PISM, A Parallel Ice Sheet Model 2.2.2-d6b3a29ca committed by Constantine Khrulev on 2025-03-28
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Classes | Public Member Functions | Private Member Functions | Static Private Member Functions | Private Attributes | List of all members
pism::stressbalance::SSAFD_SNES Class Reference

#include <SSAFD_SNES.hh>

+ Inheritance diagram for pism::stressbalance::SSAFD_SNES:

Classes

struct  CallbackData
 

Public Member Functions

 SSAFD_SNES (std::shared_ptr< const Grid > grid, bool regional_mode)
 
void solve (const Inputs &inputs)
 
double tolerance () const
 
const array::Vectorresidual () const
 
- Public Member Functions inherited from pism::stressbalance::SSAFDBase
 SSAFDBase (std::shared_ptr< const Grid > g, bool regional_mode)
 
const array::Staggeredintegrated_viscosity () const
 
const array::Vectordriving_stress () const
 
void compute_residual (const Inputs &inputs, const array::Vector2 &velocity, array::Vector &result)
 
- Public Member Functions inherited from pism::stressbalance::SSA
 SSA (std::shared_ptr< const Grid > g)
 
virtual ~SSA ()
 
virtual void update (const Inputs &inputs, bool full_update)
 Update the SSA solution.
 
virtual std::string stdout_report () const
 Produce a report string for the standard output.
 
- Public Member Functions inherited from pism::stressbalance::ShallowStressBalance
 ShallowStressBalance (std::shared_ptr< const Grid > g)
 
virtual ~ShallowStressBalance ()
 
void init ()
 
const array::Vector1velocity () const
 Get the thickness-advective 2D velocity.
 
const array::Scalarbasal_frictional_heating ()
 Get the basal frictional heating (for the adaptive energy time-stepping).
 
void compute_basal_frictional_heating (const array::Vector &velocity, const array::Scalar &tauc, const array::CellType &mask, array::Scalar &result) const
 Compute the basal frictional heating.
 
std::shared_ptr< const rheology::FlowLawflow_law () const
 
EnthalpyConverter::Ptr enthalpy_converter () const
 
const IceBasalResistancePlasticLawsliding_law () const
 
double flow_enhancement_factor () const
 
- Public Member Functions inherited from pism::Component
 Component (std::shared_ptr< const Grid > grid)
 
virtual ~Component ()=default
 
DiagnosticList diagnostics () const
 
TSDiagnosticList ts_diagnostics () const
 
std::shared_ptr< const Gridgrid () const
 
const Timetime () const
 
const Profilingprofiling () const
 
void define_model_state (const File &output) const
 Define model state variables in an output file.
 
void write_model_state (const File &output) const
 Write model state variables to an output file.
 
MaxTimestep max_timestep (double t) const
 Reports the maximum time-step the model can take at time t.
 

Private Member Functions

DiagnosticList diagnostics_impl () const
 
void compute_jacobian (const Inputs &inputs, Vector2d const *const *velocity, Mat J)
 

Static Private Member Functions

static PetscErrorCode function_callback (DMDALocalInfo *info, Vector2d const *const *velocity, Vector2d **result, CallbackData *)
 
static PetscErrorCode jacobian_callback (DMDALocalInfo *info, Vector2d const *const *velocity, Mat A, Mat J, CallbackData *data)
 

Private Attributes

array::Vector m_residual
 residual (diagnostic)
 
petsc::SNES m_snes
 
petsc::DM::Ptr m_DA
 
CallbackData m_callback_data
 

Additional Inherited Members

- Public Attributes inherited from pism::stressbalance::SSA
SSAStrengthExtensionstrength_extension
 
- Protected Types inherited from pism::Component
enum  RegriddingFlag { REGRID_WITHOUT_REGRID_VARS , NO_REGRID_WITHOUT_REGRID_VARS }
 This flag determines whether a variable is read from the -regrid_file file even if it is not listed among variables in -regrid_vars. More...
 
- Protected Member Functions inherited from pism::stressbalance::SSAFDBase
DiagnosticList diagnostics_impl () const
 
void initialize_iterations (const Inputs &inputs)
 
void compute_nuH (const array::Scalar1 &ice_thickness, const array::CellType2 &cell_type, const pism::Vector2d *const *velocity, const array::Staggered &hardness, double nuH_regularization, array::Staggered1 &result)
 
void compute_nuH_everywhere (const array::Scalar1 &ice_thickness, const pism::Vector2d *const *velocity, const array::Staggered &hardness, double nuH_regularization, array::Staggered &result)
 Compute the product of ice thickness and effective viscosity (on the staggered grid).
 
void compute_nuH_cfbc (const array::Scalar1 &ice_thickness, const array::CellType2 &cell_type, const pism::Vector2d *const *velocity, const array::Staggered &hardness, double nuH_regularization, array::Staggered &result)
 Compute the product of ice viscosity and thickness on the staggered grid. Used when CFBC is enabled.
 
void compute_driving_stress (const array::Scalar &ice_thickness, const array::Scalar1 &surface_elevation, const array::CellType1 &cell_type, const array::Scalar1 *no_model_mask, const EnthalpyConverter &EC, array::Vector &result) const
 Compute the gravitational driving stress.
 
void adjust_driving_stress (const array::Scalar &ice_thickness, const array::Scalar1 &surface_elevation, const array::CellType1 &cell_type, const array::Scalar1 *no_model_mask, array::Vector &driving_stress) const
 
void compute_average_ice_hardness (const array::Scalar1 &thickness, const array::Array3D &enthalpy, const array::CellType1 &cell_type, array::Staggered &result) const
 Computes vertically-averaged ice hardness on the staggered grid.
 
void assemble_rhs (const Inputs &inputs, const array::CellType1 &cell_type, const array::Vector &driving_stress, double bc_scaling, array::Vector &result) const
 Computes the right-hand side ("rhs") of the linear problem for the Picard iteration and finite-difference implementation of the SSA equations.
 
void fd_operator (const Geometry &geometry, const array::Scalar *bc_mask, double bc_scaling, const array::Scalar &basal_yield_stress, IceBasalResistancePlasticLaw *basal_sliding_law, const pism::Vector2d *const *velocity, const array::Staggered1 &nuH, const array::CellType1 &cell_type, Mat *A, Vector2d **Ax) const
 Assemble the left-hand side matrix for the KSP-based, Picard iteration, and finite difference implementation of the SSA equations.
 
void fracture_induced_softening (const array::Scalar1 &fracture_density, double n_glen, array::Staggered &ice_hardness)
 Correct vertically-averaged hardness using a parameterization of the fracture-induced softening.
 
void compute_residual (const Inputs &inputs, const pism::Vector2d *const *velocity, pism::Vector2d **result)
 
- Protected Member Functions inherited from pism::stressbalance::SSA
virtual void define_model_state_impl (const File &output) const
 The default (empty implementation).
 
virtual void write_model_state_impl (const File &output) const
 The default (empty implementation).
 
virtual void init_impl ()
 Initialize a generic regular-grid SSA solver.
 
void extrapolate_velocity (const array::CellType1 &cell_type, array::Vector1 &velocity) const
 
- Protected Member Functions inherited from pism::Component
virtual MaxTimestep max_timestep_impl (double t) const
 
virtual TSDiagnosticList ts_diagnostics_impl () const
 
void regrid (const std::string &module_name, array::Array &variable, RegriddingFlag flag=NO_REGRID_WITHOUT_REGRID_VARS)
 
- Protected Attributes inherited from pism::stressbalance::SSAFDBase
array::Array2D< Workm_work
 
array::Staggered m_hardness
 ice hardness
 
array::Staggered1 m_nuH
 viscosity times thickness
 
array::CellType2 m_cell_type
 
array::Vector m_rhs
 right hand side
 
array::Vector m_taud
 driving stress
 
const double m_bc_scaling
 scaling used for diagonal matrix elements at Dirichlet BC locations
 
const bool m_regional_mode
 
- Protected Attributes inherited from pism::stressbalance::SSA
std::string m_stdout_ssa
 
array::Vector m_velocity_global
 
- Protected Attributes inherited from pism::stressbalance::ShallowStressBalance
IceBasalResistancePlasticLawm_basal_sliding_law
 
std::shared_ptr< rheology::FlowLawm_flow_law
 
EnthalpyConverter::Ptr m_EC
 
array::Vector2 m_velocity
 
array::Scalar m_basal_frictional_heating
 
double m_e_factor
 flow enhancement factor
 
- Protected Attributes inherited from pism::Component
const std::shared_ptr< const Gridm_grid
 grid used by this component
 
const Config::ConstPtr m_config
 configuration database used by this component
 
const units::System::Ptr m_sys
 unit system used by this component
 
const Logger::ConstPtr m_log
 logger (for easy access)
 

Detailed Description

Definition at line 32 of file SSAFD_SNES.hh.


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