Clear Filters
Clear Filters

how to calculate slope of each grid ?

2 views (last 30 days)
Pritha Pande
Pritha Pande on 30 May 2017
Commented: Pritha Pande on 1 Jun 2017
i have 80*80 matrix. I wanted to write a code to find slope of every grid.
  4 Comments
Jan
Jan on 30 May 2017
Then your professor might be so kind to define, which slope you should calculate. The slope in x and in y direction? The direction of the steepest descent? The vector orthogonal to the plane in each point? Imagine you have a balloon. What is the "slope" in each point?
Pritha Pande
Pritha Pande on 1 Jun 2017
Got the slope now. Anyways, thanks for the help.

Sign in to comment.

Answers (1)

Jan
Jan on 30 May 2017
Edited: Jan on 30 May 2017
[dx, dy] = gradient(X)
  2 Comments
Pritha Pande
Pritha Pande on 30 May 2017
then slope would be dy/dx?
Jan
Jan on 30 May 2017
Did you read this already:
doc gradient
?

Sign in to comment.

Categories

Find more on Descriptive Statistics in Help Center and File Exchange

Tags

Community Treasure Hunt

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

Start Hunting!