A particle moves according to the law x = a cos πt2. The distance covered by it in the time interval between t = 0 to t = 3 s is