Community Profile

photo

Chen


Last seen: 10ヶ月 前 2022 年からアクティブ

統計

Content Feed

表示方法

質問


Euler method table problem.Why my fprintf(y(i+1)) only has the last ans, my y1-y(i+1) is incorrect and how to let the table be tidy?
h=0.2; x=0:h:1; y=zeros(size(x)); y(1)=0; n=numel(y); y1=exp(x)-x-1; fprintf('xn \t yn\t y(xn)\t error\n '); for i=1:n-1 ...

1年以上 前 | 1 件の回答 | 0

1

回答

質問


Why does the code have Check for incorrect argument data type or missing argument in call to function 'zero'?
h=0.1; x=0:h:1; y=zero(size(x)); y(1)=0; n=numel(y); y1=exp(x)-x-1; for i=1:n-1 f = x(i)+y(i); y(i+1) = y(i) + h...

1年以上 前 | 1 件の回答 | 0

1

回答