How to code difference quotients in matlab?
3 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
ekagra gupta
am 13 Jun. 2022
Kommentiert: Image Analyst
am 14 Jun. 2022
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 Kommentare
Akzeptierte Antwort
Jonas
am 13 Jun. 2022
elementwise differences of consecutive elements can be calculated using diff() command
2 Kommentare
Image Analyst
am 14 Jun. 2022
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.
Weitere Antworten (0)
Siehe auch
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!