![]() |
|
Computes in polar coordinates. More...
#include <Analysis.h>


Public Member Functions | |
| PolarSegmentProber (const drain::image::Channel &src, drain::image::Channel &dst) | |
| virtual void | update (int i, int j) |
| Operation performed in each segment location (i,j). A function to be redefined in derived classes. | |
Public Member Functions inherited from SizeProber | |
| SizeProber (const Channel &s, Channel &d) | |
| virtual void | clear () |
| Called before processing each segment. Compare with init(), which is called once for each image. | |
| virtual void | visit (int i, int j) |
| Visiting a single pixel when not coming from any direction. | |
| virtual bool | isVisited (int i, int j) const |
| Experimental. | |
| virtual bool | isValidSegment (int i, int j) const |
| Application dependent, to be redefined. Assumes checked coordinates. | |
Public Member Functions inherited from SegmentProber< int, int, SegmentProberConf< int, int > > | |
| SegmentProber (const Channel &s) | |
| SegmentProber (const Channel &s, Channel &d) | |
| void | setDst (Channel &d) |
| Set new target channel. Needed in multichannel operations. | |
| virtual void | init () |
| Fills the segment having intensity between min and max. | |
| void | scan () |
| A convenience function for traversing a whole image. | |
| void | probe (int i, int j, bool HORIZONTAL) |
| Start probings. | |
| bool | isValidPixel (int i, int j) const |
| Returns isValidSegment(i,j) and !isVisited(i,j). | |
Additional Inherited Members | |
Public Types inherited from SegmentProber< int, int, SegmentProberConf< int, int > > | |
| typedef int | src_t |
| typedef int | dst_t |
| typedef SegmentProberConf< int, int > | conf_t |
Public Attributes inherited from SizeProber | |
| size_t | size |
Public Attributes inherited from SegmentProber< int, int, SegmentProberConf< int, int > > | |
| ProberControl & | control |
| conf_t | conf |
| const Channel & | src |
| Channel * | dst |
Protected Member Functions inherited from SegmentProber< int, int, SegmentProberConf< int, int > > | |
| virtual bool | isValidMove (int i0, int j0, int i, int j) const |
| Application dependent, to be redefined. Note: assumes checked coordinates. | |
| bool | move (int &i, int &j) |
| Try to move; change coords in success, else keep them intact. | |
| void | scanHorzProbeVert (int i, int j) |
| A semi-recursive approach that turns the 2D recursion to 1D traversal + 1D recursion. | |
| void | scanVertProbeHorz (int i, int j) |
Protected Attributes inherited from SegmentProber< int, int, SegmentProberConf< int, int > > | |
| SimpleProberControl | basicControl |
Computes in polar coordinates.
The area of a sector of a circle is
\[ A_s = \frac{1}{2}ra = \frac{1}{2}\alpha r^2 \]
where \(r\) is radius and \(p = \alpha r\) arc of the sector.
Consider a radar sweep and a bin \(b(i,j)\) where \(i\) is the range index and \(j\) is the azimuthal index. The corresponding physical area is
\[ A_b(i,j) = \frac{1}{2}(r_2-r_1)a = \frac{1}{2}\mathrm{rscale}\cdot \frac{2\pi}{\mathrm{nrays}}(i\cdot \mathrm{rscale}) = \frac{\pi(\mathrm{rscale})^2}{\mathrm{nrays}} i \]
where \(\mathrm{rscale}\) is the phycal bin length and \(\mathrm{nrays}\) the number of beams in the sweep. Notice that the area is a function of \(i\) only, but we write both indices \((i,j)\) for clarity.
Consider a segment \(\Phi\) in a radar sweep. The segment can be identified with the set of coordinate of the involved bins: \(\Phi = \{(i,j)\}\) In computing the area of segment \( \Phi \) , PolarSegmentProber primarily computes a simple integer quantity
\[ D_\Phi = \sum_\Phi i \]
The physical area is hence
\[ A_\Phi = \sum_\Phi A_b(i,j) = \sum_\Phi \frac{\pi(\mathrm{rscale})^2}{\mathrm{nrays}} i = \frac{\pi(\mathrm{rscale})^2}{\mathrm{nrays}} \sum_\Phi i = \frac{\pi(\mathrm{rscale})^2}{\mathrm{nrays}} D_\Phi \]
Operation performed in each segment location (i,j). A function to be redefined in derived classes.
Reimplemented from SizeProber.
1.9.8