1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
|
def matrizen(x,y):
jacobi=np.arange(4).reshape(2,2)
ziel=np.arange(2)
print math.cos(x)
print -math.exp(-y)
jacobi[0,0]=math.cos(x)
jacobi[0,1]=-1.0
jacobi[1,0]=-1.0
jacobi[1,1]=-math.exp(-y)
ziel[0]=math.sin(x)-y
ziel[1]=math.exp(-y)
print np.matrix(jacobi)
print ziel
matrizen(1.0,1.0)
|