Function Repository Resource:

EllipseProperties

Source Notebook

Get an Association of the properties of a given ellipse

Contributed by: Wolfram|Alpha Math Team

ResourceFunction["EllipseProperties"][expr,{x,y}]

returns an Association of properties of the ellipse defined by expr in terms of the variables x and y.

Details and Options

The input expr can be an equation or an Association of ellipse properties. In this case, ResourceFunction["EllipseProperties"] will calculate and return the full set of properties.
Ellipse properties include "Equation", "Foci", "Vertices", "Covertices", "Eccentricity", "Center", "SemimajorAxisLength", "SemiminorAxisLength", "AreaEnclosed", "SemiLatusRectum", "Directrices", "AxesOfSymmetry", "Circumference", "RotationAngle" and "BaseConic".
The "BaseConic" property is an Association of the properties "Equation", "RotationAngle" and "DisplacementFromOrigin", where "Equation" represents an isomorphic conic section based at the origin and aligned with the x-axis.
If the given expr describes a conic section other than a ellipse, ResourceFunction["EllipseProperties"] will issue a message and return an Association of properties pertaining to the correct conic section.

Examples

Basic Examples (1) 

Compute the properties of an ellipse:

In[1]:=
ResourceFunction["EllipseProperties"][x^2/25 + y^2/9 == 1, {x, y}]
Out[1]=

Scope (3) 

Compute the properties of a ellipse described using other properties:

In[2]:=
ResourceFunction[
 "EllipseProperties"][<|"Foci" -> {{-1, 0}, {1, 0}}, "Vertices" -> {{-3, 0}, {3, 0}}|>, {x, y}]
Out[2]=

Compute the properties of a skew ellipse (not aligned with the x- or y-axis) described by some properties:

In[3]:=
ResourceFunction[
 "EllipseProperties"][<|"Foci" -> {{-1, -1}, {1, 1}}, "Vertices" -> {{-3, -3}, {3, 3}}|>, {x, y}]
Out[3]=
In[4]:=
ResourceFunction[
 "EllipseProperties"][<|"Foci" -> {{1, 1}, {2, 2}}, "Eccentricity" -> 1/2|>, {x, y}]
Out[4]=

Compute the properties of a circle as a special case of an ellipse:

In[5]:=
ResourceFunction["EllipseProperties"][x^2 + y^2 == 1, {x, y}]
Out[5]=
In[6]:=
ResourceFunction[
 "EllipseProperties"][<|"Center" -> {0, 0}, "Radius" -> 1|>, {x, y}]
Out[6]=

Applications (2) 

Compute the properties of a general ellipse centered at {h,k} with radius semi-axis lengths a and b:

In[7]:=
ResourceFunction[
 "EllipseProperties"][(x - h)^2/a + (y - k)^2/b == 1, {x, y}]
Out[7]=

Note that we have to give a constraint on a and b in order to fully define the ellipse:

In[8]:=
Assuming[a > b, ResourceFunction[
  "EllipseProperties"][(x - h)^2/a + (y - k)^2/b == 1, {x, y}]]
Out[8]=

Properties and Relations (1) 

Use the resource function InteractiveConicPlot to visualize the results of EllipseProperties:

In[9]:=
ResourceFunction["InteractiveConicPlot"][2 x^2 + 4 y^2 == 1, {x, y}]
Out[9]=

Possible Issues (1) 

If the input equation or Association does not describe an ellipse but describes another conic section, EllipseProperties will return an Association of properties pertaining to the correct conic section, including its "Type" ("Parabola", "Hyperbola" or "Circle"):

In[10]:=
ResourceFunction["EllipseProperties"][x^2 + y == 1, {x, y}]
Out[10]=

Publisher

Wolfram|Alpha Math Team

Version History

  • 2.0.0 – 23 March 2023
  • 1.0.0 – 01 May 2020

Related Resources

License Information