Commit 7ca61f55 authored by Jakub Klinkovský's avatar Jakub Klinkovský
Browse files

Added saveFailedLinearSystem method to PDE problems

This is particularly useful for debugging long simulations which don't
fail soon.
parent 35e5db2f
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -96,6 +96,11 @@ public PDEProblem< Mesh,
                                 DofVectorPointer& rightHandSide,
                                 MeshDependentDataPointer& meshDependentData );

      template< typename Matrix >
      void saveFailedLinearSystem( const Matrix& matrix,
                                   const DofVectorType& dofs,
                                   const DofVectorType& rightHandSide ) const;

   protected:

      MeshFunctionPointer uPointer;
+13 −0
Original line number Diff line number Diff line
@@ -223,4 +223,17 @@ assemblyLinearSystem( const RealType& time,
{
}

template< typename Mesh,
          typename BoundaryCondition,
          typename RightHandSide,
          typename DifferentialOperator >
    template< typename Matrix >
void
transportEquationProblem< Mesh, BoundaryCondition, RightHandSide, DifferentialOperator >::
saveFailedLinearSystem( const Matrix& matrix,
                        const DofVectorType& dofs,
                        const DofVectorType& rightHandSide ) const
{
}

} // namespace TNL
+4 −0
Original line number Diff line number Diff line
@@ -108,6 +108,10 @@ class HeatEquationProblem : public PDEProblem< Mesh,
                                 DofVectorPointer& rightHandSidePointer,
                                 MeshDependentDataPointer& meshDependentData );

      template< typename Matrix >
      void saveFailedLinearSystem( const Matrix& matrix,
                                   const DofVectorType& dofs,
                                   const DofVectorType& rightHandSide ) const;

      protected:
         
+13 −0
Original line number Diff line number Diff line
@@ -250,5 +250,18 @@ assemblyLinearSystem( const RealType& time,
      bPointer );
}

template< typename Mesh,
          typename BoundaryCondition,
          typename RightHandSide,
          typename DifferentialOperator >
    template< typename Matrix >
void
HeatEquationProblem< Mesh, BoundaryCondition, RightHandSide, DifferentialOperator >::
saveFailedLinearSystem( const Matrix& matrix,
                        const DofVectorType& dofs,
                        const DofVectorType& rightHandSide ) const
{
}

} // namespace Problems
} // namespace TNL
+4 −0
Original line number Diff line number Diff line
@@ -97,6 +97,10 @@ class MeanCurvatureFlowProblem : public PDEProblem< Mesh,
                                 DofVectorType& rightHandSide,
                                 MeshDependentDataPointer& meshDependentData );

      template< typename Matrix >
      void saveFailedLinearSystem( const Matrix& matrix,
                                   const DofVectorType& dofs,
                                   const DofVectorType& rightHandSide ) const;

      protected:

Loading