创建新的py文件实现矩阵的变换 ==> main_matrix_transformation.py
引入 python中的绘制包 matplotlib ==> import matplotlib.pyplot as plt
import matplotlib.pyplot as plt
from playLA.Matrix import Matrix
from playLA.Vector import Vector
import math
if __name__ == '__main__':
points = [[0,0],[0,5],[3,5],[3,4],[1,4],
[1,3],[2,3],[2,2],[1,2],[1,0]]
x = [point[0] for point in points]
y = [point[1] for point in points]
plt.figure(figsize=(5,5)) # 单位为英尺,设置坐标系
plt.xlim(-10,10) # 设置x轴范围
plt.ylim(-10,10)
plt.plot(x,y)
# plt.show() # plt函数会根据点坐标进行坐标系的自适应
P = Matrix(points)
# T = Matrix([[2,0],[0,1.5]])
# T = Matrix([[1,0],[0,-1]])
# T = Matrix([[-1, 0], [0, 1]])
# T = Matrix([[-1, 0], [0, -1]])
# T = Matrix([[1, 0.5], [0, 1]])
# T = Matrix([[1, 0], [0.5, 1]])
theta = math.pi/3
T = Matrix([[math.cos(theta),math.sin(t