How to Determine if a Point Lies Inside a Tilted and Translated Ellipse?

  • Thread starter Thread starter Sleeker
  • Start date Start date
  • Tags Tags
    Ellipse
AI Thread Summary
To determine if a point lies within a tilted and translated ellipse, the necessary formula incorporates the ellipse's center coordinates, lengths of the major and minor axes, and the tilt angle. The proposed equation is: ((x - x_c)cosθ + (y - y_c)sinθ)²/a² + ((x - x_c)sinθ - (y - y_c)cosθ)²/b² = 1. This formula effectively accounts for both the translation and rotation of the ellipse. The user is seeking a single formula to streamline calculations for approximately 2,500 points in their astronomical research. The discussion highlights the importance of accurately incorporating these parameters for precise point location within elliptical shapes.
Sleeker
Messages
7
Reaction score
0
I need to find whether or not a point is within an ellipse. The problem is that the ellipse is tilted at an angle and not at the origin. I've tried Googling everywhere and can't find a good equation for what I need. Does anybody know the formula for an ellipse that includes:

1. Coordinates of the ellipse's center
2. Length of major axis (diameter or radius)
3. Length of minor axis (diameter or radius)
4. Angle the ellipse is tilted relative to x or y-axis (doesn't matter which, I can figure it out from there).

I'm doing astronomical research, and I'm trying to locate points within galaxies which are shaped like ellipses. The four things I listed are the things I am given.

Edit: I know I can translate and rotate my ellipse, but I would really like just one formula since I need to do this approximately 2,500 times for my astronomical research.

Another edit: Maybe this?

(\frac{x cos\theta+y sin\theta - x_c}{a})^2 + (\frac{x sin\theta-y cos\theta - y_c}{b})^2 = 1

a = major axis (radial)
b = minor axis (radial)
x_c = x coordinate of center
y_c = y coordinate of center
\theta = Angle of tilt from x-axis

I kind of just mixed and matched formulas until I think I incorporated everything. Is it right?
 
Last edited:
Mathematics news on Phys.org
It may be simplest to compute a change of coordinates that tranforms to a coordinate system where the ellipse is not tilted. Then apply the change of coordinates to the points in question and solve the problem in the simpler setting.
 
Try this:

\frac{((x-x_c)\cos\theta + (y-y_c)\sin\theta)^2}{a^2}+<br /> \frac{((x-x_c)\sin\theta - (y-y_c)\cos\theta)^2}{b^2}=1
 
Hm, yeah, that makes more sense with incorporating the fact that it's off-center with the formula from this website:

http://www.maa.org/joma/Volume8/Kalman/General.html
 
Last edited by a moderator:
Thread 'Video on imaginary numbers and some queries'
Hi, I was watching the following video. I found some points confusing. Could you please help me to understand the gaps? Thanks, in advance! Question 1: Around 4:22, the video says the following. So for those mathematicians, negative numbers didn't exist. You could subtract, that is find the difference between two positive quantities, but you couldn't have a negative answer or negative coefficients. Mathematicians were so averse to negative numbers that there was no single quadratic...
Insights auto threads is broken atm, so I'm manually creating these for new Insight articles. In Dirac’s Principles of Quantum Mechanics published in 1930 he introduced a “convenient notation” he referred to as a “delta function” which he treated as a continuum analog to the discrete Kronecker delta. The Kronecker delta is simply the indexed components of the identity operator in matrix algebra Source: https://www.physicsforums.com/insights/what-exactly-is-diracs-delta-function/ by...
Thread 'Unit Circle Double Angle Derivations'
Here I made a terrible mistake of assuming this to be an equilateral triangle and set 2sinx=1 => x=pi/6. Although this did derive the double angle formulas it also led into a terrible mess trying to find all the combinations of sides. I must have been tired and just assumed 6x=180 and 2sinx=1. By that time, I was so mindset that I nearly scolded a person for even saying 90-x. I wonder if this is a case of biased observation that seeks to dis credit me like Jesus of Nazareth since in reality...
Back
Top