📄 trin2d.m
字号:
function [n12d,n22d,n32d,b1,b2] = trin2d(n1,n2,n3)
% Find two orthogonal basis vectors for the plane containing the triangle
b1 = n2-n1;
% find projection of n3-n1 onto b1
proj = (dot(n3-n1,b1)/dot(b1,b1))*b1;
% subtract this from n3-n1 to find second basis function orthogonal to b1
b2 = (n3-n1)-proj;
% can now express pts in traingle in form n1 +xb1 +yb2 => 2-D coords
n12d = [0,0];
n22d = [(n2-n1)/b1,(n2-n1)/b2];
n32d = [(n3-n1)/b1,(n3-n1)/b2];
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -