FV3 Bundle
ModelFV3JEDI.cc
Go to the documentation of this file.
1 /*
2  * (C) Copyright 2017 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 
8 #include <vector>
9 
10 #include "eckit/config/Configuration.h"
11 
12 #include "oops/util/DateTime.h"
13 #include "oops/util/Logger.h"
14 
15 #include "ModelFV3JEDIFortran.h"
16 #include "GeometryFV3JEDI.h"
17 #include "ModelBiasFV3JEDI.h"
18 #include "src/Model/ModelFV3JEDI.h"
19 #include "StateFV3JEDI.h"
20 #include "UtilitiesFV3JEDI.h"
21 
22 namespace fv3jedi {
23 // -----------------------------------------------------------------------------
25 // -----------------------------------------------------------------------------
27  const eckit::Configuration & model)
28  : keyConfig_(0), tstep_(0), geom_(resol),
29  vars_(std::vector<std::string>{"ud", "vd", "ua", "va", "t", "delp",
30  "q", "qi", "ql", "o3"})
31 {
32  oops::Log::trace() << "ModelFV3JEDI::ModelFV3JEDI" << std::endl;
33  tstep_ = util::Duration(model.getString("tstep"));
34  const eckit::Configuration * configc = &model;
36  fv3jedi_model_create_f90(&configc, geom_.toFortran(), keyConfig_);
38  oops::Log::trace() << "ModelFV3JEDI created" << std::endl;
39 }
40 // -----------------------------------------------------------------------------
43  oops::Log::trace() << "ModelFV3JEDI destructed" << std::endl;
44 }
45 // -----------------------------------------------------------------------------
48  oops::Log::debug() << "ModelFV3JEDI::initialize" << std::endl;
49 }
50 // -----------------------------------------------------------------------------
52  xx.validTime() += tstep_;
53  util::DateTime * dtp = &xx.validTime();
55  oops::Log::debug() << "ModelFV3JEDI::step" << std::endl;
56 }
57 // -----------------------------------------------------------------------------
60  oops::Log::debug() << "ModelFV3JEDI::finalize" << std::endl;
61 }
62 // -----------------------------------------------------------------------------
64  const ModelBiasFV3JEDI &) const {
65  int ftraj = 0;
67  ASSERT(ftraj != 0);
68  return ftraj;
69 }
70 // -----------------------------------------------------------------------------
71 void ModelFV3JEDI::print(std::ostream & os) const {
72  os << "ModelFV3JEDI::print not implemented";
73 }
74 // -----------------------------------------------------------------------------
75 } // namespace fv3jedi
void fv3jedi_model_create_f90(const eckit::Configuration *const *, const F90geom &, F90model &)
void removeFv3Files()
void stageFv3Files(const eckit::Configuration &conf)
void step(StateFV3JEDI &, const ModelBiasFV3JEDI &) const
Model integration.
Definition: ModelFV3JEDI.cc:51
void fv3jedi_model_step_f90(const F90model &, const F90state &, util::DateTime *const *)
void finalize(StateFV3JEDI &) const
Finish model integration.
Definition: ModelFV3JEDI.cc:58
subroutine std(a, mean, stdv, area)
void fv3jedi_model_initialize_f90(const F90model &, const F90state &)
void print(std::ostream &) const
Definition: ModelFV3JEDI.cc:71
Model error for the FV3JEDI model.
void initialize(StateFV3JEDI &) const
Prepare model integration.
Definition: ModelFV3JEDI.cc:46
logical debug
Definition: mpp.F90:1297
void fv3jedi_model_delete_f90(F90model &)
const util::DateTime & validTime() const
Definition: StateFV3JEDI.h:91
util::Duration tstep_
Definition: ModelFV3JEDI.h:68
ModelFV3JEDI(const GeometryFV3JEDI &, const eckit::Configuration &)
Definition: ModelFV3JEDI.cc:26
void fv3jedi_traj_prop_f90(const F90model &, const F90state &, F90traj &)
int saveTrajectory(StateFV3JEDI &, const ModelBiasFV3JEDI &) const
Definition: ModelFV3JEDI.cc:63
GeometryFV3JEDI handles geometry for FV3JEDI model.
void fv3jedi_model_finalize_f90(const F90model &, const F90inc &)
static oops::ModelMaker< FV3JEDITraits, ModelFV3JEDI > makermodel_("FV3JEDI")