14 #include "eckit/config/Configuration.h"
15 #include "eckit/geometry/Point2.h"
32 : rscale_(config.getDouble(
"lengthscale")), obsdb_(obsdb)
40 eckit::geometry::Point2 center = *iterator;
41 for (
unsigned int ii=0; ii <
obsdb_.
nobs(); ++ii) {
42 double curdist = std::abs(center[0] - locations[ii]);
43 curdist = std::min(curdist, 1.-curdist);
45 locfactor[ii] = locfactor.
missing();
55 os <<
"Gaspari-Cohn localization with lengthscale=" <<
rscale_;
const double rscale_
Gaspari-Cohn localization distance (localization goes to zero at rscale_)
const ObsTable & obsdb_
ObsSpace associated with the observations.
ObsLocGC99(const eckit::Configuration &, const ObsTable &)
void print(std::ostream &) const override
void computeLocalization(const Iterator &, ObsVec1D &locfactor) const override
A Simple Observation Data Handler.
const std::vector< double > & locations() const
unsigned int nobs() const
Vector in observation space.
const double & missing() const
The namespace for the L95 model.
static oops::ObsLocalizationMaker< L95Traits, L95ObsTraits, ObsLocGC99 > makerGC_("Gaspari-Cohn")
double gc99(const double &distnorm)