Median¶
Qualified name: manimextra.geometry.Median
- class manimextra.geometry.Median(A, B, C, **kwargs)¶
Bases:
Cevian
A class to represent a median in a triangle.
- Parameters:
A (Point3DLike) – The first vertex of the triangle.
B (Point3DLike) – The second vertex of the triangle.
C (Point3DLike) – The third vertex of the triangle.
Examples
Example: MedianExample ¶
from manim import * from manimextra import * class MedianExample(Scene): def construct(self): A = Dot(2 * DOWN + 4 * LEFT).set_z_index(1) B = Dot(2 * UP + 2.5 * LEFT).set_z_index(1) C = Dot(2 * DOWN + 4 * RIGHT) a = Line(B, C, color=BLUE) b = Line(A, C, color=BLUE) c = Line(A, B, color=BLUE) median = Median(A, B, C, color=YELLOW) self.add(A, B, C, a, b, c, median)
Methods
get_equal_segments
Attributes
animate
Used to animate the application of any method of
self
.animation_overrides
color
depth
The depth of the mobject.
fill_color
If there are multiple colors (for gradient) this returns the first one
height
The height of the mobject.
n_points_per_curve
sheen_factor
stroke_color
width
The width of the mobject.
- _original__init__(A, B, C, **kwargs)¶
Initialize self. See help(type(self)) for accurate signature.