Second-Order Difference
1 次查看(过去 30 天)
显示 更早的评论
How can I find the Second-Order Difference signals in diagonal and minor diagonal of a matrix? The matrix is an image. For the horizontal and vertical I suppose this:
Dh = diff(image, 2);
Dv = diff(Image, 2 ,2);
Thanks!
0 个评论
回答(1 个)
bym
2011-9-24
m = magic(4)
Dd = diff(diag(m),2) %diagonal
Dm = diff(diag(rot90(m)),2) %minor diagonal
2 个评论
另请参阅
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!