Quantcast

Documentation Center

  • Trial Software
  • Product Updates

plot::Ellipse2d

Ellipses in 2D

Use only in the MuPAD Notebook Interface.

This functionality does not run in MATLAB.

Syntax

plot::Ellipse2d(r1, r2, <[cx, cy]>, <a = amin .. amax>, options)

Description

plot::Ellipse2d( r1, r2, [cx, cy] ) creates a 2D ellipse with center point [cx, cy] and semi-axes of lengths r1 and r2 for the horizontal and the vertical axis, respectively.

The symmetry axes of the ellipse are parallel to the coordinate axes. Use plot::Rotate2d to create ellipses of different orientation.

If no center point is specified, an ellipse with center [0, 0] is created.

Attributes

AttributePurposeDefault Value
AffectViewingBoxinfluence of objects on the ViewingBox of a sceneTRUE
AntiAliasedantialiased lines and points?TRUE
Centercenter of objects, rotation center[0, 0]
CenterXcenter of objects, rotation center, x-component0
CenterYcenter of objects, rotation center, y-component0
Colorthe main colorRGB::Blue
Filledfilled or transparent areas and surfacesFALSE
FillColorcolor of areas and surfacesRGB::Red
FillPatterntype of area fillingDiagonalLines
Framesthe number of frames in an animation50
Legendmakes a legend entry 
LegendTextshort explanatory text for legend 
LegendEntryadd this object to the legend?FALSE
LineColorcolor of linesRGB::Blue
LineWidthwidth of lines0.35
LineStylesolid, dashed or dotted lines?Solid
LinesVisiblevisibility of linesTRUE
LineColorDirectionthe direction of color transitions on lines[0, 1]
LineColorDirectionXx-component of the direction of color transitions on lines0
LineColorDirectionYy-component of the direction of color transitions on lines1
Namethe name of a plot object (for browser and legend) 
ParameterEndend value of the animation parameter 
ParameterNamename of the animation parameter 
ParameterBegininitial value of the animation parameter 
ParameterRangerange of the animation parameter 
SemiAxessemi axes of ellipses and ellipsods[2, 1]
SemiAxisXfirst semi axis of ellipses and ellipsods2
SemiAxisYsecond semi axis of ellipses and ellipsods1
TimeEndend time of the animation10.0
TimeBeginstart time of the animation0.0
TimeRangethe real time span of an animation0.0 .. 10.0
Titleobject title 
TitleFontfont of object titles[" sans-serif ", 11]
TitlePositionposition of object titles 
TitleAlignmenthorizontal alignment of titles w.r.t. their coordinatesCenter
TitlePositionXposition of object titles, x component 
TitlePositionYposition of object titles, y component 
VisiblevisibilityTRUE
VisibleAfterobject visible after this time value 
VisibleBeforeobject visible until this time value 
VisibleFromToobject visible during this time range 
VisibleAfterEndobject visible after its animation time ended?TRUE
VisibleBeforeBeginobject visible before its animation time starts?TRUE

Examples

Example 1

We create a plot of an ellipse with center point (1, 1) and semi-axes of lengths 3 and 1:

ellipse := plot::Ellipse2d(3, 1, [1, 1]):
plot(ellipse)

We apply a rotation:

plot(ellipse, plot::Rotate2d(PI/4, [1, 1], ellipse))

delete ellipse:

Example 2

We plot an animated 3D ellipse:

plot(plot::Ellipse3d(1, 1, [0,0,0], [0,a,1-a], a = 0..1))

Example 3

We plot a colored 3D ellipse:

plot(plot::Ellipse3d(2, 1, [0,0,0], Filled,
     LineColor=RGB::Yellow, LineColor2=RGB::Red, LineColorType = Dichromatic, FillColorDirection=[+1,0,0],
     FillColor=RGB::Yellow, FillColor2=RGB::Red, FillColorType = Dichromatic, FillColorDirection=[-1,0,0]
))

Parameters

r1, r2

The semi-axes of an ellipse. They must be real numerical values or arithmetical expressions of the animation parameter a.

r1, r2 are equivalent to the attributes SemiAxisX, SemiAxisY.

cx, cy

The center. The coordinates cx, cy must be real numerical values or arithmetical expressions of the animation parameter a. If no center is specified, the ellipse is centered at the origin.

cx, cy are equivalent to the attribute Center.

a

Animation parameter, specified as a = amin..amax, where amin is the initial parameter value, and amax is the final parameter value.

See Also

MuPAD Functions

MuPAD Graphical Primitives

Was this topic helpful?