import pylab import numpy as np t = np.arange(0,40,0.01) b1=2 phi1 =2*np.arctan(np.sqrt(b1**2-1)/(b1+1)*np.tan(t*np.sqrt(b1**2-1)/2)) x1=np.cos(phi1) b1_2=1.05 phi1 =2*np.arctan(np.sqrt(b1_2**2-1)/(b1_2+1)*np.tan(t*np.sqrt(b1_2**2-1)/2)) x1_2=np.cos(phi1) b2=0.7 t0=5 phi2 =2*np.arctan(np.sqrt(1-b2**2)/(1+b2)*(np.exp(np.sqrt(1-b2**2)*(t-t0))+1)/(-np.exp(np.sqrt(1-b2**2)*(t-t0))+1)) x2=np.cos(phi2) #t0=0 #phi0=np.arccos(b2)+0.01# #c=-1.0/np.sqrt(1.0-b2**2)*np.log(((1.0+b2)*np.tan(phi0/2)-np.sqrt(1.0-b2**2))/((1+b2)*np.tan(phi0/2)+np.sqrt(1.0-b2**2))) #print (1.0+b2)*np.tan(phi0/2)-np.sqrt(1.0-b2**2) #print c #phi2 =2*np.arctan(np.sqrt(1-b2**2)/(1+b2)*(np.exp(np.sqrt(1-b2**2)*(t-t0+c))+1)/(-np.exp(np.sqrt(1-b2**2)*(t-t0+c))+1)) #x2_2=np.cos(phi2) pylab.plot(t,x1,lw='3',label=r'b=%3.2f' % b1) pylab.plot(t,x1_2,lw='3',label=r'b=%3.2f' % b1_2) pylab.plot(t,x2,lw='3',label=r'b=%3.2f' % b2) #pylab.plot(t,x2_2,lw='3',color='m',label=r'b=%3.2f' % b2) #FP pylab.axhline(y=b2,color='r', label='Fixpunkt') pylab.legend() pylab.xlabel("$t$") pylab.ylabel("$\cos(\phi)$") pylab.show()