PISM, A Parallel Ice Sheet Model  stable v2.1-1-g6902d5502 committed by Ed Bueler on 2023-12-20 08:38:27 -0800
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
pism::stressbalance::BedSmoother Class Reference

PISM bed smoother, plus bed roughness parameterization, based on Schoof (2003). More...

#include <BedSmoother.hh>

Public Member Functions

 BedSmoother (std::shared_ptr< const Grid > g)
 
virtual ~BedSmoother ()=default
 
void preprocess_bed (const array::Scalar &topg)
 
void smoothed_thk (const array::Scalar &usurf, const array::Scalar &thk, const array::CellType2 &mask, array::Scalar &thksmooth) const
 Computes a smoothed thickness map. More...
 
void theta (const array::Scalar &usurf, array::Scalar &result) const
 
const array::Scalarsmoothed_bed () const
 

Protected Member Functions

void preprocess_bed (const array::Scalar &topg, unsigned int Nx_in, unsigned int Ny_in)
 
void smooth_the_bed_on_proc0 ()
 Computes the smoothed bed by a simple average over a rectangle of grid points. More...
 
void compute_coefficients_on_proc0 ()
 

Protected Attributes

std::shared_ptr< const Gridm_grid
 
const Config::ConstPtr m_config
 
array::Scalar2 m_topgsmooth
 smoothed bed elevation; set by calling preprocess_bed() More...
 
array::Scalar2 m_maxtl
 
array::Scalar2 m_C2
 
array::Scalar2 m_C3
 
array::Scalar2 m_C4
 
int m_Nx
 
int m_Ny
 
double m_Glen_exponent
 
double m_smoothing_range
 
std::shared_ptr< petsc::Vecm_topgp0
 original bed elevation on processor 0 More...
 
std::shared_ptr< petsc::Vecm_topgsmoothp0
 smoothed bed elevation on processor 0 More...
 
std::shared_ptr< petsc::Vecm_maxtlp0
 maximum elevation at (i,j) of local topography (nearby patch) More...
 
std::shared_ptr< petsc::Vecm_C2p0
 
std::shared_ptr< petsc::Vecm_C3p0
 
std::shared_ptr< petsc::Vecm_C4p0
 

Detailed Description

PISM bed smoother, plus bed roughness parameterization, based on Schoof (2003).

This class both smooths the bed and computes coefficients for an approximation to Schoof's \(\theta\). The factor \(0\le \theta \le 1\) multiplies the diffusivity in the theory of the effect of bed roughness in the SIA by Christian Schoof (2003; The effect of basal topography on ice sheet dynamics) [Schoofbasaltopg2003].

For additional information on this class see page bedrough.

The user of this class hands BedSmoother an "original" topography, and it is preprocessed to fill the smoothed topography topgsmooth, and the coefficients in an approximation to \(\theta\). This is done by a call to preprocess_bed(). The call requires the half-width of the smoothing square (a distance in m), or the number of grid points in each direction in the smoothing rectangle, and the Glen exponent.

The call to preprocess_bed() must be repeated any time the "original" topography changes, for instance at the start of an IceModel run, or at a bed deformation step in an IceModel run.

BedSmoother then provides three major functionalities, all of which must follow the call to preprocess_bed():

  1. User accesses public array::Scalar topgsmooth, the smoothed bed itself.
  2. User asks get_smoothed_thk() for gridded values of the consistent smoothed version of the ice thickness, which is the thickness corresponding to a given surface elevation and the pre-computed smoothed bed.
  3. User asks for gridded values of \(\theta(h,x,y)\) using get_theta().

Here is a basic example of the creation and usage of a BedSmoother instance. Note that BedSmoother will update ghosted values in topgsmooth, and other internal fields, and update them in the return fields thksmooth, theta, if asked. In IceModel::velocitySIAStaggered()

BedSmoother smoother(grid, 2);
const double n = 3.0,
lambda = 50.0e3;
ierr = smoother.preprocess_bed(topg, n, lambda); CHKERRQ(ierr);
ierr = smoother.get_smoothed_thk(usurf, thk, 1, &thksmooth); CHKERRQ(ierr);
ierr = smoother.get_theta(usurf, n, 1, &theta); CHKERRQ(ierr);
BedSmoother(std::shared_ptr< const Grid > g)
Definition: BedSmoother.cc:34
void theta(const array::Scalar &usurf, array::Scalar &result) const
Definition: BedSmoother.cc:350
#define n
Definition: exactTestM.c:37

See Grid documentation for initializing grid. Note we assume topg, usurf, thk, thksmooth, and theta are all created array::Scalar instances.

Definition at line 85 of file BedSmoother.hh.


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