f = 1/x
a = 1
fp = f.derivative()
fpp = fp.derivative()
fppp = fpp.derivative()
G = plot(f,(x,0.2,5),color='red',thickness='5') + point((a,f(x=a)),size=50,color='red')
p1= f(x=a) + fp(x=a)*(x-a)
G += plot(p1,(x,0.2,5),color='blue')
p2 = f(x=a) + fp(x=a)*(x-a) + fpp(x=a)*(x-a)^2/2
G += plot(p2,(x,0.2,4),color='green')
p3 = p2 + fppp(x=a)*(x-a)^3/6
G += plot(p3,(x,0.2,3),color='orange')
show(G)