Javascript矩阵库
旨在涵盖我在javascript中所需的所有向量和矩阵运算
优点:
使用方便
方便的抽象
清除代码
缺点:
很多对象创建
表演技巧很少
注意:默认情况下,向量是列向量。行和列索引从1开始
初始化
let r=3,c=3;
let rotMat = Matrix(r,c);
//special initializations in Mat function
M = Mat.rotx(10); //make a rotation matrix about the x-axis that rotates 10 degrees
v = Mat.vec(0,1,2); //make a vector, accepts an arbitrary number of objects
M = Mat.rotv(10); //make a rotation matrix ab
1