HArD::Core2D
Hybrid Arbitrary Degree::Core 2D - Library to implement 2D schemes with edge and cell polynomials as unknowns
Public Types | Public Member Functions | List of all members
HArDCore2D::StochStefanPME Class Reference

The vector Xh manipulated in the resolution has mixed components, corresponding either to the unknown \(u\) or to \(\zeta(e^W u)\), depending on the choice of weight of mass-lumping for the cell/edge unknowns. If no weight is put on the edges (resp. the cells), then the edge (resp. cell) unknowns represent \(\zeta(e^W u)\). Otherwise, they represent u. More...

#include <HMM_StochTrans_StefanPME.hpp>

Public Types

using solution_function_type = TemporalSpatialFunctionType< double >
 type for solution More...
 
using source_function_type = PiecewiseSpatialFunctionType< double >
 type for source (at a given fixed time) More...
 
using grad_function_type = PiecewiseTemporalSpatialFunctionType< VectorRd >
 type for gradient More...
 
using lapl_function_type = PiecewiseTemporalSpatialFunctionType< double >
 type for laplacian More...
 
using tensor_function_type = PiecewiseSpatialFunctionType< Eigen::Matrix2d >
 type for diffusion tensor (does not depend on time) More...
 
using WienerType = SpatialFunctionType< double >
 type for the Wiener process at a fixed time (only variation in space) More...
 
using GradWienerType = SpatialFunctionType< VectorRd >
 type for gradient of Wiener process More...
 
using ReactionType = SpatialFunctionType< double >
 Type for reaction term mu^2. More...
 

Public Member Functions

 StochStefanPME (HybridCore &hmm, tensor_function_type kappa, TestCaseNonLinearity::nonlinearity_function_type zeta, BoundaryConditions BC, solution_function_type exact_solution, grad_function_type grad_exact_solution, solution_function_type time_der_exact_solution, lapl_function_type minus_Lapl_exact_solution, double weight, std::string solver_type, std::ostream &output=std::cout)
 Constructor of the class. More...
 
StochStefanPME::source_function_type compute_source (const bool &use_exact_source, const double &t, const WienerType &W, const GradWienerType &grad_W, const WienerType &Delta_exp_W, const ReactionType &mu_squared)
 Compute the source to zero or the exact one based on the selected solution and Wiener process. More...
 
std::pair< UVector, size_t > iterate (const double tps, const double dt, const UVector &Xn, const UVector &Ih_W, const WienerType &W, const ReactionType &mu_squared, const source_function_type &source)
 Execute one time iteration: return the calculated vector, and the number of Newton iterations. More...
 
void SetWienerProcess (const int &caseW, const double &t, WienerType &W, UVector &I_W, GradWienerType &grad_W, WienerType &Delta_exp_W, ReactionType &mu_squared, bool verbose=false)
 Set the Wiener process, deterministic case. More...
 
void SimulateWienerProcess (const double &dt, DoubleVector< double > &Wtime, WienerType &W, const DoubleVector< Eigen::VectorXd > &Ih_eigs, UVector &I_W, GradWienerType &grad_W, WienerType &Delta_exp_W, ReactionType &mu_squared)
 Set the Wiener process, random case. More...
 
Eigen::VectorXd apply_nonlinearity_eW (const std::string type, const Eigen::VectorXd &Y, const Eigen::VectorXd &I_W) const
 Compute non-linearity and e^W on vector Y (depends if weight=0, weight=1 or weight\in (0,1) ) More...
 
UVector apply_nonlinearity_eW (const std::string type, const UVector &Y, const Eigen::VectorXd &I_W) const
 
double L2_MassLumped (const UVector &Xh) const
 Mass-lumped L2 norm of a function given by a vector. More...
 
double Lp_MassLumped (const UVector &Xh, double p) const
 Mass-lumped Lp norm of a function given by a vector. More...
 
double EnergyNorm (const UVector &Xh) const
 Discrete energy norm (associated to the diffusion operator) More...
 
double Integral (const UVector &Xh) const
 Integral of a function given by a vector. More...
 
double get_assembly_time () const
 cpu time to assemble the scheme More...
 
double get_solution_time () const
 cpu time to solve the linear systems More...
 
double get_itime (size_t idx) const
 various intermediate assembly times More...
 
double get_solving_error () const
 residual after solving the scheme More...
 
Eigen::MatrixXd get_MassT (size_t iT) const
 Mass matrix in cell iT. More...
 

Detailed Description

The vector Xh manipulated in the resolution has mixed components, corresponding either to the unknown \(u\) or to \(\zeta(e^W u)\), depending on the choice of weight of mass-lumping for the cell/edge unknowns. If no weight is put on the edges (resp. the cells), then the edge (resp. cell) unknowns represent \(\zeta(e^W u)\). Otherwise, they represent u.


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