Equation for making an oval based on r=cos(th)

188 Views Asked by At

I have a polar graph (on paper) with a curve similar to 7.8*cos(theta). Plotting the data estimate from a nice big print-out of the graph gives a fairly close fit, but I seems that the circle needs to made into an oval to fit better. In other words it looks like a scale factor in the "y direction" (if you'll forgive me, I know it's a polar plot.)

http://ibin.co/2V7RxQNKbqbO

deg rad     f(r)    Real Data
0   0       7.8000  7.8
10  0.174   7.6815  7.7
20  0.349   7.3296  7.4
30  0.523   6.7550  6.9
40  0.698   5.9751  6.2
50  0.872   5.0137  5.3
60  1.047   3.9000  4.2
70  1.221   2.6678  3

(Beyond 70 deg a different curve applies in my problem domain so I'm not too worried about that part of the curve)

Is there another form of equation that I can use to modify r=7.8cos(th) to stretch the curve? The purpose is to use an equation to calculate the values at intermediate points, and to avoid a potentially complex lookup system.

1

There are 1 best solutions below

6
On BEST ANSWER

You stretch the plot vertically by a scale factor $\lambda\gtrsim1$.

Your equation was

$$\rho=r\cos(\theta),$$ and in Cartesian coordinates

$$x=r\cos^2(\theta),\\ y=r\cos(\theta)\sin(\theta)).$$

It is now

$$x=r\cos^2(\theta),\\ y=\lambda r\cos(\theta)\sin(\theta),$$

which is no more simple in polar coordinates, as

$$\rho'=r\cos(\theta)\sqrt{\cos^2(\theta)+\lambda^2\sin^2(\theta)},\\ \tan(\theta')=\lambda\tan(\theta).$$

Eliminating $\theta$, this gives this little monster:

$$\rho'=r\cos\left(\arctan\left(\frac{\tan(\theta')}\lambda\right)\right)\sqrt{\cos^2\left(\arctan\left(\frac{\tan(\theta')}\lambda\right)\right)+\lambda^2\sin^2\left(\arctan\left(\frac{\tan(\theta')}\lambda\right)\right)}.$$

You'd probably better stick to Cartesian coordinates with the ellipse

$$\left(\frac{x-r}{r}\right)^2+\left(\frac y{\lambda r}\right)^2=1.$$