I have the following equation to find a point on a circle:
x = (int) (10 * Math.cos(45.0));
y = (int) (10 * Math.sin(45.0));
x1 = new Point(x, y);
I then draw a Line from the center of the circle to this new point.
I would have thought that changing the parameters of the Math.cos and Math.sin functions would change the angle at which the line comes out from the center, but when I test this, it is the radius of the circle that, if changed, changes the angle at which the line is drawn at.
Am I misunderstanding the math? What is going wrong here?
This is the line drawn from the center circle with the above equation, though it should only be as long as the radius of that center circle
This is the resulting image when the equation is:
x = (int) (350 * Math.cos(45.0));
y = (int) (350 * Math.sin(45.0));
x1 = new Point(x, y);