为什么MATLAB中cos(pi/2)不等于0,而是以分数的形式表示,怎么能让这些值很小的分数变为0呢?; V: y( G4 \ d H/ U- R: P& ~
说明:我在做一个计算时,最后出现的结果是下面这样的,但是其中的那些分数本来应该是零的* F1 F9 u9 a5 h7 ~2 y# S+ M
T40 =
( a2 L! L1 v% G& L; p2 O7 v 1 m+ \* Q9 G7 l; {9 c8 y4 N7 w; R7 @
[ (4967757600021511*cos(s1)^2)/81129638414606681695789005144064 - (4967757600021511*cos(s1)*sin(s1))/81129638414606681695789005144064 - (4967757600021511*3^(1/2)*sin(s1)^2)/243388915243820045087367015432192 + (2^(1/2)*3^(1/2)*sin(s1))/3 - (4967757600021511*3^(1/2)*cos(s1)*sin(s1))/243388915243820045087367015432192, (3^(1/2)*sin(s1)^2)/3 - (24678615572571482867467662723121*cos(s1)*sin(s1))/6582018229284824168619876730229402019930943462534319453394436096 - cos(s1)^2 + (4967757600021511*2^(1/2)*3^(1/2)*sin(s1))/243388915243820045087367015432192 - (24678615572571482867467662723121*3^(1/2)*cos(s1)*sin(s1))/19746054687854472505859630190688206059792830387602958360183308288, cos(s1)*sin(s1) + (4967757600021511*2^(1/2)*3^(1/2)*sin(s1))/243388915243820045087367015432192 + (3^(1/2)*cos(s1)*sin(s1))/3, a1*cos(s1) - a3*((3^(1/2)*sin(s1)^2)/3 - cos(s1)^2) + d4*(cos(s1)*sin(s1) + (3^(1/2)*cos(s1)*sin(s1))/3) + (2^(1/2)*3^(1/2)*d3*sin(s1))/3 + (4967757600021511*2^(1/2)*3^(1/2)*d4*sin(s1))/243388915243820045087367015432192]* L5 d4 f% O' n+ u5 t
[ (4967757600021511*cos(s1)*sin(s1))/81129638414606681695789005144064 - (4967757600021511*sin(s1)^2)/81129638414606681695789005144064 + (4967757600021511*3^(1/2)*cos(s1)^2)/243388915243820045087367015432192 + (4967757600021511*3^(1/2)*cos(s1)*sin(s1))/243388915243820045087367015432192 - (2^(1/2)*3^(1/2)*cos(s1))/3, (24678615572571482867467662723121*3^(1/2)*cos(s1)^2)/19746054687854472505859630190688206059792830387602958360183308288 - (24678615572571482867467662723121*sin(s1)^2)/6582018229284824168619876730229402019930943462534319453394436096 - cos(s1)*sin(s1) - (3^(1/2)*cos(s1)*sin(s1))/3 - (4967757600021511*2^(1/2)*3^(1/2)*cos(s1))/243388915243820045087367015432192, - (3^(1/2)*cos(s1)^2)/3 - (4967757600021511*2^(1/2)*3^(1/2)*cos(s1))/243388915243820045087367015432192 + sin(s1)^2, d4*(sin(s1)^2 - (3^(1/2)*cos(s1)^2)/3) + a1*sin(s1) + a3*(cos(s1)*sin(s1) + (3^(1/2)*cos(s1)*sin(s1))/3) - (2^(1/2)*3^(1/2)*d3*cos(s1))/3 - (4967757600021511*2^(1/2)*3^(1/2)*d4*cos(s1))/243388915243820045087367015432192]: |9 U) P% r5 l' R3 D5 f: T' w
[ 3^(1/2)/3 + (4967757600021511*2^(1/2)*3^(1/2)*sin(s1))/243388915243820045087367015432192 + (4967757600021511*2^(1/2)*3^(1/2)*cos(s1))/243388915243820045087367015432192, (4967757600021511*3^(1/2))/243388915243820045087367015432192 - (2^(1/2)*3^(1/2)*sin(s1))/3 + (24678615572571482867467662723121*2^(1/2)*3^(1/2)*cos(s1))/19746054687854472505859630190688206059792830387602958360183308288, (4967757600021511*3^(1/2))/243388915243820045087367015432192 - (2^(1/2)*3^(1/2)*cos(s1))/3, (3^(1/2)*d3)/3 + (4967757600021511*3^(1/2)*d4)/243388915243820045087367015432192 - (2^(1/2)*3^(1/2)*d4*cos(s1))/3 + (2^(1/2)*3^(1/2)*a3*sin(s1))/3] e4 W0 `5 A& ^* F2 I
[ 0, 0, 0, 1]1 k& }- L4 q [
|