20 #include "pism/earth/Given.hh"
21 #include "pism/util/array/Forcing.hh"
28 m_topg_reference(grid,
"topg") {
35 auto filename =
m_config->get_string(
"bed_deformation.given.file");
38 unsigned int buffer_size =
m_config->get_number(
"input.forcing.buffer_size");
41 bool periodic =
false;
47 buffer_size, periodic,
LINEAR);
49 .long_name(
"two-dimensional bed elevation changes")
57 (void) sea_level_elevation;
60 "* Initializing the bed model using a given topography change history...\n");
65 auto reference_filename =
m_config->get_string(
"bed_deformation.given.reference_file");
70 auto filename =
m_config->get_string(
"bed_deformation.given.file");
77 double t,
double dt) {
79 (void) sea_level_elevation;
const Config::ConstPtr m_config
configuration database used by this component
const Logger::ConstPtr m_log
logger (for easy access)
const std::shared_ptr< const Grid > m_grid
grid used by this component
High-level PISM I/O class.
void copy_from(const Array2D< T > &source)
void add(double alpha, const Array2D< T > &x)
void regrid(const std::string &filename, io::Default default_value)
SpatialVariableMetadata & metadata(unsigned int N=0)
Returns a reference to the SpatialVariableMetadata object containing metadata for the compoment N.
array::Scalar2 m_topg_last
bed elevation at the time of the last update
array::Scalar2 m_topg
current bed elevation
virtual void init_impl(const InputOptions &opts, const array::Scalar &ice_thickness, const array::Scalar &sea_level_elevation)
Initialize from the context (input file and the "variables" database).
array::Scalar m_uplift
bed uplift rate
void compute_uplift(const array::Scalar &bed, const array::Scalar &bed_last, double dt, array::Scalar &result)
Compute bed uplift (dt is in seconds).
PISM bed deformation model (base class).
void update_impl(const array::Scalar &ice_thickness, const array::Scalar &sea_level_elevation, double t, double dt)
array::Scalar m_topg_reference
std::shared_ptr< array::Forcing > m_topg_delta
Given(std::shared_ptr< const Grid > grid)
void init_impl(const InputOptions &opts, const array::Scalar &ice_thickness, const array::Scalar &sea_level_elevation)
Initialize from the context (input file and the "variables" database).
@ PISM_READONLY
open an existing file for reading only