Chapter 6 중간고사 possible 문제

1888 days ago by matrix

아래 문제가 문제 2입니다.

T1=matrix(2,2,[4,0,0,2]); T2=matrix(2,2,[cos(pi/3), -sin(pi/3), sin(pi/3), cos(pi/3)]); T=T2*T1 # Standard matrix for the given transformation. var('x') # Declare a variable. var('y') # Declare a variable. Circle=matrix(2,1,[x, y]); Ellipse=T*Circle print T print print Ellipse 
       
[        2  -sqrt(3)]
[2*sqrt(3)         1]

[-sqrt(3)*y + 2*x]
[ 2*sqrt(3)*x + y]
[        2  -sqrt(3)]
[2*sqrt(3)         1]

[-sqrt(3)*y + 2*x]
[ 2*sqrt(3)*x + y]
 
       

아래 문제가 문제 1입니다.

a,b,c =var('a,b,c') T(a,b,c)=(a+b, 2*c-a ) A=linear_transformation(QQ^3,QQ^2,T) T_x1=T(a1,b1,c1) T_x2=T(a2,b2,c2) T_x1_x2=T(a1+a2, b1+b2, c1+c2) T_kx1=T(k*a1, k*b1, k*c1) print T_x1 print T_x2 print T_x1_x2 print print T_kx1 print k*T_x1 print print (T_x1_x2) == (T_x1 + T_x2) print T_kx1 == k*T_x1 
       
(a1 + b1, -a1 + 2*c1)
(a2 + b2, -a2 + 2*c2)
(a1 + a2 + b1 + b2, -a1 - a2 + 2*c1 + 2*c2)

(a1*k + b1*k, -a1*k + 2*c1*k)
((a1 + b1)*k, -(a1 - 2*c1)*k)

True
True
(a1 + b1, -a1 + 2*c1)
(a2 + b2, -a2 + 2*c2)
(a1 + a2 + b1 + b2, -a1 - a2 + 2*c1 + 2*c2)

(a1*k + b1*k, -a1*k + 2*c1*k)
((a1 + b1)*k, -(a1 - 2*c1)*k)

True
True