matlab里的问题,>> n=2:40;>> a(n)=[102.0 101.9 102.0 102.6 100.9 100.0 100.3 100.0 100.1 100.0 100.0 100.2 100.0 99.9 99.8 99.8 99.9 100.0 99.9 99.7 99.8 99.8 99.9 99.9 99.9 99.9 99.6 99.9 100.0 100.3 100.3 100.1 100.1 100.2 100.6 100.8 101.6 102.
来源:学生作业帮助网 编辑:六六作业网 时间:2024/11/29 06:07:11
matlab里的问题,>> n=2:40;>> a(n)=[102.0 101.9 102.0 102.6 100.9 100.0 100.3 100.0 100.1 100.0 100.0 100.2 100.0 99.9 99.8 99.8 99.9 100.0 99.9 99.7 99.8 99.8 99.9 99.9 99.9 99.9 99.6 99.9 100.0 100.3 100.3 100.1 100.1 100.2 100.6 100.8 101.6 102.
matlab里的问题,
>> n=2:40;
>> a(n)=[102.0 101.9 102.0 102.6 100.9 100.0 100.3 100.0 100.1 100.0 100.0 100.2 100.0 99.9 99.8 99.8 99.9 100.0 99.9 99.7 99.8 99.8 99.9 99.9 99.9 99.9 99.6 99.9 100.0 100.3 100.3 100.1 100.1 100.2 100.6 100.8 101.6 102.4 102.7];
>> x(1)=29995;
>> x(n)=x(n-1).*a(n)
matlab里的问题,>> n=2:40;>> a(n)=[102.0 101.9 102.0 102.6 100.9 100.0 100.3 100.0 100.1 100.0 100.0 100.2 100.0 99.9 99.8 99.8 99.9 100.0 99.9 99.7 99.8 99.8 99.9 99.9 99.9 99.9 99.6 99.9 100.0 100.3 100.3 100.1 100.1 100.2 100.6 100.8 101.6 102.
你是想用迭代吗?你用的数组和循环都有些问题