Spaces:
Runtime error
Runtime error
12th commit
Browse files301 unmodified lines302303304305306307308182 unmodified lines491492493494495496497498301 unmodified linesself.play(Write(text1))self.wait()self.play(Transform(text1, text2))self.wait()'''}def check_system_requirements():182 unmodified lines- **Animations**: `Create()`, `Write()`, `Transform()`, `FadeIn()`, `FadeOut()`- **Colors**: `RED`, `BLUE`, `GREEN`, `YELLOW`, `WHITE`, `BLACK````---Made with ❤️ using [Manim](https://www.manim.community/) and [Gradio](https://gradio.app/)""")301 unmodified lines302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373182 unmodified lines556557558559560561301 unmodified linesself.play(Write(text1))self.wait()self.play(Transform(text1, text2))self.wait()''',"Polynomial Plot": '''from manim import *import numpy as npclass PolynomialPlot(Scene):def construct(self):# Set up the coordinate systemaxes = Axes(x_range=[-4, 4, 1],y_range=[-20, 80, 10],x_length=10,y_length=6,axis_config={"color": BLUE},x_axis_config={"numbers_to_include": np.arange(-4, 5, 1),"numbers_with_elongated_ticks": np.arange(-4, 5, 1),},y_axis_config={"numbers_to_include": np.arange(-20, 81, 20),"numbers_with_elongated_ticks": np.arange(-20, 81, 20),},tips=False,)# Add axis labelsaxes_labels = axes.get_axis_labels(x_label="x", y_label="f(x)")# Define the polynomial functiondef polynomial(x):return x**3 - 2*x**2 + 10*x + 8# Create the polynomial graphgraph = axes.plot(polynomial, color=RED, x_range=[-4, 4])# Create the function labelfunction_label = MathTex(r"f(x) = x^3 - 2x^2 + 10x + 8", color=RED)function_label.to_corner(UP + LEFT)# Animation sequence# First, show the axesself.play(Create(axes), Write(axes_labels), run_time=2)# Show the function labelself.play(Write(function_label), run_time=1)# Animate the drawing of the polynomial curveself.play(Create(graph), run_time=6)# Hold the final sceneself.wait(1)# Optional: Add some points of interest# Find and mark the y-intercept (when x=0)y_intercept_point = axes.coords_to_point(0, polynomial(0))y_intercept_dot = Dot(y_intercept_point, color=YELLOW, radius=0.08)y_intercept_label = MathTex(r"(0, 8)", color=YELLOW).next_to(y_intercept_dot, RIGHT)self.play(Create(y_intercept_dot),Write(y_intercept_label),run_time=0.5)# Final wait to complete 10 seconds totalself.wait(0.5)'''}def check_system_requirements():182 unmodified lines- **Animations**: `Create()`, `Write()`, `Transform()`, `FadeIn()`, `FadeOut()`- **Colors**: `RED`, `BLUE`, `GREEN`, `YELLOW`, `WHITE`, `BLACK`---Made with ❤️ using [Manim](https://www.manim.community/) and [Gradio](https://gradio.app/)""")
app.py+66-3