Center of a general hyperbola

90 Views Asked by At

I have an application where I work with conic sections in the form

$$A x^{2} + B x y + C y^{2} + D x + E y + F = 0$$

In case a hyperbola, a straightforward way calculate its center, as I understand is

$$x_c = \frac{B E-2 C D}{4 A C -B^2}$$ $$y_c = \frac{B D-2 A E}{4 A C -B^2}$$

It had been working fine until recently, when I came across the following situation where the coefficients of the above curve are

A = -0.3309241482403108
B = -0.39325536339874551
C = -0.11618424089196536
D = 0.98578834911406965
E = -0.5076292198791521
F = 8.264829655812191

This is a hyperbola where the center, as calculated by the above equation, is at (-500.1698135428269, 844.291924015812)

Curve(red) and calculated center(black)

As can be seen from the graph, this center is clearly wrong. More specifically, the $y$ coordinate of the center is way off and I don't really understand why. As far as I know, there are no conditions in the use of above equation for ellipses and hyperbolas. Can someone please explain to me what I am missing here?

1

There are 1 best solutions below

7
On BEST ANSWER

The hyperbola with center at $(h,k)$ is given by $$ \frac{(x - h)^2}{a^2} + \frac{(x - h) (y - k)}{c^2} + \frac{(y - k)^2}{b^2} = 1 $$

which can be re-written as

$$c^2b^2(x^2-2xh+h^2)+a^2b^2(xy-xk-hy+kh)+a^2c^2(y^2-2yk+k^2)-a^2b^2c^2=0$$

$$\implies c^2b^2x^2+a^2b^2xy+a^2c^2y^2+(-2hc^2b^2-ka^2b^2)x+(-ha^2b^2-2ka^2c^2)y+\left(h^2c^2b^2+kha^2b^2+k^2a^2c^2-a^2b^2c^2\right)=0$$

Then comparing with $$A x^{2} + B x y + C y^{2} + D x + E y + F = 0$$

gives $$D=-2hA-kB$$ $$E=-hB-2kC$$

and solving gives the center of the hyperbola to be

$$h = \frac{B E-2 C D}{4 A C -B^2}$$ $$k = \frac{B D-2 A E}{4 A C -B^2}$$


Your plot is not correct. Firstly you obtained the center to be $(500.1698135428269, 844.291924015812)$, but in the plot it looks like it's $(\color{red}{-}500.1698135428269, 844.291924015812)$, which is the correct center. Substituting the given values of $A,B,C,D,E$ and $F$ and plotting on Desmos, with centre $(h,k)\approx (-500.17,844.29)$, gives

enter image description here