Loading examples/heat-equation/tnl-heat-equation-eoc.h +3 −2 Original line number Diff line number Diff line Loading @@ -44,7 +44,8 @@ template< typename Real, typename Index, typename MeshType, typename MeshConfig, typename SolverStarter > typename SolverStarter, typename CommunicatorType > class heatEquationSetter { public: Loading @@ -64,7 +65,7 @@ class heatEquationSetter typedef HeatEquationEocRhs< ExactOperator, TestFunction > RightHandSide; typedef Containers::StaticVector < MeshType::getMeshDimension(), Real > Point; typedef Operators::DirichletBoundaryConditions< MeshType, TestFunction, Dimension, Real, Index > BoundaryConditions; typedef HeatEquationEocProblem< MeshType, BoundaryConditions, RightHandSide, ApproximateOperator > Solver; typedef HeatEquationEocProblem< MeshType, BoundaryConditions, RightHandSide, CommunicatorType, ApproximateOperator > Solver; SolverStarter solverStarter; return solverStarter.template run< Solver >( parameters ); }; Loading examples/inviscid-flow/euler.h +6 −5 Original line number Diff line number Diff line Loading @@ -51,7 +51,8 @@ template< typename Real, typename Index, typename MeshType, typename ConfigTag, typename SolverStarter > typename SolverStarter, typename CommunicatorType > class eulerSetter { public: Loading Loading @@ -79,12 +80,12 @@ class eulerSetter if( boundaryConditionsType == "dirichlet" ) { typedef Operators::DirichletBoundaryConditions< MeshType, Constant, MeshType::getMeshDimension(), Real, Index > BoundaryConditions; typedef eulerProblem< MeshType, BoundaryConditions, RightHandSide, ApproximateOperator > Problem; typedef eulerProblem< MeshType, BoundaryConditions, RightHandSide, CommunicatorType, ApproximateOperator > Problem; SolverStarter solverStarter; return solverStarter.template run< Problem >( parameters ); } typedef Operators::NeumannBoundaryConditions< MeshType, Constant, Real, Index > BoundaryConditions; typedef eulerProblem< MeshType, BoundaryConditions, RightHandSide, ApproximateOperator > Problem; typedef eulerProblem< MeshType, BoundaryConditions, RightHandSide, CommunicatorType, ApproximateOperator > Problem; SolverStarter solverStarter; return solverStarter.template run< Problem >( parameters ); } Loading @@ -92,12 +93,12 @@ class eulerSetter if( boundaryConditionsType == "dirichlet" ) { typedef Operators::DirichletBoundaryConditions< MeshType, MeshFunction, MeshType::getMeshDimension(), Real, Index > BoundaryConditions; typedef eulerProblem< MeshType, BoundaryConditions, RightHandSide, ApproximateOperator > Problem; typedef eulerProblem< MeshType, BoundaryConditions, RightHandSide, CommunicatorType, ApproximateOperator> Problem; SolverStarter solverStarter; return solverStarter.template run< Problem >( parameters ); } typedef Operators::NeumannBoundaryConditions< MeshType, MeshFunction, Real, Index > BoundaryConditions; typedef eulerProblem< MeshType, BoundaryConditions, RightHandSide, ApproximateOperator > Problem; typedef eulerProblem< MeshType, BoundaryConditions, RightHandSide, CommunicatorType ,ApproximateOperator > Problem; SolverStarter solverStarter; return solverStarter.template run< Problem >( parameters ); } Loading examples/inviscid-flow/eulerProblem.h +3 −0 Original line number Diff line number Diff line Loading @@ -22,6 +22,7 @@ namespace TNL { template< typename Mesh, typename BoundaryCondition, typename RightHandSide, typename CommType, typename InviscidOperators > class eulerProblem: public PDEProblem< Mesh, Loading @@ -36,6 +37,8 @@ class eulerProblem: typedef typename InviscidOperators::IndexType IndexType; typedef PDEProblem< Mesh, RealType, DeviceType, IndexType > BaseType; typedef CommType CommunicatorType; using typename BaseType::MeshType; using typename BaseType::MeshPointer; using typename BaseType::DofVectorType; Loading examples/inviscid-flow/eulerProblem_impl.h +30 −18 Original line number Diff line number Diff line Loading @@ -33,9 +33,10 @@ namespace TNL { template< typename Mesh, typename BoundaryCondition, typename RightHandSide, typename CommType, typename InviscidOperators > String eulerProblem< Mesh, BoundaryCondition, RightHandSide, InviscidOperators >:: eulerProblem< Mesh, BoundaryCondition, RightHandSide, CommType, InviscidOperators >:: getTypeStatic() { return String( "eulerProblem< " ) + Mesh :: getTypeStatic() + " >"; Loading @@ -44,9 +45,10 @@ getTypeStatic() template< typename Mesh, typename BoundaryCondition, typename RightHandSide, typename CommType, typename InviscidOperators > String eulerProblem< Mesh, BoundaryCondition, RightHandSide, InviscidOperators >:: eulerProblem< Mesh, BoundaryCondition, RightHandSide, CommType, InviscidOperators >:: getPrologHeader() const { return String( "Inviscid flow solver" ); Loading @@ -55,9 +57,10 @@ getPrologHeader() const template< typename Mesh, typename BoundaryCondition, typename RightHandSide, typename CommType, typename InviscidOperators > void eulerProblem< Mesh, BoundaryCondition, RightHandSide, InviscidOperators >:: eulerProblem< Mesh, BoundaryCondition, RightHandSide, CommType, InviscidOperators >:: writeProlog( Logger& logger, const Config::ParameterContainer& parameters ) const { /**** Loading @@ -69,9 +72,10 @@ writeProlog( Logger& logger, const Config::ParameterContainer& parameters ) cons template< typename Mesh, typename BoundaryCondition, typename RightHandSide, typename CommType, typename InviscidOperators > bool eulerProblem< Mesh, BoundaryCondition, RightHandSide, InviscidOperators >:: eulerProblem< Mesh, BoundaryCondition, RightHandSide, CommType, InviscidOperators >:: setup( const MeshPointer& meshPointer, const Config::ParameterContainer& parameters, const String& prefix ) Loading @@ -89,9 +93,10 @@ setup( const MeshPointer& meshPointer, template< typename Mesh, typename BoundaryCondition, typename RightHandSide, typename CommType, typename InviscidOperators > typename eulerProblem< Mesh, BoundaryCondition, RightHandSide, InviscidOperators >::IndexType eulerProblem< Mesh, BoundaryCondition, RightHandSide, InviscidOperators >:: typename eulerProblem< Mesh, BoundaryCondition, RightHandSide, CommType, InviscidOperators >::IndexType eulerProblem< Mesh, BoundaryCondition, RightHandSide, CommType, InviscidOperators >:: getDofs( const MeshPointer& mesh ) const { /**** Loading @@ -104,9 +109,10 @@ getDofs( const MeshPointer& mesh ) const template< typename Mesh, typename BoundaryCondition, typename RightHandSide, typename CommType, typename InviscidOperators > void eulerProblem< Mesh, BoundaryCondition, RightHandSide, InviscidOperators >:: eulerProblem< Mesh, BoundaryCondition, RightHandSide, CommType, InviscidOperators >:: bindDofs( const MeshPointer& mesh, DofVectorPointer& dofVector ) { Loading @@ -116,9 +122,10 @@ bindDofs( const MeshPointer& mesh, template< typename Mesh, typename BoundaryCondition, typename RightHandSide, typename CommType, typename InviscidOperators > bool eulerProblem< Mesh, BoundaryCondition, RightHandSide, InviscidOperators >:: eulerProblem< Mesh, BoundaryCondition, RightHandSide, CommType, InviscidOperators >:: setInitialCondition( const Config::ParameterContainer& parameters, const MeshPointer& mesh, DofVectorPointer& dofs, Loading @@ -142,10 +149,11 @@ setInitialCondition( const Config::ParameterContainer& parameters, template< typename Mesh, typename BoundaryCondition, typename RightHandSide, typename CommType, typename InviscidOperators > template< typename Matrix > bool eulerProblem< Mesh, BoundaryCondition, RightHandSide, InviscidOperators >:: eulerProblem< Mesh, BoundaryCondition, RightHandSide, CommType, InviscidOperators >:: setupLinearSystem( const MeshPointer& mesh, Matrix& matrix ) { Loading @@ -168,9 +176,10 @@ setupLinearSystem( const MeshPointer& mesh, template< typename Mesh, typename BoundaryCondition, typename RightHandSide, typename CommType, typename InviscidOperators > bool eulerProblem< Mesh, BoundaryCondition, RightHandSide, InviscidOperators >:: eulerProblem< Mesh, BoundaryCondition, RightHandSide, CommType, InviscidOperators >:: makeSnapshot( const RealType& time, const IndexType& step, const MeshPointer& mesh, Loading Loading @@ -209,9 +218,10 @@ makeSnapshot( const RealType& time, template< typename Mesh, typename BoundaryCondition, typename RightHandSide, typename CommType, typename InviscidOperators > void eulerProblem< Mesh, BoundaryCondition, RightHandSide, InviscidOperators >:: eulerProblem< Mesh, BoundaryCondition, RightHandSide, CommType, InviscidOperators >:: getExplicitUpdate( const RealType& time, const RealType& tau, const MeshPointer& mesh, Loading Loading @@ -256,7 +266,7 @@ getExplicitUpdate( const RealType& time, explicitUpdaterContinuity.setDifferentialOperator( this->inviscidOperatorsPointer->getContinuityOperator() ); explicitUpdaterContinuity.setBoundaryConditions( this->boundaryConditionPointer ); explicitUpdaterContinuity.setRightHandSide( this->rightHandSidePointer ); explicitUpdaterContinuity.template update< typename Mesh::Cell >( time, tau, mesh, explicitUpdaterContinuity.template update< typename Mesh::Cell, CommunicatorType >( time, tau, mesh, this->conservativeVariables->getDensity(), this->conservativeVariablesRHS->getDensity() ); Loading @@ -267,7 +277,7 @@ getExplicitUpdate( const RealType& time, explicitUpdaterMomentumX.setDifferentialOperator( this->inviscidOperatorsPointer->getMomentumXOperator() ); explicitUpdaterMomentumX.setBoundaryConditions( this->boundaryConditionPointer ); explicitUpdaterMomentumX.setRightHandSide( this->rightHandSidePointer ); explicitUpdaterMomentumX.template update< typename Mesh::Cell >( time, tau, mesh, explicitUpdaterMomentumX.template update< typename Mesh::Cell, CommunicatorType >( time, tau, mesh, ( *this->conservativeVariables->getMomentum() )[ 0 ], // uRhoVelocityX, ( *this->conservativeVariablesRHS->getMomentum() )[ 0 ] ); //, fuRhoVelocityX ); Loading @@ -277,7 +287,7 @@ getExplicitUpdate( const RealType& time, explicitUpdaterMomentumY.setDifferentialOperator( this->inviscidOperatorsPointer->getMomentumYOperator() ); explicitUpdaterMomentumY.setBoundaryConditions( this->boundaryConditionPointer ); explicitUpdaterMomentumY.setRightHandSide( this->rightHandSidePointer ); explicitUpdaterMomentumY.template update< typename Mesh::Cell >( time, tau, mesh, explicitUpdaterMomentumY.template update< typename Mesh::Cell, CommunicatorType >( time, tau, mesh, ( *this->conservativeVariables->getMomentum() )[ 1 ], // uRhoVelocityX, ( *this->conservativeVariablesRHS->getMomentum() )[ 1 ] ); //, fuRhoVelocityX ); } Loading @@ -288,7 +298,7 @@ getExplicitUpdate( const RealType& time, explicitUpdaterMomentumZ.setDifferentialOperator( this->inviscidOperatorsPointer->getMomentumZOperator() ); explicitUpdaterMomentumZ.setBoundaryConditions( this->boundaryConditionPointer ); explicitUpdaterMomentumZ.setRightHandSide( this->rightHandSidePointer ); explicitUpdaterMomentumZ.template update< typename Mesh::Cell >( time, tau, mesh, explicitUpdaterMomentumZ.template update< typename Mesh::Cell, CommunicatorType >( time, tau, mesh, ( *this->conservativeVariables->getMomentum() )[ 2 ], // uRhoVelocityX, ( *this->conservativeVariablesRHS->getMomentum() )[ 2 ] ); //, fuRhoVelocityX ); } Loading @@ -301,7 +311,7 @@ getExplicitUpdate( const RealType& time, explicitUpdaterEnergy.setDifferentialOperator( this->inviscidOperatorsPointer->getEnergyOperator() ); explicitUpdaterEnergy.setBoundaryConditions( this->boundaryConditionPointer ); explicitUpdaterEnergy.setRightHandSide( this->rightHandSidePointer ); explicitUpdaterEnergy.template update< typename Mesh::Cell >( time, tau, mesh, explicitUpdaterEnergy.template update< typename Mesh::Cell, CommunicatorType >( time, tau, mesh, this->conservativeVariables->getEnergy(), // uRhoVelocityX, this->conservativeVariablesRHS->getEnergy() ); //, fuRhoVelocityX ); Loading @@ -315,10 +325,11 @@ getExplicitUpdate( const RealType& time, template< typename Mesh, typename BoundaryCondition, typename RightHandSide, typename CommType, typename InviscidOperators > template< typename Matrix > void eulerProblem< Mesh, BoundaryCondition, RightHandSide, InviscidOperators >:: eulerProblem< Mesh, BoundaryCondition, RightHandSide, CommType, InviscidOperators >:: assemblyLinearSystem( const RealType& time, const RealType& tau, const MeshPointer& mesh, Loading Loading @@ -351,9 +362,10 @@ assemblyLinearSystem( const RealType& time, template< typename Mesh, typename BoundaryCondition, typename RightHandSide, typename CommType, typename InviscidOperators > bool eulerProblem< Mesh, BoundaryCondition, RightHandSide, InviscidOperators >:: eulerProblem< Mesh, BoundaryCondition, RightHandSide, CommType, InviscidOperators >:: postIterate( const RealType& time, const RealType& tau, const MeshPointer& mesh, Loading examples/transport-equation/tnl-transport-equation-eoc.h +4 −3 Original line number Diff line number Diff line Loading @@ -72,7 +72,8 @@ template< typename Real, typename Index, typename MeshType, typename ConfigTag, typename SolverStarter > typename SolverStarter, typename CommunicatorType > class advectionSetter { public: Loading @@ -98,13 +99,13 @@ class advectionSetter if( boundaryConditionsType == "dirichlet" ) { typedef Operators::DirichletBoundaryConditions< MeshType, ConstantFunctionType, MeshType::getMeshDimension(), Real, Index > BoundaryConditions; typedef transportEquationProblemEoc< MeshType, BoundaryConditions, ConstantFunctionType, DifferentialOperatorType > Problem; typedef transportEquationProblemEoc< MeshType, BoundaryConditions, ConstantFunctionType, CommunicatorType, DifferentialOperatorType > Problem; return callSolverStarter< Problem >( parameters ); } if( boundaryConditionsType == "neumann" ) { typedef Operators::DirichletBoundaryConditions< MeshType, ConstantFunctionType, MeshType::getMeshDimension(), Real, Index > BoundaryConditions; typedef transportEquationProblemEoc< MeshType, BoundaryConditions, ConstantFunctionType, DifferentialOperatorType > Problem; typedef transportEquationProblemEoc< MeshType, BoundaryConditions, ConstantFunctionType, CommunicatorType, DifferentialOperatorType > Problem; return callSolverStarter< Problem >( parameters ); } std::cerr << "Unknown boundary conditions type: " << boundaryConditionsType << "." << std::endl; Loading Loading
examples/heat-equation/tnl-heat-equation-eoc.h +3 −2 Original line number Diff line number Diff line Loading @@ -44,7 +44,8 @@ template< typename Real, typename Index, typename MeshType, typename MeshConfig, typename SolverStarter > typename SolverStarter, typename CommunicatorType > class heatEquationSetter { public: Loading @@ -64,7 +65,7 @@ class heatEquationSetter typedef HeatEquationEocRhs< ExactOperator, TestFunction > RightHandSide; typedef Containers::StaticVector < MeshType::getMeshDimension(), Real > Point; typedef Operators::DirichletBoundaryConditions< MeshType, TestFunction, Dimension, Real, Index > BoundaryConditions; typedef HeatEquationEocProblem< MeshType, BoundaryConditions, RightHandSide, ApproximateOperator > Solver; typedef HeatEquationEocProblem< MeshType, BoundaryConditions, RightHandSide, CommunicatorType, ApproximateOperator > Solver; SolverStarter solverStarter; return solverStarter.template run< Solver >( parameters ); }; Loading
examples/inviscid-flow/euler.h +6 −5 Original line number Diff line number Diff line Loading @@ -51,7 +51,8 @@ template< typename Real, typename Index, typename MeshType, typename ConfigTag, typename SolverStarter > typename SolverStarter, typename CommunicatorType > class eulerSetter { public: Loading Loading @@ -79,12 +80,12 @@ class eulerSetter if( boundaryConditionsType == "dirichlet" ) { typedef Operators::DirichletBoundaryConditions< MeshType, Constant, MeshType::getMeshDimension(), Real, Index > BoundaryConditions; typedef eulerProblem< MeshType, BoundaryConditions, RightHandSide, ApproximateOperator > Problem; typedef eulerProblem< MeshType, BoundaryConditions, RightHandSide, CommunicatorType, ApproximateOperator > Problem; SolverStarter solverStarter; return solverStarter.template run< Problem >( parameters ); } typedef Operators::NeumannBoundaryConditions< MeshType, Constant, Real, Index > BoundaryConditions; typedef eulerProblem< MeshType, BoundaryConditions, RightHandSide, ApproximateOperator > Problem; typedef eulerProblem< MeshType, BoundaryConditions, RightHandSide, CommunicatorType, ApproximateOperator > Problem; SolverStarter solverStarter; return solverStarter.template run< Problem >( parameters ); } Loading @@ -92,12 +93,12 @@ class eulerSetter if( boundaryConditionsType == "dirichlet" ) { typedef Operators::DirichletBoundaryConditions< MeshType, MeshFunction, MeshType::getMeshDimension(), Real, Index > BoundaryConditions; typedef eulerProblem< MeshType, BoundaryConditions, RightHandSide, ApproximateOperator > Problem; typedef eulerProblem< MeshType, BoundaryConditions, RightHandSide, CommunicatorType, ApproximateOperator> Problem; SolverStarter solverStarter; return solverStarter.template run< Problem >( parameters ); } typedef Operators::NeumannBoundaryConditions< MeshType, MeshFunction, Real, Index > BoundaryConditions; typedef eulerProblem< MeshType, BoundaryConditions, RightHandSide, ApproximateOperator > Problem; typedef eulerProblem< MeshType, BoundaryConditions, RightHandSide, CommunicatorType ,ApproximateOperator > Problem; SolverStarter solverStarter; return solverStarter.template run< Problem >( parameters ); } Loading
examples/inviscid-flow/eulerProblem.h +3 −0 Original line number Diff line number Diff line Loading @@ -22,6 +22,7 @@ namespace TNL { template< typename Mesh, typename BoundaryCondition, typename RightHandSide, typename CommType, typename InviscidOperators > class eulerProblem: public PDEProblem< Mesh, Loading @@ -36,6 +37,8 @@ class eulerProblem: typedef typename InviscidOperators::IndexType IndexType; typedef PDEProblem< Mesh, RealType, DeviceType, IndexType > BaseType; typedef CommType CommunicatorType; using typename BaseType::MeshType; using typename BaseType::MeshPointer; using typename BaseType::DofVectorType; Loading
examples/inviscid-flow/eulerProblem_impl.h +30 −18 Original line number Diff line number Diff line Loading @@ -33,9 +33,10 @@ namespace TNL { template< typename Mesh, typename BoundaryCondition, typename RightHandSide, typename CommType, typename InviscidOperators > String eulerProblem< Mesh, BoundaryCondition, RightHandSide, InviscidOperators >:: eulerProblem< Mesh, BoundaryCondition, RightHandSide, CommType, InviscidOperators >:: getTypeStatic() { return String( "eulerProblem< " ) + Mesh :: getTypeStatic() + " >"; Loading @@ -44,9 +45,10 @@ getTypeStatic() template< typename Mesh, typename BoundaryCondition, typename RightHandSide, typename CommType, typename InviscidOperators > String eulerProblem< Mesh, BoundaryCondition, RightHandSide, InviscidOperators >:: eulerProblem< Mesh, BoundaryCondition, RightHandSide, CommType, InviscidOperators >:: getPrologHeader() const { return String( "Inviscid flow solver" ); Loading @@ -55,9 +57,10 @@ getPrologHeader() const template< typename Mesh, typename BoundaryCondition, typename RightHandSide, typename CommType, typename InviscidOperators > void eulerProblem< Mesh, BoundaryCondition, RightHandSide, InviscidOperators >:: eulerProblem< Mesh, BoundaryCondition, RightHandSide, CommType, InviscidOperators >:: writeProlog( Logger& logger, const Config::ParameterContainer& parameters ) const { /**** Loading @@ -69,9 +72,10 @@ writeProlog( Logger& logger, const Config::ParameterContainer& parameters ) cons template< typename Mesh, typename BoundaryCondition, typename RightHandSide, typename CommType, typename InviscidOperators > bool eulerProblem< Mesh, BoundaryCondition, RightHandSide, InviscidOperators >:: eulerProblem< Mesh, BoundaryCondition, RightHandSide, CommType, InviscidOperators >:: setup( const MeshPointer& meshPointer, const Config::ParameterContainer& parameters, const String& prefix ) Loading @@ -89,9 +93,10 @@ setup( const MeshPointer& meshPointer, template< typename Mesh, typename BoundaryCondition, typename RightHandSide, typename CommType, typename InviscidOperators > typename eulerProblem< Mesh, BoundaryCondition, RightHandSide, InviscidOperators >::IndexType eulerProblem< Mesh, BoundaryCondition, RightHandSide, InviscidOperators >:: typename eulerProblem< Mesh, BoundaryCondition, RightHandSide, CommType, InviscidOperators >::IndexType eulerProblem< Mesh, BoundaryCondition, RightHandSide, CommType, InviscidOperators >:: getDofs( const MeshPointer& mesh ) const { /**** Loading @@ -104,9 +109,10 @@ getDofs( const MeshPointer& mesh ) const template< typename Mesh, typename BoundaryCondition, typename RightHandSide, typename CommType, typename InviscidOperators > void eulerProblem< Mesh, BoundaryCondition, RightHandSide, InviscidOperators >:: eulerProblem< Mesh, BoundaryCondition, RightHandSide, CommType, InviscidOperators >:: bindDofs( const MeshPointer& mesh, DofVectorPointer& dofVector ) { Loading @@ -116,9 +122,10 @@ bindDofs( const MeshPointer& mesh, template< typename Mesh, typename BoundaryCondition, typename RightHandSide, typename CommType, typename InviscidOperators > bool eulerProblem< Mesh, BoundaryCondition, RightHandSide, InviscidOperators >:: eulerProblem< Mesh, BoundaryCondition, RightHandSide, CommType, InviscidOperators >:: setInitialCondition( const Config::ParameterContainer& parameters, const MeshPointer& mesh, DofVectorPointer& dofs, Loading @@ -142,10 +149,11 @@ setInitialCondition( const Config::ParameterContainer& parameters, template< typename Mesh, typename BoundaryCondition, typename RightHandSide, typename CommType, typename InviscidOperators > template< typename Matrix > bool eulerProblem< Mesh, BoundaryCondition, RightHandSide, InviscidOperators >:: eulerProblem< Mesh, BoundaryCondition, RightHandSide, CommType, InviscidOperators >:: setupLinearSystem( const MeshPointer& mesh, Matrix& matrix ) { Loading @@ -168,9 +176,10 @@ setupLinearSystem( const MeshPointer& mesh, template< typename Mesh, typename BoundaryCondition, typename RightHandSide, typename CommType, typename InviscidOperators > bool eulerProblem< Mesh, BoundaryCondition, RightHandSide, InviscidOperators >:: eulerProblem< Mesh, BoundaryCondition, RightHandSide, CommType, InviscidOperators >:: makeSnapshot( const RealType& time, const IndexType& step, const MeshPointer& mesh, Loading Loading @@ -209,9 +218,10 @@ makeSnapshot( const RealType& time, template< typename Mesh, typename BoundaryCondition, typename RightHandSide, typename CommType, typename InviscidOperators > void eulerProblem< Mesh, BoundaryCondition, RightHandSide, InviscidOperators >:: eulerProblem< Mesh, BoundaryCondition, RightHandSide, CommType, InviscidOperators >:: getExplicitUpdate( const RealType& time, const RealType& tau, const MeshPointer& mesh, Loading Loading @@ -256,7 +266,7 @@ getExplicitUpdate( const RealType& time, explicitUpdaterContinuity.setDifferentialOperator( this->inviscidOperatorsPointer->getContinuityOperator() ); explicitUpdaterContinuity.setBoundaryConditions( this->boundaryConditionPointer ); explicitUpdaterContinuity.setRightHandSide( this->rightHandSidePointer ); explicitUpdaterContinuity.template update< typename Mesh::Cell >( time, tau, mesh, explicitUpdaterContinuity.template update< typename Mesh::Cell, CommunicatorType >( time, tau, mesh, this->conservativeVariables->getDensity(), this->conservativeVariablesRHS->getDensity() ); Loading @@ -267,7 +277,7 @@ getExplicitUpdate( const RealType& time, explicitUpdaterMomentumX.setDifferentialOperator( this->inviscidOperatorsPointer->getMomentumXOperator() ); explicitUpdaterMomentumX.setBoundaryConditions( this->boundaryConditionPointer ); explicitUpdaterMomentumX.setRightHandSide( this->rightHandSidePointer ); explicitUpdaterMomentumX.template update< typename Mesh::Cell >( time, tau, mesh, explicitUpdaterMomentumX.template update< typename Mesh::Cell, CommunicatorType >( time, tau, mesh, ( *this->conservativeVariables->getMomentum() )[ 0 ], // uRhoVelocityX, ( *this->conservativeVariablesRHS->getMomentum() )[ 0 ] ); //, fuRhoVelocityX ); Loading @@ -277,7 +287,7 @@ getExplicitUpdate( const RealType& time, explicitUpdaterMomentumY.setDifferentialOperator( this->inviscidOperatorsPointer->getMomentumYOperator() ); explicitUpdaterMomentumY.setBoundaryConditions( this->boundaryConditionPointer ); explicitUpdaterMomentumY.setRightHandSide( this->rightHandSidePointer ); explicitUpdaterMomentumY.template update< typename Mesh::Cell >( time, tau, mesh, explicitUpdaterMomentumY.template update< typename Mesh::Cell, CommunicatorType >( time, tau, mesh, ( *this->conservativeVariables->getMomentum() )[ 1 ], // uRhoVelocityX, ( *this->conservativeVariablesRHS->getMomentum() )[ 1 ] ); //, fuRhoVelocityX ); } Loading @@ -288,7 +298,7 @@ getExplicitUpdate( const RealType& time, explicitUpdaterMomentumZ.setDifferentialOperator( this->inviscidOperatorsPointer->getMomentumZOperator() ); explicitUpdaterMomentumZ.setBoundaryConditions( this->boundaryConditionPointer ); explicitUpdaterMomentumZ.setRightHandSide( this->rightHandSidePointer ); explicitUpdaterMomentumZ.template update< typename Mesh::Cell >( time, tau, mesh, explicitUpdaterMomentumZ.template update< typename Mesh::Cell, CommunicatorType >( time, tau, mesh, ( *this->conservativeVariables->getMomentum() )[ 2 ], // uRhoVelocityX, ( *this->conservativeVariablesRHS->getMomentum() )[ 2 ] ); //, fuRhoVelocityX ); } Loading @@ -301,7 +311,7 @@ getExplicitUpdate( const RealType& time, explicitUpdaterEnergy.setDifferentialOperator( this->inviscidOperatorsPointer->getEnergyOperator() ); explicitUpdaterEnergy.setBoundaryConditions( this->boundaryConditionPointer ); explicitUpdaterEnergy.setRightHandSide( this->rightHandSidePointer ); explicitUpdaterEnergy.template update< typename Mesh::Cell >( time, tau, mesh, explicitUpdaterEnergy.template update< typename Mesh::Cell, CommunicatorType >( time, tau, mesh, this->conservativeVariables->getEnergy(), // uRhoVelocityX, this->conservativeVariablesRHS->getEnergy() ); //, fuRhoVelocityX ); Loading @@ -315,10 +325,11 @@ getExplicitUpdate( const RealType& time, template< typename Mesh, typename BoundaryCondition, typename RightHandSide, typename CommType, typename InviscidOperators > template< typename Matrix > void eulerProblem< Mesh, BoundaryCondition, RightHandSide, InviscidOperators >:: eulerProblem< Mesh, BoundaryCondition, RightHandSide, CommType, InviscidOperators >:: assemblyLinearSystem( const RealType& time, const RealType& tau, const MeshPointer& mesh, Loading Loading @@ -351,9 +362,10 @@ assemblyLinearSystem( const RealType& time, template< typename Mesh, typename BoundaryCondition, typename RightHandSide, typename CommType, typename InviscidOperators > bool eulerProblem< Mesh, BoundaryCondition, RightHandSide, InviscidOperators >:: eulerProblem< Mesh, BoundaryCondition, RightHandSide, CommType, InviscidOperators >:: postIterate( const RealType& time, const RealType& tau, const MeshPointer& mesh, Loading
examples/transport-equation/tnl-transport-equation-eoc.h +4 −3 Original line number Diff line number Diff line Loading @@ -72,7 +72,8 @@ template< typename Real, typename Index, typename MeshType, typename ConfigTag, typename SolverStarter > typename SolverStarter, typename CommunicatorType > class advectionSetter { public: Loading @@ -98,13 +99,13 @@ class advectionSetter if( boundaryConditionsType == "dirichlet" ) { typedef Operators::DirichletBoundaryConditions< MeshType, ConstantFunctionType, MeshType::getMeshDimension(), Real, Index > BoundaryConditions; typedef transportEquationProblemEoc< MeshType, BoundaryConditions, ConstantFunctionType, DifferentialOperatorType > Problem; typedef transportEquationProblemEoc< MeshType, BoundaryConditions, ConstantFunctionType, CommunicatorType, DifferentialOperatorType > Problem; return callSolverStarter< Problem >( parameters ); } if( boundaryConditionsType == "neumann" ) { typedef Operators::DirichletBoundaryConditions< MeshType, ConstantFunctionType, MeshType::getMeshDimension(), Real, Index > BoundaryConditions; typedef transportEquationProblemEoc< MeshType, BoundaryConditions, ConstantFunctionType, DifferentialOperatorType > Problem; typedef transportEquationProblemEoc< MeshType, BoundaryConditions, ConstantFunctionType, CommunicatorType, DifferentialOperatorType > Problem; return callSolverStarter< Problem >( parameters ); } std::cerr << "Unknown boundary conditions type: " << boundaryConditionsType << "." << std::endl; Loading