Bezier interpolation ruining graph: Disable feature?
- Lenguaje dominante
- Python
- Estrellas
- 93.8k
- Forks
- 7.7k
- Métricas de merge de PR
- Métricas de PR pendientes
Descripción
When plotting the function seen in the (attached) image, a ringing occurs on the transition shoulders. I assume this is from the Bezier interpolation the function goes through when `get_graph()` is called? `get_graph()` calls `interpolate(x_min, x_max, alpha)` from `manimlib.utils.bezier`.
Is there a feature to disable this? Correct way to handle this?
```
class FirstScene(GraphScene):
CONFIG={
"camera_config":{"background_color":WHITE},
"x_min":0,
"x_max":4,
"y_min":0,
"function_color":BLUE,
"function2_color":RED,
"x_tick_frequency": 0.25,
"y_tick_frequency": 0.5,
"y_max":1.2,
"y_axis_label": "$y$",
"x_axis_label": "$x$",
"label_nums_color":BLACK,
"x_labeled_nums":range(0,5,1),
"y_labeled_nums":range(0,1,1),
}
def construct(self):
self.setup_axes(animate=True)
func_graph=self.get_graph(self.func_to_graph,self.function_color)
func_graph2=self.get_graph(self.func_to_graph2,self.function2_color)
self.play(ShowCreation(func_graph))
self.play(ShowCreation(func_graph2))
def func_to_graph(self,x):
kB = 8e-5
T = 20
return 1 / ( 1 + np.exp( (x - 1) / (kB*T) ) )
def func_to_graph2(self,x):
kB = 8e-5
T = 800
return 1 / ( 1 + np.exp( (x - 1) / (kB*T) ) )
```

Guía de contribución
No hay ninguna guía de contribución indexada para este repositorio
Evaluación
Este issue todavía no se ha evaluado.