How to find the gradient of a curve at a specific point?

5 ビュー (過去 30 日間)
Pramodya Wijesinghe
Pramodya Wijesinghe 2017 年 9 月 7 日

採用された回答

Jose Marques
Jose Marques 2017 年 9 月 9 日
If the data is in the variable "data", you find the gradient like this:
grad = zeros(size(data))
for i=1:(size(data,2)-1)
grad(i) = data(i+1)-data(i);
end
  1 件のコメント
Pramodya Wijesinghe
Pramodya Wijesinghe 2017 年 9 月 15 日
Thank you very much!That was really helpful.

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeMathematics and Optimization についてさらに検索

タグ

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by