How to code difference quotients in matlab?
5 ビュー (過去 30 日間)
古いコメントを表示
I have a vector U and I want to take its difference quotient at a time instance j i.e. I want to find dU as shown below. How can it be done?
Thank you guys in advance!
0 件のコメント
採用された回答
Jonas
2022 年 6 月 13 日
elementwise differences of consecutive elements can be calculated using diff() command
2 件のコメント
Image Analyst
2022 年 6 月 14 日
U = randi(9, 1, 10)
% Compute difference
du = diff(U)
% Compute variance
varU = var(du)
Not sure what you mean by ratio. A ratio is a fraction of something divided by something. What are you ratioing? The ratio of a single number -- the variance -- doesn't make sense.
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Numerical Integration and Differential Equations についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!