|
|
Jon S. Berndt wrote:
> can't seem to find an equation that will allow me to draw an ellipse
> (CENTERED ON THE ORIGIN) by stepping through an angle A. Given the x and y
> axis radii, a and b, I want to start at zero angle and calculate a radius
> measurement R (FROM THE ORIGIN) for that angle. My thinking is that I will
> y = b*sin(A)
> x = a*cos(A)
This is an ellipse, but A is not the angle, but some unspecified
parameter (which nevertheless runs from 0 to 2pi).
The angle can be computed after this with the equation
phi = atan2(y,x)
if you need it (if your computing environment does not know
the function atan2, you will have to emulate it using atan(y/x)
and manual sign manipulation/constant addition).
> y = a*sin^2(A)
> x = b*cos^2(A)
This is a straight line (irrespective of what A stands for).
Ralf
Post a reply to this message
|
|