LinearWave#
Qualified name: manim\_physics.wave.LinearWave
- class LinearWave(wavelength=1, period=1, amplitude=0.1, x_range=[- 5, 5], y_range=[- 5, 5], **kwargs)[source]#
Bases:
RadialWaveA 3D Surface with waves in one direction.
- Parameters:
wavelength (float) – The wavelength of the wave.
period (float) – The period of the wave.
amplitude (float) – The amplitude of the wave.
x_range (Iterable[float]) – The range of the wave in the x direction.
y_range (Iterable[float]) – The range of the wave in the y direction.
kwargs – Additional parameters to be passed to
Surface.
Examples
Example: LinearWaveExampleScene ¶
from manim import * class LinearWaveExampleScene(ThreeDScene): def construct(self): self.set_camera_orientation(60 * DEGREES, -45 * DEGREES) wave = LinearWave() self.add(wave) wave.start_wave() self.wait() wave.stop_wave()
class LinearWaveExampleScene(ThreeDScene): def construct(self): self.set_camera_orientation(60 * DEGREES, -45 * DEGREES) wave = LinearWave() self.add(wave) wave.start_wave() self.wait() wave.stop_wave()Methods
Attributes
animateUsed to animate the application of any method of
self.animation_overridescolordepthThe depth of the mobject.
fill_colorIf there are multiple colors (for gradient) this returns the first one
heightThe height of the mobject.
n_points_per_curvesheen_factorstroke_colorwidthThe width of the mobject.