소수와 분수의 출력 형식이 달라지는 경우
显示 更早的评论
왜 un_A가 출력에서는 소수가 아닌 분수로 나타나는 것인가요?
clear
mL=[200 202 201 199 198];
avg_mL=mean(mL);
std_mL=std(mL);
un_A=round(std_mL/sqrt(length(mL)),3);
un_A % un_A=0.707
syms Li Lr;
LL=Li+Lr;
Ldiff=diff(LL,Li);
c_mL=vpa(subs(Ldiff,Lr,1));
un_mag=un_A*c_mL;
v_mL=length(mL)-1;
syms A1 A2 A3 A4 A5 A6
mA=[A1 avg_mL; A2 un_A; A3 A3; A4 c_mL; A5 un_mag; A6 v_mL] % un_A=707/1000
<출력>
mA =
[A1, 200]
[A2, 707/1000] % un_A=707/1000
[A3, A3]
[A4, 1.0]
[A5, 0.707]
[A6, 4]
采纳的回答
更多回答(0 个)
类别
在 帮助中心 和 File Exchange 中查找有关 기호와 수치 간 변환 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
