gradient of gradient and laplacian of one-dimensional vector
1 view (last 30 days)
Show older comments
I have a 1-dimensional vector which is:
p = [1 3 6 10 16 18 29];
laplace = del2(p);
px= gradient(p);
pxx=gradient(px);
Since it is one-dimensional, laplacian of the vector must be equal to gradient of gradient. However they give completely different results.
laplace = 0.2500 0.2500 0.2500 0.5000 -1.0000 2.2500 5.5000
pxx = 0.5000 0.7500 1.2500 0.2500 0.7500 3.5000 4.5000
0 Comments
Answers (0)
See Also
Categories
Find more on Mathematics and Optimization in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!