Structuring program to always round off any five decimal numbersto zero
이전 댓글 표시
In my code, the results displayed are annoying with very lenthy fractional numbers which if actually divided is insignifican. For example
F = - exp(t*x3)*(1262711551877025502231421556075/411376139330301510538742295639337626245683966408394965837152256 + 879015404686425i/365375409332725729550921208179070754913983135744) + exp(p1*t)*cos(q1*t)*(27598641832495742863565849383413328672542006982019799902774379281/105312291668557186697918027683670432318895095400549111254310977536 + 49835990979419693i/5846006549323611672814739330865132078623730171904) + exp(p2*t)*cos(q2*t)*(119736836245515984576451256966513/162259276829213363391578010288128 - 21895279333859301i/1461501637330902918203684832716283019655932542976) - exp(p1*t)*sin(q1*t)*(244148955905429654108869640572109/5846006549323611672814739330865132078623730171904 - 10021248928274823387123781097474250594205428510041i/105312291668557186697918027683670432318895095400549111254310977536) + exp(p2*t)*sin(q2*t)*(76122868185700701518774529615449/1461501637330902918203684832716283019655932542976 - 7298426444619767i/162259276829213363391578010288128)
The above is actually just A(1,1) element of matrix A, you can now imagine 5x5 matrix
AND THIS ACTUALLY EQUALS
F = exp(p1*t)*cos(q1*t)*(0.2621) + exp(p2*t)*cos(q2*t)*(0.7379)
Could the problem have come from the symbolic reprensentation I am using before substitution?
댓글 수: 1
Matt J
2023년 5월 7일
Could the problem have come from the symbolic reprensentation I am using before substitution?
We have no way of knowing what you did to generate F.
채택된 답변
추가 답변 (0개)
카테고리
도움말 센터 및 File Exchange에서 Logical에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!


