Calculate midpoints between extrema in a picture
1 view (last 30 days)
Show older comments
Hello, after calculating the maxima and minima in a picture i'd like to calculate the midpoints between them (and interpolate them later on). In a one dimensional singal it would be something like
if true
(E(i)+E(i+1))/2
end
where E(i) is the i-th Extrema. But in 2D it isn't that easy anymore, because in every direction there are points to calculate. I don't really know how to approach this problem and maybe someone did something familiar? I am thankful for any suggestion.
2 Comments
Varun Pai
on 13 Oct 2015
Do you want the pixel values connecting the maximum and minimum pixel intensity. You may have more than one maxima and minima in a pic.
Answers (1)
Thorsten
on 13 Oct 2015
You can compute the mid points between every combination of extrema.
Or only the midpoints between extrema that are within a specified distance of each other.
Or split the plane into radial segments of a predefined width for each extrema and compute the midpoint between the extrema with the smallest distance from your extrema i.
or ...
you need to tell as a bit more about your data and what your're trying to achieve with this computation.
0 Comments
See Also
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!