Commit 4415d734 authored by jannick.wolters's avatar jannick.wolters
Browse files

added solver init for csdpn

parent 0fc22f3d
Pipeline #142889 passed with stage
in 20 minutes and 28 seconds
......@@ -115,6 +115,7 @@ enum SOLVER_NAME {
CSD_SN_FOKKERPLANCK_TRAFO_SOLVER,
CSD_SN_FOKKERPLANCK_TRAFO_SOLVER_2D,
CSD_SN_FOKKERPLANCK_TRAFO_SH_SOLVER_2D,
CSD_PN_SOLVER,
PN_SOLVER,
MN_SOLVER
};
......@@ -126,6 +127,7 @@ inline std::map<std::string, SOLVER_NAME> Solver_Map{ { "SN_SOLVER", SN_SOLVER }
{ "CSD_SN_FOKKERPLANCK_TRAFO_SOLVER", CSD_SN_FOKKERPLANCK_TRAFO_SOLVER },
{ "CSD_SN_FOKKERPLANCK_TRAFO_SOLVER_2D", CSD_SN_FOKKERPLANCK_TRAFO_SOLVER_2D },
{ "CSD_SN_FOKKERPLANCK_TRAFO_SH_SOLVER_2D", CSD_SN_FOKKERPLANCK_TRAFO_SH_SOLVER_2D },
{ "CSD_PN", CSD_PN_SOLVER },
{ "PN_SOLVER", PN_SOLVER },
{ "MN_SOLVER", MN_SOLVER } };
......
OUTPUT_DIR = ../result
OUTPUT_FILE = IsotropicPointSource_sph_nq6
LOG_DIR = ../result/logs
MESH_FILE = phantom2D_fine.su2
MESH_FILE = meshes/phantom2D.su2
PROBLEM = ISOTROPICPOINTSOURCE2D
SOLVER = CSD_SN_FOKKERPLANCK_TRAFO_SH_SOLVER_2D
CONTINUOUS_SLOWING_DOWN = YES
SOLVER = CSD_PN
HYDROGEN_FILE = ENDL_H.txt
OXYGEN_FILE = ENDL_O.txt
KERNEL = ISOTROPIC
......
......@@ -6,6 +6,7 @@
#include "fluxes/numericalflux.h"
#include "problems/problembase.h"
#include "quadratures/quadraturebase.h"
#include "solvers/csdpnsolver.h"
#include "solvers/csdsnsolver.h"
#include "solvers/csdsolvertrafofp.h"
#include "solvers/csdsolvertrafofp2d.h"
......@@ -110,6 +111,7 @@ SolverBase* SolverBase::Create( Config* settings ) {
case CSD_SN_FOKKERPLANCK_TRAFO_SOLVER: return new CSDSolverTrafoFP( settings );
case CSD_SN_FOKKERPLANCK_TRAFO_SOLVER_2D: return new CSDSolverTrafoFP2D( settings );
case CSD_SN_FOKKERPLANCK_TRAFO_SH_SOLVER_2D: return new CSDSolverTrafoFPSH2D( settings );
case CSD_PN_SOLVER: return new CSDPNSolver( settings );
default: ErrorMessages::Error( "Creator for the chosen solver does not yet exist. This is is the fault of the coder!", CURRENT_FUNCTION );
}
ErrorMessages::Error( "Creator for the chosen solver does not yet exist. This is is the fault of the coder!", CURRENT_FUNCTION );
......
......@@ -53,7 +53,7 @@ double Interpolation::operator()( double x ) const {
// Check whether 1D
if( _dim != 1u ) ErrorMessages::Error( "Invalid data dimension for operator(x)!", CURRENT_FUNCTION );
// x must be between min and max of table values
if( x < _x[0] || x > _x[_x.size() - 1u] ) {
if( ( x < _x[0] || x > _x[_x.size() - 1u] ) && _type != linear ) {
// std::cout << x << "\t" << _x[0] << std::endl;
// std::cout << x << "\t" << _x[_x.size() - 1u] << std::endl;
ErrorMessages::Error( "Extrapolation is not supported!", CURRENT_FUNCTION );
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment