java code to compute some multiple of a number?
===

I am using Math.PI in my example, so it is a double. It is a simple code but there is a bit I am not sure how to do:

I want the code to calculate the fundamental period X of a sin or cos function with a multiple value, a given by the user. The n value is initialised at n=1.

If the result of (2 * pi * n)/a = X is lower than pi then the number n should increment and it should keep going until that number is a multiple of pi, then print the result

Hope that makes sense. 