SAGE

sageTanh

Converging (?) to tanh

Converging (?) to tanh

sage: g = Graphics()
sage: var(‘x’)
sage: f(x) = tanh(x)
sage: g = plot(f(x),(x, -3, 3),hue=((i/10)),alpha=(1-i/13),ymax=5,ymin=-5,legend_label=’$tanh(x)$’)
sage: for i in range(100):
… p = plot(f.taylor(x, 0, (i+1)),(x, -3, 3),hue=((i/10)),alpha=(1-i/13),ymax=5,ymin=-5)
… g = g + p

sage: g.show(dpi=200, axes=false,aspect_ratio=1)

Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *