FV3 Bundle
ObsStericHeightTLAD.cc
Go to the documentation of this file.
1 /*
2  * (C) Copyright 2017-2018 UCAR
3  *
4  * This software is licensed under the terms of the Apache Licence Version 2.0
5  * which can be obtained at http://www.apache.org/licenses/LICENSE-2.0.
6  */
7 
9 
10 #include <ostream>
11 #include <string>
12 #include <vector>
13 
14 #include "ioda/ObsVector.h"
15 
16 #include "oops/base/Variables.h"
17 #include "oops/util/Logger.h"
18 
19 #include "ufo/GeoVaLs.h"
20 #include "ufo/ObsBias.h"
21 
22 namespace ufo {
23 
24 // -----------------------------------------------------------------------------
25 static LinearObsOperatorMaker<ObsStericHeightTLAD> makerObsStericHeightTLAD_("ObsStericHeightTLAD");
26 // -----------------------------------------------------------------------------
27 
29  const eckit::Configuration & config)
30  : keyOperStericHeight_(0), varin_(), traj_()
31  {
32  std::cout << "steric height tlad =============================" << std::endl;
33  const eckit::Configuration * configc = &config;
35  const std::vector<std::string> vv{"sea_surface_height_above_geoid",
36  "ocean_potential_temperature",
37  "ocean_salinity"};
38  varin_.reset(new oops::Variables(vv));
39  traj_.reset(new GeoVaLs(config, oops::Variables(vv)));
40 
42  GeoVaLs traj(config, vars);
43  // ufo_stericheight_tlad_gettraj_f90(keyOperStericHeight_, odb.nobs(), vars.toFortran(),
44  // traj.toFortran());
45  oops::Log::trace() << "ObsStericHeightTLAD created" << std::endl;
46  }
47 
48  // -----------------------------------------------------------------------------
49 
52  oops::Log::trace() << "ObsStericHeightTLAD destrcuted" << std::endl;
53  }
54 
55  // -----------------------------------------------------------------------------
56 
57  void ObsStericHeightTLAD::setTrajectory(const GeoVaLs & geovals, const ObsBias & bias) {
58  std::cout << "steric height tlad settraj =============================" << std::endl;
60  oops::Log::trace() << "ObsStericHeightTLAD trajectory was set " << geovals << std::endl;
61  }
62 
63  // -----------------------------------------------------------------------------
64 
66  const ObsBiasIncrement & bias) const {
68  ovec.size(), ovec.toFortran());
69  }
70 
71  // -----------------------------------------------------------------------------
72 
74  ObsBiasIncrement & bias) const {
76  ovec.size(), ovec.toFortran());
77  }
78 
79  // -----------------------------------------------------------------------------
80 
81  void ObsStericHeightTLAD::print(std::ostream & os) const {
82  os << "ObsStericHeightTLAD::print not implemented" << std::endl;
83  }
84 
85  // -----------------------------------------------------------------------------
86 
87 } // namespace ufo
void ufo_stericheight_tlad_settraj_f90(const F90hop &, const F90goms &)
void simulateObsAD(GeoVaLs &, const ioda::ObsVector &, ObsBiasIncrement &) const
std::size_t size() const
ObsVector class to handle vectors in observation space for IODA.
static LinearObsOperatorMaker< ObsStericHeightTLAD > makerObsStericHeightTLAD_("ObsStericHeightTLAD")
void ufo_stericheight_simobs_ad_f90(const F90hop &, const F90goms &, const int &, const double &)
void ufo_stericheight_tlad_delete_f90(F90hop &)
void ufo_stericheight_tlad_setup_f90(F90hop &, const eckit::Configuration *const *)
void print(std::ostream &) const
const double & toFortran() const
void ufo_stericheight_simobs_tl_f90(const F90hop &, const F90goms &, const int &, const double &)
Wrapper around ObsHelpQG, mostly to hide the factory.
GeoVaLs: geophysical values at locations.
void setTrajectory(const GeoVaLs &, const ObsBias &)
Obs Operator.
void simulateObsTL(const GeoVaLs &, ioda::ObsVector &, const ObsBiasIncrement &) const
boost::scoped_ptr< const GeoVaLs > traj_
ObsStericHeightTLAD(const ioda::ObsSpace &, const eckit::Configuration &)
Class to handle observation bias parameters.
boost::scoped_ptr< const oops::Variables > varin_