RAVE
detection_range.c File Reference

Provides functionality for creating composites. More...

#include "detection_range.h"
#include "raveobject_list.h"
#include "rave_debug.h"
#include "rave_alloc.h"
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <time.h>
#include <sys/stat.h>
#include <math.h>

Classes

struct  _DetectionRange_t
 Represents the detection range generator. More...

Macros

#define ER   8495000.0
 effective earth radius for bin height calculations
#define ERKM   8495
 effective earth radius in km
#define CONSTGRAD   50.0
 10 dB/km = 1000 m / 20 dBN

Functions

int DetectionRange_setLookupPath (DetectionRange_t *self, const char *path)
 Sets the lookup path where the cache files are stored.
const char * DetectionRange_getLookupPath (DetectionRange_t *self)
 Returns the lookup path where the cache files are stored.
void DetectionRange_setAnalysisMinRange (DetectionRange_t *self, double minrange)
 Sets the minrange to be processed during the analysis stage.
double DetectionRange_getAnalysisMinRange (DetectionRange_t *self)
 Returns the min radial range to be processed in the analysis stage.
void DetectionRange_setAnalysisMaxRange (DetectionRange_t *self, double maxrange)
 Sets the maxrange to be processed during the analysis stage.
double DetectionRange_getAnalysisMaxRange (DetectionRange_t *self)
 Returns the max radial range to be processed in the analysis stage.
PolarScan_tDetectionRange_top (DetectionRange_t *self, PolarVolume_t *pvol, double scale, double threshold_dBZN, char *paramname)
 Returns the echo top.
PolarScan_tDetectionRange_filter (DetectionRange_t *self, PolarScan_t *scan)
 Top field garbage should be filtered.
RaveField_tDetectionRange_analyze (DetectionRange_t *self, PolarScan_t *scan, int avgsector, double sortage, double samplepoint)
 Analyzes the detection ranges.

Variables

RaveCoreObjectType DetectionRange_TYPE
 Type definition to use when creating a rave object.

Detailed Description

Provides functionality for creating composites.

Author
Harri Hohti, FMI
Daniel Michelson, SMHI (Intgration)
Anders Henja, SMHI (Adaption to rave framework)
Date
2010-01-19

Macro Definition Documentation

◆ CONSTGRAD

#define CONSTGRAD   50.0

10 dB/km = 1000 m / 20 dBN

◆ ER

#define ER   8495000.0

effective earth radius for bin height calculations

◆ ERKM

#define ERKM   8495

effective earth radius in km

Function Documentation

◆ DetectionRange_analyze()

RaveField_t * DetectionRange_analyze ( DetectionRange_t * self,
PolarScan_t * scan,
int avgsector,
double sortage,
double samplepoint )

Analyzes the detection ranges.

Parameters
[in]avgsector- width of the floating average azimuthal sector
[in]sortage- defining the higher portion of sorted ray to be analysed, typically 0.05 - 0.2
[in]samplepoint- define the position to pick a representative TOP value from highest valid TOPs, typically near 0.5 (median) lower values (nearer to highest TOP, 0.15) used in noisier radars like KOR.
[in]self- self
[in]scan- the HGHT scan to be analyzed
[in]avgsector- width of the floating average azimuthal sector
[in]sortage- defining the higher portion of sorted ray to be analysed, typically 0.05 - 0.2
[in]samplepoint- define the position to pick a representative TOP value from highest valid TOPs, typically near 0.5 (median) lower values (nearer to highest TOP, 0.15) used in noisier radars like KOR.
Returns
the analyzed field on success otherwise NULL

Calculate previous top value

◆ DetectionRange_filter()

PolarScan_t * DetectionRange_filter ( DetectionRange_t * self,
PolarScan_t * scan )

Top field garbage should be filtered.

Parameters
[in]self- self
[in]scan- the scan to filter (after top has been calculated)
Returns
a PolarScan containing the filtered tops

◆ DetectionRange_getAnalysisMaxRange()

double DetectionRange_getAnalysisMaxRange ( DetectionRange_t * self)

Returns the max radial range to be processed in the analysis stage.

Parameters
[in]self- self
Returns
the max radial range in meters

◆ DetectionRange_getAnalysisMinRange()

double DetectionRange_getAnalysisMinRange ( DetectionRange_t * self)

Returns the min radial range to be processed in the analysis stage.

Parameters
[in]self- self
Returns
the min radial range in meters

◆ DetectionRange_getLookupPath()

const char * DetectionRange_getLookupPath ( DetectionRange_t * self)

Returns the lookup path where the cache files are stored.

Parameters
[in]self- self
Returns
the lookup path

◆ DetectionRange_setAnalysisMaxRange()

void DetectionRange_setAnalysisMaxRange ( DetectionRange_t * self,
double maxrange )

Sets the maxrange to be processed during the analysis stage.

Parameters
[in]self- self
[in]maxrange- the max radial range in meters (default is 240000.0)

◆ DetectionRange_setAnalysisMinRange()

void DetectionRange_setAnalysisMinRange ( DetectionRange_t * self,
double minrange )

Sets the minrange to be processed during the analysis stage.

Parameters
[in]self- self
[in]minrange- the min radial range in meters (default is 10000.0)

◆ DetectionRange_setLookupPath()

int DetectionRange_setLookupPath ( DetectionRange_t * self,
const char * path )

Sets the lookup path where the cache files are stored.

Parameters
[in]self- self
[in]path- the path to use for lookup tables MAY NOT BE NULL (default /tmp)
Returns
1 on success otherwise 0

◆ DetectionRange_top()

PolarScan_t * DetectionRange_top ( DetectionRange_t * self,
PolarVolume_t * pvol,
double scale,
double threshold_dBZN,
char * paramname )

Returns the echo top.

Parameters
[in]self- self
[in]pvol- the polar volume
[in]scale- the bin length
[in]threshold_dBZN- threshold for dBZN values
Returns
a PolarScan containing the echo tops

Variable Documentation

◆ DetectionRange_TYPE

RaveCoreObjectType DetectionRange_TYPE
Initial value:
= {
"DetectionRange",
DetectionRange_constructor,
DetectionRange_destructor,
DetectionRange_copyconstructor
}
struct _DetectionRange_t DetectionRange_t
Defines a Detection range generator.
Definition detection_range.h:40

Type definition to use when creating a rave object.