Gridpp 0.8.0
A post-processing library for gridded weather forecasts
Public Member Functions | List of all members
gridpp::SoarStructure Class Reference

#include <gridpp.h>

Inheritance diagram for gridpp::SoarStructure:
gridpp::StructureFunction

Public Member Functions

StructureFunctionPtr clone () const
 
float corr (const Point &p1, const Point &p2) const
 Correlation between two points. More...
 
vec corr (const Point &p1, const std::vector< Point > &p2) const
 
float localization_distance (const Point &p) const
 Maximum distance for which an observation can have an impact (localization) More...
 
 SoarStructure (float h, float v=0, float w=0, float hmax=MV)
 Exponential structure function. More...
 
 SoarStructure (Grid grid, vec2 h, vec2 v, vec2 w, float min_rho=StructureFunction::default_min_rho)
 Soar structure function where decorrelation varyies spatially. More...
 
- Public Member Functions inherited from gridpp::StructureFunction
virtual float corr_background (const Point &p1, const Point &p2) const
 Correlation between a background point and an observation points. More...
 
virtual vec corr_background (const Point &p1, const std::vector< Point > &p2) const
 
 StructureFunction (float localization_distance=0)
 

Additional Inherited Members

- Static Public Attributes inherited from gridpp::StructureFunction
static const float default_min_rho = 0.0013
 
- Protected Member Functions inherited from gridpp::StructureFunction
float barnes_rho (float dist, float length) const
 Barnes correlation function. More...
 
float cressman_rho (float dist, float length) const
 Cressman correlation function. More...
 
float linear_rho (float diff, float min_corr) const
 Linear correlation function. More...
 
float powerlaw_rho (float dist, float length) const
 Powerlaw correlation function. More...
 
float soar_rho (float dist, float length) const
 Compactly supported second-order autoregressive correlation function. More...
 
float toar_rho (float dist, float length) const
 Compactly supported third-order autoregressive correlation function. More...
 
- Protected Attributes inherited from gridpp::StructureFunction
float m_localization_distance
 

Detailed Description

SOAR structure function based on distance, elevation, and land area fraction.

Constructor & Destructor Documentation

◆ SoarStructure() [1/2]

gridpp::SoarStructure::SoarStructure ( float  h,
float  v = 0,
float  w = 0,
float  hmax = MV 
)

Exponential structure function.

SOAR.

Parameters
hHorizontal decorrelation length >=0 [m]
vVertical decorrelation length >=0 [m]. If 0, disable decorrelation.
wLand/sea decorrelation length >=0 [1]. If 0, disable decorrelation.
hmaxTruncate horizontal correlation beyond this length [m]. If undefined, 3.64 * h.

◆ SoarStructure() [2/2]

gridpp::SoarStructure::SoarStructure ( Grid  grid,
vec2  h,
vec2  v,
vec2  w,
float  min_rho = StructureFunction::default_min_rho 
)

Soar structure function where decorrelation varyies spatially.

Parameters
gridGrid of decorrelation field
h2D vector of horizontal decorrelation lengths >=0, same size as grid [m]
v2D vector of Vertical decorrelation lengths >=0 [m]. Set all to 0 to disable decorrelation.
w2D vector of land/sea decorrelation lengths >=0 [1]. Set all to 0 to disable decorrelation.
min_rhoTruncate horizontal correlation when rho is less than this value [m].

Member Function Documentation

◆ clone()

gridpp::StructureFunctionPtr gridpp::SoarStructure::clone ( ) const
virtual

◆ corr() [1/2]

float gridpp::SoarStructure::corr ( const Point &  p1,
const Point &  p2 
) const
virtual

Correlation between two points.

Parameters
p1First point
p2Other point
Returns
Correlation between points

Implements gridpp::StructureFunction.

◆ corr() [2/2]

vec gridpp::SoarStructure::corr ( const Point &  p1,
const std::vector< Point > &  p2 
) const
virtual

Reimplemented from gridpp::StructureFunction.

◆ localization_distance()

float gridpp::SoarStructure::localization_distance ( const Point &  p) const
virtual

Maximum distance for which an observation can have an impact (localization)

Returns
Distance [m]

Reimplemented from gridpp::StructureFunction.


The documentation for this class was generated from the following files: