RectangularDrivenCavityProblem< ELEMENT > Class Template Reference

Driven cavity problem in rectangular domain. More...

+ Inheritance diagram for RectangularDrivenCavityProblem< ELEMENT >:

Public Member Functions

 RectangularDrivenCavityProblem (const unsigned &element_multiplier, const bool &use_iterative_solver, const bool &use_hypre_for_pressure, const bool &use_hypre_for_momentum, const bool &use_block_diagonal_for_momentum)
 
 ~RectangularDrivenCavityProblem ()
 Destructor. More...
 
void fix_pressure (const unsigned &e, const unsigned &pdof, const double &pvalue)
 Fix pressure in element e at pressure dof pdof and set to pvalue. More...
 
void actions_after_newton_solve ()
 Update the after solve (empty) More...
 
void actions_before_newton_solve ()
 
SimpleRectangularQuadMesh< ELEMENT > * mesh_pt ()
 
void doc_solution (DocInfo &doc_info)
 Doc the solution. More...
 
 RectangularDrivenCavityProblem ()
 Constructor for RectangularDrivenCavity problem. More...
 
 ~RectangularDrivenCavityProblem ()
 Destructor. More...
 
void fix_pressure (const unsigned &e, const unsigned &pdof, const double &pvalue)
 Fix pressure in element e at pressure dof pdof and set to pvalue. More...
 
void actions_after_newton_solve ()
 Update the after solve (empty) More...
 
void actions_before_newton_solve ()
 
SimpleRectangularQuadMesh< ELEMENT > * mesh_pt ()
 
void doc_solution (DocInfo &doc_info)
 Doc the solution. More...
 
 RectangularDrivenCavityProblem (const unsigned &element_multiplier, const bool &use_iterative_solver, const bool &use_hypre_for_pressure, const bool &use_hypre_for_momentum, const bool &use_block_diagonal_for_momentum)
 
 ~RectangularDrivenCavityProblem ()
 Destructor. More...
 
void fix_pressure (const unsigned &e, const unsigned &pdof, const double &pvalue)
 Fix pressure in element e at pressure dof pdof and set to pvalue. More...
 
void actions_after_newton_solve ()
 Update the after solve (empty) More...
 
void actions_before_newton_solve ()
 
SimpleRectangularQuadMesh< ELEMENT > * mesh_pt ()
 
void doc_solution (DocInfo &doc_info)
 Doc the solution. More...
 
void actions_before_adapt ()
 
void actions_after_adapt ()
 Actions that are to be performed after a mesh adaptation. More...
 
void actions_before_distribute ()
 
void actions_after_distribute ()
 
 RectangularDrivenCavityProblem ()
 Constructor. More...
 
 ~RectangularDrivenCavityProblem ()
 Destructor (empty) More...
 
void fix_pressure (const unsigned &e, const unsigned &pdof, const double &pvalue)
 Fix pressure in element e at pressure dof pdof and set to pvalue. More...
 
void actions_after_newton_solve ()
 Update the after solve (empty) More...
 
void actions_before_newton_solve ()
 
SimpleRectangularQuadMesh< ELEMENT > * mesh_pt ()
 
void doc_solution (DocInfo &doc_info)
 Doc the solution. More...
 
 RectangularDrivenCavityProblem ()
 Constructor. More...
 
 ~RectangularDrivenCavityProblem ()
 Destructor (empty) More...
 
void fix_pressure (const unsigned &e, const unsigned &pdof, const double &pvalue)
 Fix pressure in element e at pressure dof pdof and set to pvalue. More...
 
void actions_after_newton_solve ()
 Update the after solve (empty) More...
 
void actions_before_newton_solve ()
 Update the before solve (empty) More...
 
void doc_solution (DocInfo &doc_info)
 Doc the solution. More...
 
void actions_before_newton_step ()
 
void setup_line_plot_points ()
 Build line plot points. More...
 
 RectangularDrivenCavityProblem ()
 Constructor. More...
 
 ~RectangularDrivenCavityProblem ()
 Destructor (empty) More...
 
void sparse_assemble_row_or_column_compressed_test (Vector< Vector< int > > &column_or_row_index, Vector< Vector< int > > &row_or_column_start, Vector< Vector< double > > &value, Vector< Vector< double > * > &residuals, bool compressed_row_flag, unsigned method=1)
 To be killed. More...
 
void fix_pressure (const unsigned &e, const unsigned &pdof, const double &pvalue)
 Fix pressure in element e at pressure dof pdof and set to pvalue. More...
 
void actions_after_newton_solve ()
 Update the after solve (empty) More...
 
void actions_before_newton_solve ()
 
SimpleRectangularQuadMesh< ELEMENT > * mesh_pt ()
 
void doc_solution (DocInfo &doc_info)
 Doc the solution. More...
 
void compare_assembly_strategies (const unsigned &method)
 Do what it says... More...
 
 RectangularDrivenCavityProblem ()
 Constructor. More...
 
 ~RectangularDrivenCavityProblem ()
 Destructor to clean up memory. More...
 
void fix_pressure (const unsigned &e, const unsigned &pdof, const double &pvalue)
 Fix pressure in element e at pressure dof pdof and set to pvalue. More...
 
void actions_after_newton_solve ()
 Update the after solve (empty) More...
 
void actions_before_newton_solve ()
 
SimpleRectangularQuadMesh< ELEMENT > * mesh_pt ()
 
void doc_solution (DocInfo &doc_info)
 Doc the solution. More...
 
- Public Member Functions inherited from oomph::Problem
virtual void debug_hook_fct (const unsigned &i)
 
void set_analytic_dparameter (double *const &parameter_pt)
 
void unset_analytic_dparameter (double *const &parameter_pt)
 
bool is_dparameter_calculated_analytically (double *const &parameter_pt)
 
void set_analytic_hessian_products ()
 
void unset_analytic_hessian_products ()
 
bool are_hessian_products_calculated_analytically ()
 
void set_pinned_values_to_zero ()
 
bool distributed () const
 
OomphCommunicatorcommunicator_pt ()
 access function to the oomph-lib communicator More...
 
const OomphCommunicatorcommunicator_pt () const
 access function to the oomph-lib communicator, const version More...
 
 Problem ()
 
 Problem (const Problem &dummy)=delete
 Broken copy constructor. More...
 
void operator= (const Problem &)=delete
 Broken assignment operator. More...
 
virtual ~Problem ()
 Virtual destructor to clean up memory. More...
 
Mesh *& mesh_pt ()
 Return a pointer to the global mesh. More...
 
Mesh *const & mesh_pt () const
 Return a pointer to the global mesh (const version) More...
 
Mesh *& mesh_pt (const unsigned &imesh)
 
Mesh *const & mesh_pt (const unsigned &imesh) const
 Return a pointer to the i-th submesh (const version) More...
 
unsigned nsub_mesh () const
 Return number of submeshes. More...
 
unsigned add_sub_mesh (Mesh *const &mesh_pt)
 
void flush_sub_meshes ()
 
void build_global_mesh ()
 
void rebuild_global_mesh ()
 
LinearSolver *& linear_solver_pt ()
 Return a pointer to the linear solver object. More...
 
LinearSolver *const & linear_solver_pt () const
 Return a pointer to the linear solver object (const version) More...
 
LinearSolver *& mass_matrix_solver_for_explicit_timestepper_pt ()
 
LinearSolvermass_matrix_solver_for_explicit_timestepper_pt () const
 
EigenSolver *& eigen_solver_pt ()
 Return a pointer to the eigen solver object. More...
 
EigenSolver *const & eigen_solver_pt () const
 Return a pointer to the eigen solver object (const version) More...
 
Time *& time_pt ()
 Return a pointer to the global time object. More...
 
Timetime_pt () const
 Return a pointer to the global time object (const version). More...
 
doubletime ()
 Return the current value of continuous time. More...
 
double time () const
 Return the current value of continuous time (const version) More...
 
TimeStepper *& time_stepper_pt ()
 
const TimeSteppertime_stepper_pt () const
 
TimeStepper *& time_stepper_pt (const unsigned &i)
 Return a pointer to the i-th timestepper. More...
 
ExplicitTimeStepper *& explicit_time_stepper_pt ()
 Return a pointer to the explicit timestepper. More...
 
unsigned long set_timestepper_for_all_data (TimeStepper *const &time_stepper_pt, const bool &preserve_existing_data=false)
 
virtual void shift_time_values ()
 Shift all values along to prepare for next timestep. More...
 
AssemblyHandler *& assembly_handler_pt ()
 Return a pointer to the assembly handler object. More...
 
AssemblyHandler *const & assembly_handler_pt () const
 Return a pointer to the assembly handler object (const version) More...
 
doubleminimum_dt ()
 Access function to min timestep in adaptive timestepping. More...
 
doublemaximum_dt ()
 Access function to max timestep in adaptive timestepping. More...
 
unsignedmax_newton_iterations ()
 Access function to max Newton iterations before giving up. More...
 
void problem_is_nonlinear (const bool &prob_lin)
 Access function to Problem_is_nonlinear. More...
 
doublemax_residuals ()
 
booltime_adaptive_newton_crash_on_solve_fail ()
 Access function for Time_adaptive_newton_crash_on_solve_fail. More...
 
doublenewton_solver_tolerance ()
 
void add_time_stepper_pt (TimeStepper *const &time_stepper_pt)
 
void set_explicit_time_stepper_pt (ExplicitTimeStepper *const &explicit_time_stepper_pt)
 
void initialise_dt (const double &dt)
 
void initialise_dt (const Vector< double > &dt)
 
Data *& global_data_pt (const unsigned &i)
 Return a pointer to the the i-th global data object. More...
 
void add_global_data (Data *const &global_data_pt)
 
void flush_global_data ()
 
LinearAlgebraDistribution *const & dof_distribution_pt () const
 Return the pointer to the dof distribution (read-only) More...
 
unsigned long ndof () const
 Return the number of dofs. More...
 
unsigned ntime_stepper () const
 Return the number of time steppers. More...
 
unsigned nglobal_data () const
 Return the number of global data values. More...
 
unsigned self_test ()
 Self-test: Check meshes and global data. Return 0 for OK. More...
 
void enable_store_local_dof_pt_in_elements ()
 
void disable_store_local_dof_pt_in_elements ()
 
unsigned long assign_eqn_numbers (const bool &assign_local_eqn_numbers=true)
 
void describe_dofs (std::ostream &out= *(oomph_info.stream_pt())) const
 
void enable_discontinuous_formulation ()
 
void disable_discontinuous_formulation ()
 
void get_dofs (DoubleVector &dofs) const
 
void get_dofs (const unsigned &t, DoubleVector &dofs) const
 Return vector of the t'th history value of all dofs. More...
 
void set_dofs (const DoubleVector &dofs)
 Set the values of the dofs. More...
 
void set_dofs (const unsigned &t, DoubleVector &dofs)
 Set the history values of the dofs. More...
 
void set_dofs (const unsigned &t, Vector< double * > &dof_pt)
 
void add_to_dofs (const double &lambda, const DoubleVector &increment_dofs)
 Add lambda x incremenet_dofs[l] to the l-th dof. More...
 
doubleglobal_dof_pt (const unsigned &i)
 
doubledof (const unsigned &i)
 i-th dof in the problem More...
 
double dof (const unsigned &i) const
 i-th dof in the problem (const version) More...
 
double *& dof_pt (const unsigned &i)
 Pointer to i-th dof in the problem. More...
 
doubledof_pt (const unsigned &i) const
 Pointer to i-th dof in the problem (const version) More...
 
virtual void get_inverse_mass_matrix_times_residuals (DoubleVector &Mres)
 
virtual void get_dvaluesdt (DoubleVector &f)
 
virtual void get_residuals (DoubleVector &residuals)
 Get the total residuals Vector for the problem. More...
 
virtual void get_jacobian (DoubleVector &residuals, DenseDoubleMatrix &jacobian)
 
virtual void get_jacobian (DoubleVector &residuals, CRDoubleMatrix &jacobian)
 
virtual void get_jacobian (DoubleVector &residuals, CCDoubleMatrix &jacobian)
 
virtual void get_jacobian (DoubleVector &residuals, SumOfMatrices &jacobian)
 
void get_fd_jacobian (DoubleVector &residuals, DenseMatrix< double > &jacobian)
 Get the full Jacobian by finite differencing. More...
 
void get_derivative_wrt_global_parameter (double *const &parameter_pt, DoubleVector &result)
 
void get_hessian_vector_products (DoubleVectorWithHaloEntries const &Y, Vector< DoubleVectorWithHaloEntries > const &C, Vector< DoubleVectorWithHaloEntries > &product)
 
void solve_eigenproblem (const unsigned &n_eval, Vector< std::complex< double >> &eigenvalue, Vector< DoubleVector > &eigenvector, const bool &steady=true)
 Solve the eigenproblem. More...
 
void solve_eigenproblem (const unsigned &n_eval, Vector< std::complex< double >> &eigenvalue, const bool &steady=true)
 
virtual void get_eigenproblem_matrices (CRDoubleMatrix &mass_matrix, CRDoubleMatrix &main_matrix, const double &shift=0.0)
 
void assign_eigenvector_to_dofs (DoubleVector &eigenvector)
 Assign the eigenvector passed to the function to the dofs. More...
 
void add_eigenvector_to_dofs (const double &epsilon, const DoubleVector &eigenvector)
 
void store_current_dof_values ()
 Store the current values of the degrees of freedom. More...
 
void restore_dof_values ()
 Restore the stored values of the degrees of freedom. More...
 
void enable_jacobian_reuse ()
 
void disable_jacobian_reuse ()
 Disable recycling of Jacobian in Newton iteration. More...
 
bool jacobian_reuse_is_enabled ()
 Is recycling of Jacobian in Newton iteration enabled? More...
 
booluse_predictor_values_as_initial_guess ()
 
void newton_solve ()
 Use Newton method to solve the problem. More...
 
void enable_globally_convergent_newton_method ()
 enable globally convergent Newton method More...
 
void disable_globally_convergent_newton_method ()
 disable globally convergent Newton method More...
 
void newton_solve (unsigned const &max_adapt)
 
void steady_newton_solve (unsigned const &max_adapt=0)
 
void copy (Problem *orig_problem_pt)
 
virtual Problemmake_copy ()
 
virtual void read (std::ifstream &restart_file, bool &unsteady_restart)
 
virtual void read (std::ifstream &restart_file)
 
virtual void dump (std::ofstream &dump_file) const
 
void dump (const std::string &dump_file_name) const
 
void delete_all_external_storage ()
 
virtual void symmetrise_eigenfunction_for_adaptive_pitchfork_tracking ()
 
doublebifurcation_parameter_pt () const
 
void get_bifurcation_eigenfunction (Vector< DoubleVector > &eigenfunction)
 
void activate_fold_tracking (double *const &parameter_pt, const bool &block_solve=true)
 
void activate_bifurcation_tracking (double *const &parameter_pt, const DoubleVector &eigenvector, const bool &block_solve=true)
 
void activate_bifurcation_tracking (double *const &parameter_pt, const DoubleVector &eigenvector, const DoubleVector &normalisation, const bool &block_solve=true)
 
void activate_pitchfork_tracking (double *const &parameter_pt, const DoubleVector &symmetry_vector, const bool &block_solve=true)
 
void activate_hopf_tracking (double *const &parameter_pt, const bool &block_solve=true)
 
void activate_hopf_tracking (double *const &parameter_pt, const double &omega, const DoubleVector &null_real, const DoubleVector &null_imag, const bool &block_solve=true)
 
void deactivate_bifurcation_tracking ()
 
void reset_assembly_handler_to_default ()
 Reset the system to the standard non-augemented state. More...
 
double arc_length_step_solve (double *const &parameter_pt, const double &ds, const unsigned &max_adapt=0)
 
double arc_length_step_solve (Data *const &data_pt, const unsigned &data_index, const double &ds, const unsigned &max_adapt=0)
 
void reset_arc_length_parameters ()
 
intsign_of_jacobian ()
 
void explicit_timestep (const double &dt, const bool &shift_values=true)
 Take an explicit timestep of size dt. More...
 
void unsteady_newton_solve (const double &dt)
 
void unsteady_newton_solve (const double &dt, const bool &shift_values)
 
void unsteady_newton_solve (const double &dt, const unsigned &max_adapt, const bool &first, const bool &shift=true)
 
double doubly_adaptive_unsteady_newton_solve (const double &dt, const double &epsilon, const unsigned &max_adapt, const bool &first, const bool &shift=true)
 
double doubly_adaptive_unsteady_newton_solve (const double &dt, const double &epsilon, const unsigned &max_adapt, const unsigned &suppress_resolve_after_spatial_adapt_flag, const bool &first, const bool &shift=true)
 
double adaptive_unsteady_newton_solve (const double &dt_desired, const double &epsilon)
 
double adaptive_unsteady_newton_solve (const double &dt_desired, const double &epsilon, const bool &shift_values)
 
void assign_initial_values_impulsive ()
 
void assign_initial_values_impulsive (const double &dt)
 
void calculate_predictions ()
 Calculate predictions. More...
 
void enable_mass_matrix_reuse ()
 
void disable_mass_matrix_reuse ()
 
bool mass_matrix_reuse_is_enabled ()
 Return whether the mass matrix is being reused. More...
 
void refine_uniformly (const Vector< unsigned > &nrefine_for_mesh)
 
void refine_uniformly (const Vector< unsigned > &nrefine_for_mesh, DocInfo &doc_info)
 
void refine_uniformly_and_prune (const Vector< unsigned > &nrefine_for_mesh)
 
void refine_uniformly_and_prune (const Vector< unsigned > &nrefine_for_mesh, DocInfo &doc_info)
 
void refine_uniformly (DocInfo &doc_info)
 
void refine_uniformly_and_prune (DocInfo &doc_info)
 
void refine_uniformly ()
 
void refine_uniformly (const unsigned &i_mesh, DocInfo &doc_info)
 Do uniform refinement for submesh i_mesh with documentation. More...
 
void refine_uniformly (const unsigned &i_mesh)
 Do uniform refinement for submesh i_mesh without documentation. More...
 
void p_refine_uniformly (const Vector< unsigned > &nrefine_for_mesh)
 
void p_refine_uniformly (const Vector< unsigned > &nrefine_for_mesh, DocInfo &doc_info)
 
void p_refine_uniformly_and_prune (const Vector< unsigned > &nrefine_for_mesh)
 
void p_refine_uniformly_and_prune (const Vector< unsigned > &nrefine_for_mesh, DocInfo &doc_info)
 
void p_refine_uniformly (DocInfo &doc_info)
 
void p_refine_uniformly_and_prune (DocInfo &doc_info)
 
void p_refine_uniformly ()
 
void p_refine_uniformly (const unsigned &i_mesh, DocInfo &doc_info)
 Do uniform p-refinement for submesh i_mesh with documentation. More...
 
void p_refine_uniformly (const unsigned &i_mesh)
 Do uniform p-refinement for submesh i_mesh without documentation. More...
 
void refine_selected_elements (const Vector< unsigned > &elements_to_be_refined)
 
void refine_selected_elements (const Vector< RefineableElement * > &elements_to_be_refined_pt)
 
void refine_selected_elements (const unsigned &i_mesh, const Vector< unsigned > &elements_to_be_refined)
 
void refine_selected_elements (const unsigned &i_mesh, const Vector< RefineableElement * > &elements_to_be_refined_pt)
 
void refine_selected_elements (const Vector< Vector< unsigned >> &elements_to_be_refined)
 
void refine_selected_elements (const Vector< Vector< RefineableElement * >> &elements_to_be_refined_pt)
 
void p_refine_selected_elements (const Vector< unsigned > &elements_to_be_refined)
 
void p_refine_selected_elements (const Vector< PRefineableElement * > &elements_to_be_refined_pt)
 
void p_refine_selected_elements (const unsigned &i_mesh, const Vector< unsigned > &elements_to_be_refined)
 
void p_refine_selected_elements (const unsigned &i_mesh, const Vector< PRefineableElement * > &elements_to_be_refined_pt)
 
void p_refine_selected_elements (const Vector< Vector< unsigned >> &elements_to_be_refined)
 
void p_refine_selected_elements (const Vector< Vector< PRefineableElement * >> &elements_to_be_refined_pt)
 
unsigned unrefine_uniformly ()
 
unsigned unrefine_uniformly (const unsigned &i_mesh)
 
void p_unrefine_uniformly (DocInfo &doc_info)
 
void p_unrefine_uniformly (const unsigned &i_mesh, DocInfo &doc_info)
 Do uniform p-unrefinement for submesh i_mesh without documentation. More...
 
void adapt (unsigned &n_refined, unsigned &n_unrefined)
 
void adapt ()
 
void p_adapt (unsigned &n_refined, unsigned &n_unrefined)
 
void p_adapt ()
 
void adapt_based_on_error_estimates (unsigned &n_refined, unsigned &n_unrefined, Vector< Vector< double >> &elemental_error)
 
void adapt_based_on_error_estimates (Vector< Vector< double >> &elemental_error)
 
void get_all_error_estimates (Vector< Vector< double >> &elemental_error)
 
void doc_errors (DocInfo &doc_info)
 Get max and min error for all elements in submeshes. More...
 
void doc_errors ()
 Get max and min error for all elements in submeshes. More...
 
void enable_info_in_newton_solve ()
 
void disable_info_in_newton_solve ()
 Disable the output of information when in the newton solver. More...
 
- Public Member Functions inherited from oomph::ExplicitTimeSteppableObject
 ExplicitTimeSteppableObject ()
 Empty constructor. More...
 
 ExplicitTimeSteppableObject (const ExplicitTimeSteppableObject &)=delete
 Broken copy constructor. More...
 
void operator= (const ExplicitTimeSteppableObject &)=delete
 Broken assignment operator. More...
 
virtual ~ExplicitTimeSteppableObject ()
 Empty destructor. More...
 
virtual void actions_before_explicit_stage ()
 
virtual void actions_after_explicit_stage ()
 

Private Attributes

IterativeLinearSolverSolver_pt
 oomph-lib iterative linear solver More...
 
NavierStokesSchurComplementPreconditionerPrec_pt
 Preconditioner. More...
 
PreconditionerP_matrix_preconditioner_pt
 Inexact solver for P block. More...
 
PreconditionerF_matrix_preconditioner_pt
 Inexact solver for F block. More...
 
SingularNavierStokesSolutionElement< ELEMENT > * Singular_navier_stokes_solution1_element_pt
 
SingularNavierStokesSolutionElement< ELEMENT > * Singular_navier_stokes_solution2_element_pt
 
MeshSingular_navier_stokes_solution_mesh_pt
 
MeshNavier_stokes_mesh_pt
 Pointer to mesh with Poisson elements. More...
 
MeshAsGeomObjectMesh_as_geom_object_pt
 Mesh as geom object representation of mesh. More...
 
Vector< Vector< std::pair< GeomObject *, Vector< double > > > > Line_plot_point
 Line_plot_point[i_phi][i_rho]. More...
 

Additional Inherited Members

- Public Types inherited from oomph::Problem
typedef void(* SpatialErrorEstimatorFctPt) (Mesh *&mesh_pt, Vector< double > &elemental_error)
 Function pointer for spatial error estimator. More...
 
typedef void(* SpatialErrorEstimatorWithDocFctPt) (Mesh *&mesh_pt, Vector< double > &elemental_error, DocInfo &doc_info)
 Function pointer for spatial error estimator with doc. More...
 
- Public Attributes inherited from oomph::Problem
bool Shut_up_in_newton_solve
 
- Static Public Attributes inherited from oomph::Problem
static bool Suppress_warning_about_actions_before_read_unstructured_meshes
 
- Protected Types inherited from oomph::Problem
enum  Assembly_method {
  Perform_assembly_using_vectors_of_pairs , Perform_assembly_using_two_vectors , Perform_assembly_using_maps , Perform_assembly_using_lists ,
  Perform_assembly_using_two_arrays
}
 Enumerated flags to determine which sparse assembly method is used. More...
 
- Protected Member Functions inherited from oomph::Problem
unsigned setup_element_count_per_dof ()
 
virtual void sparse_assemble_row_or_column_compressed (Vector< int * > &column_or_row_index, Vector< int * > &row_or_column_start, Vector< double * > &value, Vector< unsigned > &nnz, Vector< double * > &residual, bool compressed_row_flag)
 
virtual void actions_before_newton_convergence_check ()
 
virtual void actions_after_newton_step ()
 
virtual void actions_before_implicit_timestep ()
 
virtual void actions_after_implicit_timestep ()
 
virtual void actions_after_implicit_timestep_and_error_estimation ()
 
virtual void actions_before_explicit_timestep ()
 Actions that should be performed before each explicit time step. More...
 
virtual void actions_after_explicit_timestep ()
 Actions that should be performed after each explicit time step. More...
 
virtual void actions_before_read_unstructured_meshes ()
 
virtual void actions_after_read_unstructured_meshes ()
 
virtual void actions_after_change_in_global_parameter (double *const &parameter_pt)
 
virtual void actions_after_change_in_bifurcation_parameter ()
 
virtual void actions_after_parameter_increase (double *const &parameter_pt)
 
doubledof_derivative (const unsigned &i)
 
doubledof_current (const unsigned &i)
 
virtual void set_initial_condition ()
 
virtual double global_temporal_error_norm ()
 
unsigned newton_solve_continuation (double *const &parameter_pt)
 
unsigned newton_solve_continuation (double *const &parameter_pt, DoubleVector &z)
 
void calculate_continuation_derivatives (double *const &parameter_pt)
 
void calculate_continuation_derivatives (const DoubleVector &z)
 
void calculate_continuation_derivatives_fd (double *const &parameter_pt)
 
bool does_pointer_correspond_to_problem_data (double *const &parameter_pt)
 
void set_consistent_pinned_values_for_continuation ()
 
- Protected Attributes inherited from oomph::Problem
Vector< Problem * > Copy_of_problem_pt
 
std::map< double *, boolCalculate_dparameter_analytic
 
bool Calculate_hessian_products_analytic
 
LinearAlgebraDistributionDof_distribution_pt
 
Vector< double * > Dof_pt
 Vector of pointers to dofs. More...
 
DoubleVectorWithHaloEntries Element_count_per_dof
 
double Relaxation_factor
 
double Newton_solver_tolerance
 
unsigned Max_newton_iterations
 Maximum number of Newton iterations. More...
 
unsigned Nnewton_iter_taken
 
Vector< doubleMax_res
 Maximum residuals at start and after each newton iteration. More...
 
double Max_residuals
 
bool Time_adaptive_newton_crash_on_solve_fail
 
bool Jacobian_reuse_is_enabled
 Is re-use of Jacobian in Newton iteration enabled? Default: false. More...
 
bool Jacobian_has_been_computed
 
bool Problem_is_nonlinear
 
bool Pause_at_end_of_sparse_assembly
 
bool Doc_time_in_distribute
 
unsigned Sparse_assembly_method
 
unsigned Sparse_assemble_with_arrays_initial_allocation
 
unsigned Sparse_assemble_with_arrays_allocation_increment
 
Vector< Vector< unsigned > > Sparse_assemble_with_arrays_previous_allocation
 
double Numerical_zero_for_sparse_assembly
 
double FD_step_used_in_get_hessian_vector_products
 
bool Mass_matrix_reuse_is_enabled
 
bool Mass_matrix_has_been_computed
 
bool Discontinuous_element_formulation
 
double Minimum_dt
 Minimum desired dt: if dt falls below this value, exit. More...
 
double Maximum_dt
 Maximum desired dt. More...
 
double DTSF_max_increase
 
double DTSF_min_decrease
 
double Minimum_dt_but_still_proceed
 
bool Scale_arc_length
 Boolean to control whether arc-length should be scaled. More...
 
double Desired_proportion_of_arc_length
 Proportion of the arc-length to taken by the parameter. More...
 
double Theta_squared
 
int Sign_of_jacobian
 Storage for the sign of the global Jacobian. More...
 
double Continuation_direction
 
double Parameter_derivative
 Storage for the derivative of the global parameter wrt arc-length. More...
 
double Parameter_current
 Storage for the present value of the global parameter. More...
 
bool Use_continuation_timestepper
 Boolean to control original or new storage of dof stuff. More...
 
unsigned Dof_derivative_offset
 
unsigned Dof_current_offset
 
Vector< doubleDof_derivative
 Storage for the derivative of the problem variables wrt arc-length. More...
 
Vector< doubleDof_current
 Storage for the present values of the variables. More...
 
double Ds_current
 Storage for the current step value. More...
 
unsigned Desired_newton_iterations_ds
 
double Minimum_ds
 Minimum desired value of arc-length. More...
 
bool Bifurcation_detection
 Boolean to control bifurcation detection via determinant of Jacobian. More...
 
bool Bisect_to_find_bifurcation
 Boolean to control wheter bisection is used to located bifurcation. More...
 
bool First_jacobian_sign_change
 Boolean to indicate whether a sign change has occured in the Jacobian. More...
 
bool Arc_length_step_taken
 Boolean to indicate whether an arc-length step has been taken. More...
 
bool Use_finite_differences_for_continuation_derivatives
 
OomphCommunicatorCommunicator_pt
 The communicator for this problem. More...
 
bool Always_take_one_newton_step
 
double Timestep_reduction_factor_after_nonconvergence
 
bool Keep_temporal_error_below_tolerance
 
- Static Protected Attributes inherited from oomph::Problem
static ContinuationStorageScheme Continuation_time_stepper
 Storage for the single static continuation timestorage object. More...
 

Detailed Description

template<class ELEMENT>
class RectangularDrivenCavityProblem< ELEMENT >

Driven cavity problem in rectangular domain.

///////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////

Constructor & Destructor Documentation

◆ RectangularDrivenCavityProblem() [1/7]

template<class ELEMENT >
RectangularDrivenCavityProblem< ELEMENT >::RectangularDrivenCavityProblem ( const unsigned element_multiplier,
const bool use_iterative_solver,
const bool use_hypre_for_pressure,
const bool use_hypre_for_momentum,
const bool use_block_diagonal_for_momentum 
)

Constructor: Specify multiplier for number of element rows/columns and solver flag.

Constructor for RectangularDrivenCavity problem: Specify multiplier for number of element rows/columns and solver flag.

200 {
201 
202  // Initialise pointer to oomph-lib iterative linear solver
203  Solver_pt=0;
204 
205  // Initialise pointer to Preconditioner
206  Prec_pt=0;
207 
208  // Initialise pointer to inexact solver for P block
210 
211  // Initialise pointer to inexact solver for F block
213 
214 
215  // Setup mesh
216 
217  // # of elements in x-direction
218  unsigned n_x=10*element_multiplier;
219 
220  // # of elements in y-direction
221  unsigned n_y=10*element_multiplier;
222 
223  // Domain length in x-direction
224  double l_x=1.0;
225 
226  // Domain length in y-direction
227  double l_y=1.0;
228 
229  // Build and assign mesh
230  Problem::mesh_pt() = new SimpleRectangularQuadMesh<ELEMENT>(n_x,n_y,l_x,l_y);
231 
232  // Set the boundary conditions for this problem: All nodes are
233  // free by default -- just pin the ones that have Dirichlet conditions
234  // here.
235  unsigned num_bound = mesh_pt()->nboundary();
236  for(unsigned ibound=0;ibound<num_bound;ibound++)
237  {
238  unsigned num_nod= mesh_pt()->nboundary_node(ibound);
239  for (unsigned inod=0;inod<num_nod;inod++)
240  {
241  // Loop over values (u and v velocities)
242  for (unsigned i=0;i<2;i++)
243  {
244  mesh_pt()->boundary_node_pt(ibound,inod)->pin(i);
245  }
246  }
247  } // end loop over boundaries
248 
249  // Complete the build of all elements so they are fully functional
250 
251  //Find number of elements in mesh
252  unsigned n_element = mesh_pt()->nelement();
253 
254  // Loop over the elements to set up element-specific
255  // things that cannot be handled by constructor
256  for(unsigned e=0;e<n_element;e++)
257  {
258  // Upcast from GeneralisedElement to the present element
259  ELEMENT* el_pt = dynamic_cast<ELEMENT*>(mesh_pt()->element_pt(e));
260 
261  //Set the Reynolds number
262  el_pt->re_pt() = &Global_Physical_Variables::Re;
263  } // end loop over elements
264 
265  // Now set the first pressure value in element 0 to 0.0
266  fix_pressure(0,0,0.0);
267 
268 
269  // Setup iterative linear solver if required
270  if (use_iterative_solver)
271  {
272  // Create oomph-lib iterative linear solver
274 
275  // Set linear solver
277 
278  // Set preconditioner
281 
283 
284  // By default, the LSC Preconditioner uses SuperLU as
285  // an exact preconditioner (i.e. a solver) for the
286  // momentum and Schur complement blocks.
287  // Can overwrite this by passing pointers to
288  // other preconditioners that perform the (approximate)
289  // solves of these blocks.
290 
291  // Create internal preconditioners used on Schur block
292  //-----------------------------------------------------
293 #ifdef OOMPH_HAS_HYPRE
294 //Trap because HYPRE can't handle the case when
295 //OOMPH_HAS_MPI, but we run in serial
296 #ifndef OOMPH_HAS_MPI
297  if (use_hypre_for_pressure)
298  {
300 
301  // Set parameters for use as preconditioner on Poisson-type problem
304 
305  // Use Hypre for the Schur complement block
307 
308  // Shut up!
310  disable_doc_time();
311  }
312 #endif
313 #endif
314 
315  // Create internal preconditioners used on momentum block
316  //--------------------------------------------------------
317  if (use_block_diagonal_for_momentum)
318  {
321 #ifdef OOMPH_HAS_HYPRE
322 //Trap because HYPRE can't handle the case when
323 //OOMPH_HAS_MPI, but we run in serial
324 #ifndef OOMPH_HAS_MPI
325  if (use_hypre_for_momentum)
326  {
328  (F_matrix_preconditioner_pt)->set_subsidiary_preconditioner_function
329  (Hypre_Subsidiary_Preconditioner_Helper::set_hypre_preconditioner);
330  }
331 #endif
332 #endif
333  // Use Hypre for momentum block
335  }
336  else
337  {
338 #ifdef OOMPH_HAS_HYPRE
339 //Trap because HYPRE can't handle the case when
340 //OOMPH_HAS_MPI, but we run in serial
341 #ifndef OOMPH_HAS_MPI
342  if (use_hypre_for_momentum)
343  {
345 
346  // Shut up!
348  disable_doc_time();
349 
350  // Set parameters for use as preconditioner in for momentum
351  // block in Navier-Stokes problem
354 
355  // Use Hypre for momentum block
357  }
358 #endif
359 #endif
360  }
361 
362  }
363 
364  // Setup equation numbering scheme
365  cout << "Number of equations: " << assign_eqn_numbers() << std::endl;
366 
367 } // end_of_constructor
int i
Definition: BiCGSTAB_step_by_step.cpp:9
Array< double, 1, 3 > e(1./3., 0.5, 2.)
Preconditioner * P_matrix_preconditioner_pt
Inexact solver for P block.
Definition: linear_solvers/driven_cavity.cc:180
SimpleRectangularQuadMesh< ELEMENT > * mesh_pt()
Definition: linear_solvers/driven_cavity.cc:158
IterativeLinearSolver * Solver_pt
oomph-lib iterative linear solver
Definition: linear_solvers/driven_cavity.cc:174
Preconditioner * F_matrix_preconditioner_pt
Inexact solver for F block.
Definition: linear_solvers/driven_cavity.cc:183
void fix_pressure(const unsigned &e, const unsigned &pdof, const double &pvalue)
Fix pressure in element e at pressure dof pdof and set to pvalue.
Definition: linear_solvers/driven_cavity.cc:112
NavierStokesSchurComplementPreconditioner * Prec_pt
Preconditioner.
Definition: linear_solvers/driven_cavity.cc:177
Definition: general_purpose_block_preconditioners.h:321
The GMRES method.
Definition: iterative_linear_solver.h:1227
Definition: hypre_solver.h:826
Preconditioner *& preconditioner_pt()
Access function to preconditioner.
Definition: iterative_linear_solver.h:95
Definition: navier_stokes_preconditioners.h:607
void set_p_preconditioner(Preconditioner *new_p_preconditioner_pt)
Function to set a new pressure matrix preconditioner (inexact solver)
Definition: navier_stokes_preconditioners.h:745
void set_f_preconditioner(Preconditioner *new_f_preconditioner_pt)
Function to set a new momentum matrix preconditioner (inexact solver)
Definition: navier_stokes_preconditioners.h:769
void set_navier_stokes_mesh(Mesh *mesh_pt, const bool &allow_multiple_element_type_in_navier_stokes_mesh=false)
Definition: navier_stokes_preconditioners.h:732
LinearSolver *& linear_solver_pt()
Return a pointer to the linear solver object.
Definition: problem.h:1466
unsigned long assign_eqn_numbers(const bool &assign_local_eqn_numbers=true)
Definition: problem.cc:1989
Definition: simple_rectangular_quadmesh.template.h:58
double Re
Reynolds number.
Definition: fibre.cc:55
void set_defaults_for_navier_stokes_momentum_block(HyprePreconditioner *hypre_preconditioner_pt)
Definition: hypre_solver.cc:85
void set_defaults_for_2D_poisson_problem(HyprePreconditioner *hypre_preconditioner_pt)
Definition: hypre_solver.cc:45

References e(), i, Global_Physical_Variables::Re, oomph::Hypre_default_settings::set_defaults_for_2D_poisson_problem(), and oomph::Hypre_default_settings::set_defaults_for_navier_stokes_momentum_block().

◆ ~RectangularDrivenCavityProblem() [1/7]

template<class ELEMENT >
RectangularDrivenCavityProblem< ELEMENT >::~RectangularDrivenCavityProblem
inline

Destructor.

Destructor for RectangularDrivenCavity problem.

93  {
94  // Kill oomph-lib iterative linear solver
95  if (Solver_pt!=0) delete Solver_pt;
96 
97  // Kill preconditioner
98  if (Prec_pt!=0) delete Prec_pt;
99 
100  // Kill inexact solver for P block
102 
103  // Kill inexact solver for F block
105 
106  // Kill mesh
107  delete mesh_pt();
108 
109  };

◆ RectangularDrivenCavityProblem() [2/7]

template<class ELEMENT >
RectangularDrivenCavityProblem< ELEMENT >::RectangularDrivenCavityProblem

Constructor for RectangularDrivenCavity problem.

Constructor: Specify multiplier for number of element rows/columns and solver flag.

Constructor for RectangularDrivenCavity problem: Specify multiplier for number of element rows/columns and solver flag.

807 {
808  unsigned element_multiplier=1;
809  bool use_iterative_solver=true;
810  bool use_hypre_for_pressure=false;
811  bool use_hypre_for_momentum=false;
812  bool use_block_diagonal_for_momentum=false;
813 
814  // Initialise pointer to oomph-lib iterative linear solver
815  Solver_pt=0;
816 
817  // Initialise pointer to Preconditioner
818  Prec_pt=0;
819 
820  // Initialise pointer to inexact solver for P block
822 
823  // Initialise pointer to inexact solver for F block
825 
826 
827  // Setup mesh
828 
829  // # of elements in x-direction
830  unsigned n_x=10*element_multiplier;
831 
832  // # of elements in y-direction
833  unsigned n_y=10*element_multiplier;
834 
835  // Domain length in x-direction
836  double l_x=1.0;
837 
838  // Domain length in y-direction
839  double l_y=1.0;
840 
841  // Build and assign mesh
842  Problem::mesh_pt() = new SimpleRectangularQuadMesh<ELEMENT>(n_x,n_y,l_x,l_y);
843 
844  // Set the boundary conditions for this problem: All nodes are
845  // free by default -- just pin the ones that have Dirichlet conditions
846  // here.
847  unsigned num_bound = mesh_pt()->nboundary();
848  for(unsigned ibound=0;ibound<num_bound;ibound++)
849  {
850  unsigned num_nod= mesh_pt()->nboundary_node(ibound);
851  for (unsigned inod=0;inod<num_nod;inod++)
852  {
853  // Loop over values (u and v velocities)
854  for (unsigned i=0;i<2;i++)
855  {
856  mesh_pt()->boundary_node_pt(ibound,inod)->pin(i);
857  }
858  }
859  } // end loop over boundaries
860 
861  // Complete the build of all elements so they are fully functional
862 
863  //Find number of elements in mesh
864  unsigned n_element = mesh_pt()->nelement();
865 
866  // Loop over the elements to set up element-specific
867  // things that cannot be handled by constructor
868  for(unsigned e=0;e<n_element;e++)
869  {
870  // Upcast from GeneralisedElement to the present element
871  ELEMENT* el_pt = dynamic_cast<ELEMENT*>(mesh_pt()->element_pt(e));
872 
873  //Set the Reynolds number
874  el_pt->re_pt() = &Global_Physical_Variables::Re;
875  } // end loop over elements
876 
877  // Now set the first pressure value in element 0 to 0.0
878  fix_pressure(0,0,0.0);
879 
880 
881  // Setup iterative linear solver if required
882  if (use_iterative_solver)
883  {
884  // Create oomph-lib iterative linear solver
886 
887  // Set linear solver
889 
890  // Set preconditioner
893 
894 // Prec_pt->navier_stokes_mesh_pt() = this->mesh_pt();
896 
897 
898  // By default, the LSC Preconditioner uses SuperLU as
899  // an exact preconditioner (i.e. a solver) for the
900  // momentum and Schur complement blocks.
901  // Can overwrite this by passing pointers to
902  // other preconditioners that perform the (approximate)
903  // solves of these blocks.
904 
905  // Create internal preconditioners used on Schur block
906  //-----------------------------------------------------
907 #ifdef OOMPH_HAS_HYPRE
908 //Trap because HYPRE can't handle the case when
909 //OOMPH_HAS_MPI, but we run in serial
910 #ifndef OOMPH_HAS_MPI
911  if (use_hypre_for_pressure)
912  {
914 
915  // Set parameters for use as preconditioner on Poisson-type problem
918 
919  // Use Hypre for the Schur complement block
921 
922  // Shut up!
924  disable_doc_time();
925  }
926 #endif
927 #endif
928 
929  // Create internal preconditioners used on momentum block
930  //--------------------------------------------------------
931  if (use_block_diagonal_for_momentum)
932  {
935 #ifdef OOMPH_HAS_HYPRE
936 //Trap because HYPRE can't handle the case when
937 //OOMPH_HAS_MPI, but we run in serial
938 #ifndef OOMPH_HAS_MPI
939  if (use_hypre_for_momentum)
940  {
942  (F_matrix_preconditioner_pt)->set_subsidiary_preconditioner_function
943  (Hypre_Subsidiary_Preconditioner_Helper::set_hypre_preconditioner);
944  }
945 #endif
946 #endif
947  // Use Hypre for momentum block
949  }
950  else
951  {
952 #ifdef OOMPH_HAS_HYPRE
953 //Trap because HYPRE can't handle the case when
954 //OOMPH_HAS_MPI, but we run in serial
955 #ifndef OOMPH_HAS_MPI
956  if (use_hypre_for_momentum)
957  {
959 
960  // Shut up!
962  disable_doc_time();
963 
964  // Set parameters for use as preconditioner in for momentum
965  // block in Navier-Stokes problem
968 
969  // Use Hypre for momentum block
971  }
972 #endif
973 #endif
974  }
975 
976  }
977 
978  // Setup equation numbering scheme
979  cout << "Number of equations: " << assign_eqn_numbers() << std::endl;
980 
981 } // end_of_constructor

References e(), i, Global_Physical_Variables::Re, oomph::Hypre_default_settings::set_defaults_for_2D_poisson_problem(), and oomph::Hypre_default_settings::set_defaults_for_navier_stokes_momentum_block().

◆ ~RectangularDrivenCavityProblem() [2/7]

template<class ELEMENT >
RectangularDrivenCavityProblem< ELEMENT >::~RectangularDrivenCavityProblem ( )
inline

Destructor.

705  {
706  // Kill oomph-lib iterative linear solver
707  if (Solver_pt!=0) delete Solver_pt;
708 
709  // Kill preconditioner
710  if (Prec_pt!=0) delete Prec_pt;
711 
712  // Kill inexact solver for P block
714 
715  // Kill inexact solver for F block
717 
718  // Kill mesh
719  delete mesh_pt();
720 
721  };

◆ RectangularDrivenCavityProblem() [3/7]

template<class ELEMENT >
RectangularDrivenCavityProblem< ELEMENT >::RectangularDrivenCavityProblem ( const unsigned element_multiplier,
const bool use_iterative_solver,
const bool use_hypre_for_pressure,
const bool use_hypre_for_momentum,
const bool use_block_diagonal_for_momentum 
)

Constructor: Specify multiplier for number of element rows/columns and solver flag.

◆ ~RectangularDrivenCavityProblem() [3/7]

template<class ELEMENT >
RectangularDrivenCavityProblem< ELEMENT >::~RectangularDrivenCavityProblem ( )
inline

Destructor.

97  {
98  // Kill oomph-lib iterative linear solver
99  if (Solver_pt!=0) delete Solver_pt;
100 
101  // Kill preconditioner
102  if (Prec_pt!=0) delete Prec_pt;
103 
104  // Kill inexact solver for P block
106 
107  // Kill inexact solver for F block
109 
110  // Kill mesh
111  delete mesh_pt();
112 
113  };

◆ RectangularDrivenCavityProblem() [4/7]

template<class ELEMENT >
RectangularDrivenCavityProblem< ELEMENT >::RectangularDrivenCavityProblem ( )

Constructor.

◆ ~RectangularDrivenCavityProblem() [4/7]

template<class ELEMENT >
RectangularDrivenCavityProblem< ELEMENT >::~RectangularDrivenCavityProblem ( )
inline

Destructor (empty)

73 {}

◆ RectangularDrivenCavityProblem() [5/7]

template<class ELEMENT >
RectangularDrivenCavityProblem< ELEMENT >::RectangularDrivenCavityProblem ( )

Constructor.

◆ ~RectangularDrivenCavityProblem() [5/7]

template<class ELEMENT >
RectangularDrivenCavityProblem< ELEMENT >::~RectangularDrivenCavityProblem ( )
inline

Destructor (empty)

769 {}

◆ RectangularDrivenCavityProblem() [6/7]

template<class ELEMENT >
RectangularDrivenCavityProblem< ELEMENT >::RectangularDrivenCavityProblem ( )

Constructor.

◆ ~RectangularDrivenCavityProblem() [6/7]

template<class ELEMENT >
RectangularDrivenCavityProblem< ELEMENT >::~RectangularDrivenCavityProblem ( )
inline

Destructor (empty)

92  {
93  delete Problem::mesh_pt();
94  }

◆ RectangularDrivenCavityProblem() [7/7]

template<class ELEMENT >
RectangularDrivenCavityProblem< ELEMENT >::RectangularDrivenCavityProblem ( )

Constructor.

◆ ~RectangularDrivenCavityProblem() [7/7]

template<class ELEMENT >
RectangularDrivenCavityProblem< ELEMENT >::~RectangularDrivenCavityProblem ( )

Destructor to clean up memory.

Member Function Documentation

◆ actions_after_adapt()

template<class ELEMENT >
void RectangularDrivenCavityProblem< ELEMENT >::actions_after_adapt ( )
inlinevirtual

Actions that are to be performed after a mesh adaptation.

Reimplemented from oomph::Problem.

178  {
180  unpin_all_pressure_dofs(mesh_pt()->element_pt());
182  pin_redundant_nodal_pressures(mesh_pt()->element_pt());
183  }
Definition: refineable_navier_stokes_elements.h:322

◆ actions_after_distribute()

template<class ELEMENT >
void RectangularDrivenCavityProblem< ELEMENT >::actions_after_distribute ( )
inline
189 {}

◆ actions_after_newton_solve() [1/7]

template<class ELEMENT >
void RectangularDrivenCavityProblem< ELEMENT >::actions_after_newton_solve ( )
inlinevirtual

Update the after solve (empty)

Reimplemented from oomph::Problem.

122 {}

◆ actions_after_newton_solve() [2/7]

template<class ELEMENT >
void RectangularDrivenCavityProblem< ELEMENT >::actions_after_newton_solve ( )
inlinevirtual

Update the after solve (empty)

Reimplemented from oomph::Problem.

734 {}

◆ actions_after_newton_solve() [3/7]

template<class ELEMENT >
void RectangularDrivenCavityProblem< ELEMENT >::actions_after_newton_solve ( )
inlinevirtual

Update the after solve (empty)

Reimplemented from oomph::Problem.

126 {}

◆ actions_after_newton_solve() [4/7]

template<class ELEMENT >
void RectangularDrivenCavityProblem< ELEMENT >::actions_after_newton_solve ( )
inlinevirtual

Update the after solve (empty)

Reimplemented from oomph::Problem.

86 {}

◆ actions_after_newton_solve() [5/7]

template<class ELEMENT >
void RectangularDrivenCavityProblem< ELEMENT >::actions_after_newton_solve ( )
inlinevirtual

Update the after solve (empty)

Reimplemented from oomph::Problem.

782 {}

◆ actions_after_newton_solve() [6/7]

template<class ELEMENT >
void RectangularDrivenCavityProblem< ELEMENT >::actions_after_newton_solve ( )
inlinevirtual

Update the after solve (empty)

Reimplemented from oomph::Problem.

117 {}

◆ actions_after_newton_solve() [7/7]

template<class ELEMENT >
void RectangularDrivenCavityProblem< ELEMENT >::actions_after_newton_solve ( )
inlinevirtual

Update the after solve (empty)

Reimplemented from oomph::Problem.

93 {}

◆ actions_before_adapt()

template<class ELEMENT >
void RectangularDrivenCavityProblem< ELEMENT >::actions_before_adapt ( )
inlinevirtual

Actions that are to be performed before a mesh adaptation. These might include removing any additional elements, such as traction boundary elements before the adaptation.

Reimplemented from oomph::Problem.

175 {}

◆ actions_before_distribute()

template<class ELEMENT >
void RectangularDrivenCavityProblem< ELEMENT >::actions_before_distribute ( )
inline
186 {}

◆ actions_before_newton_solve() [1/7]

template<class ELEMENT >
void RectangularDrivenCavityProblem< ELEMENT >::actions_before_newton_solve ( )
inlinevirtual

Update the problem specs before solve. Re-set velocity boundary conditions just to be on the safe side...

Reimplemented from oomph::Problem.

128  {
129  // Setup tangential flow along boundary 0:
130  unsigned ibound=0;
131  unsigned num_nod= mesh_pt()->nboundary_node(ibound);
132  for (unsigned inod=0;inod<num_nod;inod++)
133  {
134  // Tangential flow
135  unsigned i=0;
136  mesh_pt()->boundary_node_pt(ibound,inod)->set_value(i,1.0);
137  // No penetration
138  i=1;
139  mesh_pt()->boundary_node_pt(ibound,inod)->set_value(i,0.0);
140  }
141 
142  // Overwrite with no flow along the other boundaries
143  unsigned num_bound = mesh_pt()->nboundary();
144  for(unsigned ibound=1;ibound<num_bound;ibound++)
145  {
146  unsigned num_nod= mesh_pt()->nboundary_node(ibound);
147  for (unsigned inod=0;inod<num_nod;inod++)
148  {
149  for (unsigned i=0;i<2;i++)
150  {
151  mesh_pt()->boundary_node_pt(ibound,inod)->set_value(i,0.0);
152  }
153  }
154  }
155  } // end_of_actions_before_newton_solve

References i.

Referenced by main().

◆ actions_before_newton_solve() [2/7]

template<class ELEMENT >
void RectangularDrivenCavityProblem< ELEMENT >::actions_before_newton_solve ( )
inlinevirtual

Update the problem specs before solve. Re-set velocity boundary conditions just to be on the safe side...

Reimplemented from oomph::Problem.

740  {
741  // Setup tangential flow along boundary 0:
742  unsigned ibound=0;
743  unsigned num_nod= mesh_pt()->nboundary_node(ibound);
744  for (unsigned inod=0;inod<num_nod;inod++)
745  {
746  // Tangential flow
747  unsigned i=0;
748  mesh_pt()->boundary_node_pt(ibound,inod)->set_value(i,1.0);
749  // No penetration
750  i=1;
751  mesh_pt()->boundary_node_pt(ibound,inod)->set_value(i,0.0);
752  }
753 
754  // Overwrite with no flow along the other boundaries
755  unsigned num_bound = mesh_pt()->nboundary();
756  for(unsigned ibound=1;ibound<num_bound;ibound++)
757  {
758  unsigned num_nod= mesh_pt()->nboundary_node(ibound);
759  for (unsigned inod=0;inod<num_nod;inod++)
760  {
761  for (unsigned i=0;i<2;i++)
762  {
763  mesh_pt()->boundary_node_pt(ibound,inod)->set_value(i,0.0);
764  }
765  }
766  }
767  } // end_of_actions_before_newton_solve

References i.

◆ actions_before_newton_solve() [3/7]

template<class ELEMENT >
void RectangularDrivenCavityProblem< ELEMENT >::actions_before_newton_solve ( )
inlinevirtual

Update the problem specs before solve. Re-set velocity boundary conditions just to be on the safe side...

Reimplemented from oomph::Problem.

132  {
133  // Setup tangential flow along boundary 0:
134  unsigned ibound=0;
135  unsigned num_nod= mesh_pt()->nboundary_node(ibound);
136  for (unsigned inod=0;inod<num_nod;inod++)
137  {
138  // Tangential flow
139  unsigned i=0;
140  mesh_pt()->boundary_node_pt(ibound,inod)->set_value(i,1.0);
141  // No penetration
142  i=1;
143  mesh_pt()->boundary_node_pt(ibound,inod)->set_value(i,0.0);
144  }
145 
146  // Overwrite with no flow along the other boundaries
147  unsigned num_bound = mesh_pt()->nboundary();
148  for(unsigned ibound=1;ibound<num_bound;ibound++)
149  {
150  unsigned num_nod= mesh_pt()->nboundary_node(ibound);
151  for (unsigned inod=0;inod<num_nod;inod++)
152  {
153  for (unsigned i=0;i<2;i++)
154  {
155  mesh_pt()->boundary_node_pt(ibound,inod)->set_value(i,0.0);
156  }
157  }
158  }
159  } // end_of_actions_before_newton_solve

References i.

◆ actions_before_newton_solve() [4/7]

template<class ELEMENT >
void RectangularDrivenCavityProblem< ELEMENT >::actions_before_newton_solve ( )
inlinevirtual

Update the problem specs before solve. Re-set velocity boundary conditions just to be on the safe side...

Reimplemented from oomph::Problem.

92  {
93  // Setup tangential flow along boundary 0:
94  unsigned ibound=0;
95  unsigned num_nod= mesh_pt()->nboundary_node(ibound);
96  for (unsigned inod=0;inod<num_nod;inod++)
97  {
98  // Tangential flow
99  unsigned i=0;
100  mesh_pt()->boundary_node_pt(ibound,inod)->set_value(i,1.0);
101  // No penetration
102  i=1;
103  mesh_pt()->boundary_node_pt(ibound,inod)->set_value(i,0.0);
104  }
105 
106  // Overwrite with no flow along the other boundaries
107  unsigned num_bound = mesh_pt()->nboundary();
108  for(unsigned ibound=1;ibound<num_bound;ibound++)
109  {
110  unsigned num_nod= mesh_pt()->nboundary_node(ibound);
111  for (unsigned inod=0;inod<num_nod;inod++)
112  {
113  for (unsigned i=0;i<2;i++)
114  {
115  mesh_pt()->boundary_node_pt(ibound,inod)->set_value(i,0.0);
116  }
117  }
118  }
119  } // end_of_actions_before_newton_solve

References i.

◆ actions_before_newton_solve() [5/7]

template<class ELEMENT >
void RectangularDrivenCavityProblem< ELEMENT >::actions_before_newton_solve ( )
inlinevirtual

Update the before solve (empty)

Reimplemented from oomph::Problem.

785 {}

◆ actions_before_newton_solve() [6/7]

template<class ELEMENT >
void RectangularDrivenCavityProblem< ELEMENT >::actions_before_newton_solve ( )
inlinevirtual

Update the problem specs before solve. Re-set velocity boundary conditions just to be on the safe side...

Reimplemented from oomph::Problem.

123  {
124  // Setup tangential flow along boundary 0:
125  unsigned ibound=0;
126  unsigned num_nod= mesh_pt()->nboundary_node(ibound);
127  for (unsigned inod=0;inod<num_nod;inod++)
128  {
129  // Tangential flow
130  unsigned i=0;
131  mesh_pt()->boundary_node_pt(ibound,inod)->set_value(i,1.0);
132  // No penetration
133  i=1;
134  mesh_pt()->boundary_node_pt(ibound,inod)->set_value(i,0.0);
135  }
136 
137  // Overwrite with no flow along the other boundaries
138  unsigned num_bound = mesh_pt()->nboundary();
139  for(unsigned ibound=1;ibound<num_bound;ibound++)
140  {
141  unsigned num_nod= mesh_pt()->nboundary_node(ibound);
142  for (unsigned inod=0;inod<num_nod;inod++)
143  {
144  for (unsigned i=0;i<2;i++)
145  {
146  mesh_pt()->boundary_node_pt(ibound,inod)->set_value(i,0.0);
147  }
148  }
149  }
150  } // end_of_actions_before_newton_solve

References i.

◆ actions_before_newton_solve() [7/7]

template<class ELEMENT >
void RectangularDrivenCavityProblem< ELEMENT >::actions_before_newton_solve ( )
inlinevirtual

Update the problem specs before solve. Re-set velocity boundary conditions just to be on the safe side...

Reimplemented from oomph::Problem.

98  {
99  // Setup tangential flow along boundary 0:
100  unsigned ibound=0;
101  unsigned num_nod= mesh_pt()->nboundary_node(ibound);
102  for (unsigned inod=0;inod<num_nod;inod++)
103  {
104  // Tangential flow
105  unsigned i=0;
106  mesh_pt()->boundary_node_pt(ibound,inod)->set_value(i,1.0);
107  // No penetration
108  i=1;
109  mesh_pt()->boundary_node_pt(ibound,inod)->set_value(i,0.0);
110  }
111 
112  // Overwrite with no flow along the other boundaries
113  unsigned num_bound = mesh_pt()->nboundary();
114  for(unsigned ibound=1;ibound<num_bound;ibound++)
115  {
116  unsigned num_nod= mesh_pt()->nboundary_node(ibound);
117  for (unsigned inod=0;inod<num_nod;inod++)
118  {
119  for (unsigned i=0;i<2;i++)
120  {
121  mesh_pt()->boundary_node_pt(ibound,inod)->set_value(i,0.0);
122  }
123  }
124  }
125  } // end_of_actions_before_newton_solve

References i.

◆ actions_before_newton_step()

template<class ELEMENT >
void RectangularDrivenCavityProblem< ELEMENT >::actions_before_newton_step ( )
inlinevirtual

Any actions that are to be performed before each individual Newton step. Most likely to be used for diagnostic purposes to doc the solution during a non-converging iteration, say.

Reimplemented from oomph::Problem.

792  {
793  // CRDoubleMatrix jac;
794  // DoubleVector res;
795  // get_jacobian(res,jac);
796  // jac.sparse_indexed_output("jac.dat");
797 
798  // unsigned n_dof=ndof();
799  // DenseDoubleMatrix fd_jac(n_dof);
800  // get_fd_jacobian(res,fd_jac);
801  // fd_jac.sparse_indexed_output("fd_jac.dat");
802  // pause("done");
803  }

◆ compare_assembly_strategies()

template<class ELEMENT >
void RectangularDrivenCavityProblem< ELEMENT >::compare_assembly_strategies ( const unsigned method)

Do what it says...

Compare assembly strategies.

Dump matrix?

268 {
269 
270  // Halt code execution?
271  Problem::Pause_at_end_of_sparse_assembly=Global_Variables::Halt_code;
272 
273  DoubleVector residual;
275 
276  Vector<int*> col_index(1);
277  Vector<int* > row_start(1);
279  Vector<unsigned> nnz(1);
280  Vector<double* > residuals(1);
281  bool compressed_row = true;
282 
283  clock_t clock1 = clock();
284 // time_t time1 = std::time(0);
285 
286  switch(method)
287  {
288  case 1:
289 
290  Problem::Sparse_assembly_method=
291  Problem::Perform_assembly_using_vectors_of_pairs;
292 
293  std::cout << std::endl << "Oomph vector of pairs"
294  << std::endl << std::endl;
295  break;
296 
297 
298  case 2:
299 
300  Problem::Sparse_assembly_method=
301  Problem::Perform_assembly_using_two_vectors;
302 
303 
304  std::cout << std::endl << "Oomph two vectors"
305  << std::endl << std::endl;
306  break;
307 
308  case 3:
309 
310  Problem::Sparse_assembly_method=
311  Problem::Perform_assembly_using_maps;
312 
313 
314  std::cout << std::endl << "Oomph maps"
315  << std::endl << std::endl;
316  break;
317 
318 
319  case 4:
320 
321  Problem::Sparse_assembly_method=
322  Problem::Perform_assembly_using_lists;
323 
324 
325  std::cout << std::endl << "Oomph lists"
326  << std::endl << std::endl;
327 
328  break;
329 
330 
331  case 5:
332 
333  Problem::Sparse_assembly_method=
334  Problem::Perform_assembly_using_two_arrays;
335 
336 
337  std::cout << std::endl << "Oomph arrays"
338  << std::endl << std::endl;
339 
340  break;
341 
342  default:
343 
344  std::cout << "Never get here" << std::endl;
345  exit(1);
346 
347  }
348 
349  // Call assembly routine
351  row_start,
352  value,
353  nnz,
354  residuals,
355  compressed_row);
356 
357  clock_t clock2 = clock();
358  //time_t time2 = time(0);
359 
360  cout <<"CPU time for "
361  << Global_Variables::Nx << " x "
362  << Global_Variables::Ny << " mesh; assembly with method "
363  << method << ": "
364  << double(clock2-clock1)/CLOCKS_PER_SEC << "s" << endl;
365 
366 // cout << "Wall time for method " << method << ": "
367 // << difftime(time2, time1) << "s" << endl;
368 
369 //Read out the dimension of the matrix
370  unsigned long n = ndof();
371  LinearAlgebraDistribution dist(this->communicator_pt(),n,false);
372  matrix.build(&dist);
373  matrix.build_without_copy(n,nnz[0],value[0],col_index[0],row_start[0]);
374 
377  {
378  ofstream matrix_file;
379  char filename[100];
380  sprintf(filename,"matrix%i.dat",method);
381  matrix_file.open(filename);
382  matrix.sparse_indexed_output(matrix_file);
383  matrix_file.close();
384  }
385 
386  // clean up
387  delete[] residuals[0];
388 }
const unsigned n
Definition: CG3DPackingUnitTest.cpp:11
Definition: matrices.h:888
Definition: double_vector.h:58
Definition: linear_algebra_distribution.h:64
unsigned long ndof() const
Return the number of dofs.
Definition: problem.h:1674
OomphCommunicator * communicator_pt()
access function to the oomph-lib communicator
Definition: problem.h:1246
virtual void sparse_assemble_row_or_column_compressed(Vector< int * > &column_or_row_index, Vector< int * > &row_or_column_start, Vector< double * > &value, Vector< unsigned > &nnz, Vector< double * > &residual, bool compressed_row_flag)
Definition: problem.cc:4484
Definition: oomph-lib/src/generic/Vector.h:58
Eigen::Map< Eigen::Matrix< T, Eigen::Dynamic, Eigen::Dynamic, Eigen::ColMajor >, 0, Eigen::OuterStride<> > matrix(T *data, int rows, int cols, int stride)
Definition: common.h:85
squared absolute value
Definition: GlobalFunctions.h:87
unsigned Nx
Number of elements in x direction.
Definition: sparse_assemble_test.cc:55
unsigned Ny
Number of elements in x direction.
Definition: sparse_assemble_test.cc:58
bool Halt_code
Definition: sparse_assemble_test.cc:65
bool Dump_matrices
By default we're dumping the matrices for comparison.
Definition: sparse_assemble_test.cc:61
string filename
Definition: MergeRestartFiles.py:39

References Global_Variables::Dump_matrices, MergeRestartFiles::filename, Global_Variables::Halt_code, matrix(), n, Global_Variables::Nx, Global_Variables::Ny, and Eigen::value.

◆ doc_solution() [1/7]

template<class ELEMENT >
void RectangularDrivenCavityProblem< ELEMENT >::doc_solution ( DocInfo doc_info)

Doc the solution.

377 {
378  ofstream some_file;
379  char filename[100];
380 
381  // Number of plot points
382  unsigned npts;
383  npts=5;
384 
385  // Output solution
386  sprintf(filename,"%s/soln%i.dat",doc_info.directory().c_str(),
387  doc_info.number());
388  some_file.open(filename);
389  mesh_pt()->output(some_file,npts);
390  some_file.close();
391 } // end_of_doc_solution
std::string directory() const
Output directory.
Definition: oomph_utilities.h:524
unsigned & number()
Number used (e.g.) for labeling output files.
Definition: oomph_utilities.h:554

References oomph::DocInfo::directory(), MergeRestartFiles::filename, and oomph::DocInfo::number().

◆ doc_solution() [2/7]

template<class ELEMENT >
void RectangularDrivenCavityProblem< ELEMENT >::doc_solution ( DocInfo doc_info)

Doc the solution.

◆ doc_solution() [3/7]

template<class ELEMENT >
void RectangularDrivenCavityProblem< ELEMENT >::doc_solution ( DocInfo doc_info)

Doc the solution.

◆ doc_solution() [4/7]

template<class ELEMENT >
void RectangularDrivenCavityProblem< ELEMENT >::doc_solution ( DocInfo doc_info)

Doc the solution.

◆ doc_solution() [5/7]

template<class ELEMENT >
void RectangularDrivenCavityProblem< ELEMENT >::doc_solution ( DocInfo doc_info)

Doc the solution.

◆ doc_solution() [6/7]

template<class ELEMENT >
void RectangularDrivenCavityProblem< ELEMENT >::doc_solution ( DocInfo doc_info)

Doc the solution.

◆ doc_solution() [7/7]

template<class ELEMENT >
void RectangularDrivenCavityProblem< ELEMENT >::doc_solution ( DocInfo doc_info)

Doc the solution.

◆ fix_pressure() [1/7]

template<class ELEMENT >
void RectangularDrivenCavityProblem< ELEMENT >::fix_pressure ( const unsigned e,
const unsigned pdof,
const double pvalue 
)
inline

Fix pressure in element e at pressure dof pdof and set to pvalue.

114  {
115  //Cast to full element type and fix the pressure at that element
116  dynamic_cast<ELEMENT*>(mesh_pt()->element_pt(e))->
117  fix_pressure(pdof,pvalue);
118  } // end of fix_pressure

References e().

◆ fix_pressure() [2/7]

template<class ELEMENT >
void RectangularDrivenCavityProblem< ELEMENT >::fix_pressure ( const unsigned e,
const unsigned pdof,
const double pvalue 
)
inline

Fix pressure in element e at pressure dof pdof and set to pvalue.

726  {
727  //Cast to full element type and fix the pressure at that element
728  dynamic_cast<ELEMENT*>(mesh_pt()->element_pt(e))->
729  fix_pressure(pdof,pvalue);
730  } // end of fix_pressure

References e().

◆ fix_pressure() [3/7]

template<class ELEMENT >
void RectangularDrivenCavityProblem< ELEMENT >::fix_pressure ( const unsigned e,
const unsigned pdof,
const double pvalue 
)
inline

Fix pressure in element e at pressure dof pdof and set to pvalue.

118  {
119  //Cast to full element type and fix the pressure at that element
120  dynamic_cast<ELEMENT*>(mesh_pt()->element_pt(e))->
121  fix_pressure(pdof,pvalue);
122  } // end of fix_pressure

References e().

◆ fix_pressure() [4/7]

template<class ELEMENT >
void RectangularDrivenCavityProblem< ELEMENT >::fix_pressure ( const unsigned e,
const unsigned pdof,
const double pvalue 
)
inline

Fix pressure in element e at pressure dof pdof and set to pvalue.

78  {
79  //Cast to full element type and fix the pressure at that element
80  dynamic_cast<ELEMENT*>(mesh_pt()->element_pt(e))->
81  fix_pressure(pdof,pvalue);
82  } // end of fix_pressure

References e().

◆ fix_pressure() [5/7]

template<class ELEMENT >
void RectangularDrivenCavityProblem< ELEMENT >::fix_pressure ( const unsigned e,
const unsigned pdof,
const double pvalue 
)
inline

Fix pressure in element e at pressure dof pdof and set to pvalue.

774  {
775  //Cast to full element type and fix the pressure at that element
776  dynamic_cast<ELEMENT*>(mesh_pt()->element_pt(e))->
777  fix_pressure(pdof,pvalue);
778  } // end of fix_pressure

References e().

◆ fix_pressure() [6/7]

template<class ELEMENT >
void RectangularDrivenCavityProblem< ELEMENT >::fix_pressure ( const unsigned e,
const unsigned pdof,
const double pvalue 
)
inline

Fix pressure in element e at pressure dof pdof and set to pvalue.

109  {
110  //Cast to full element type and fix the pressure at that element
111  dynamic_cast<ELEMENT*>(mesh_pt()->element_pt(e))->
112  fix_pressure(pdof,pvalue);
113  } // end of fix_pressure

References e().

◆ fix_pressure() [7/7]

template<class ELEMENT >
void RectangularDrivenCavityProblem< ELEMENT >::fix_pressure ( const unsigned e,
const unsigned pdof,
const double pvalue 
)
inline

Fix pressure in element e at pressure dof pdof and set to pvalue.

86  {
87  //Cast to full element type and fix the pressure at that element
88  dynamic_cast<ELEMENT*>(mesh_pt()->element_pt(e))->
89  fix_pressure(pdof,pvalue);
90  } // end of fix_pressure

References e().

◆ mesh_pt() [1/6]

template<class ELEMENT >
SimpleRectangularQuadMesh<ELEMENT>* RectangularDrivenCavityProblem< ELEMENT >::mesh_pt ( )
inline
159  {
160  // Upcast from pointer to the Mesh base class to the specific
161  // element type that we're using here.
162  return dynamic_cast<SimpleRectangularQuadMesh<ELEMENT>*>(
163  Problem::mesh_pt());
164  }

◆ mesh_pt() [2/6]

template<class ELEMENT >
SimpleRectangularQuadMesh<ELEMENT>* RectangularDrivenCavityProblem< ELEMENT >::mesh_pt ( )
inline
771  {
772  // Upcast from pointer to the Mesh base class to the specific
773  // element type that we're using here.
774  return dynamic_cast<SimpleRectangularQuadMesh<ELEMENT>*>(
775  Problem::mesh_pt());
776  }

◆ mesh_pt() [3/6]

template<class ELEMENT >
SimpleRectangularQuadMesh<ELEMENT>* RectangularDrivenCavityProblem< ELEMENT >::mesh_pt ( )
inline
163  {
164  // Upcast from pointer to the Mesh base class to the specific
165  // element type that we're using here.
166  return dynamic_cast<SimpleRectangularQuadMesh<ELEMENT>*>(
167  Problem::mesh_pt());
168  }

◆ mesh_pt() [4/6]

template<class ELEMENT >
SimpleRectangularQuadMesh<ELEMENT>* RectangularDrivenCavityProblem< ELEMENT >::mesh_pt ( )
inline
123  {
124  // Upcast from pointer to the Mesh base class to the specific
125  // element type that we're using here.
126  return dynamic_cast<SimpleRectangularQuadMesh<ELEMENT>*>(
127  Problem::mesh_pt());
128  }

◆ mesh_pt() [5/6]

template<class ELEMENT >
SimpleRectangularQuadMesh<ELEMENT>* RectangularDrivenCavityProblem< ELEMENT >::mesh_pt ( )
inline
154  {
155  // Upcast from pointer to the Mesh base class to the specific
156  // element type that we're using here.
157  return dynamic_cast<SimpleRectangularQuadMesh<ELEMENT>*>(
158  Problem::mesh_pt());
159  }

◆ mesh_pt() [6/6]

template<class ELEMENT >
SimpleRectangularQuadMesh<ELEMENT>* RectangularDrivenCavityProblem< ELEMENT >::mesh_pt ( )
inline
129  {
130  // Upcast from pointer to the Mesh base class to the specific
131  // element type that we're using here.
132  return dynamic_cast<SimpleRectangularQuadMesh<ELEMENT>*>(
133  Problem::mesh_pt());
134  }

◆ setup_line_plot_points()

template<class ELEMENT >
void RectangularDrivenCavityProblem< ELEMENT >::setup_line_plot_points ( )
inline

Build line plot points.

807  {
808  // Get geom object
810 
811  // Number of radial lines
812  unsigned n_phi=5;
813  Line_plot_point.resize(n_phi);
814 
815  // How many points to you want?
816  unsigned npt=100;
817  double r_max=0.1;
818  Vector<double> zeta(2);
819  Vector<double> s(2);
820  GeomObject* geom_object_pt=0;
821  for (unsigned i=0;i<n_phi;i++)
822  {
823  Line_plot_point[i].resize(npt);
824  double phi=0.5*MathematicalConstants::Pi*double(i)/double(n_phi-1);
825  oomph_info << "setup at phi : " << phi/(0.5*MathematicalConstants::Pi)
826  << " pi/2" << std::endl;
827  for (unsigned j=0;j<npt;j++)
828  {
829  double r=r_max*double(j+1)/double(npt);
830  zeta[0]=r*cos(phi);
831  zeta[1]=r*sin(phi);
832  Mesh_as_geom_object_pt->locate_zeta(zeta,geom_object_pt,s);
833  if (geom_object_pt==0)
834  {
835  oomph_info << "Point : "
836  << zeta[0] << " "
837  << zeta[1] << " "
838  << " not found in setup of line plots"
839  << std::endl;
840  }
841  Line_plot_point[i][j]=std::make_pair(geom_object_pt,s);
842  }
843  }
844  }
AnnoyingScalar cos(const AnnoyingScalar &x)
Definition: AnnoyingScalar.h:136
AnnoyingScalar sin(const AnnoyingScalar &x)
Definition: AnnoyingScalar.h:137
MeshAsGeomObject * Mesh_as_geom_object_pt
Mesh as geom object representation of mesh.
Definition: navier_stokes/navier_stokes_with_singularity/driven_cavity.cc:864
Vector< Vector< std::pair< GeomObject *, Vector< double > > > > Line_plot_point
Line_plot_point[i_phi][i_rho].
Definition: navier_stokes/navier_stokes_with_singularity/driven_cavity.cc:867
Mesh * Navier_stokes_mesh_pt
Pointer to mesh with Poisson elements.
Definition: navier_stokes/navier_stokes_with_singularity/driven_cavity.cc:861
Definition: geom_objects.h:101
Definition: mesh_as_geometric_object.h:93
void locate_zeta(const Vector< double > &zeta, GeomObject *&sub_geom_object_pt, Vector< double > &s, const bool &use_coordinate_as_initial_guess=false)
Definition: mesh_as_geometric_object.h:373
RealScalar s
Definition: level1_cplx_impl.h:130
double r_max
Definition: two_d_biharmonic.cc:238
double Pi
Definition: two_d_biharmonic.cc:235
EIGEN_STRONG_INLINE const Eigen::CwiseBinaryOp< Eigen::internal::scalar_zeta_op< typename DerivedX::Scalar >, const DerivedX, const DerivedQ > zeta(const Eigen::ArrayBase< DerivedX > &x, const Eigen::ArrayBase< DerivedQ > &q)
Definition: SpecialFunctionsArrayAPI.h:152
r
Definition: UniformPSDSelfTest.py:20
OomphInfo oomph_info
Definition: oomph_definitions.cc:319
std::ptrdiff_t j
Definition: tut_arithmetic_redux_minmax.cpp:2

References cos(), i, j, oomph::oomph_info, BiharmonicTestFunctions2::Pi, UniformPSDSelfTest::r, BiharmonicTestFunctions2::r_max, s, sin(), and Eigen::zeta().

◆ sparse_assemble_row_or_column_compressed_test()

template<class ELEMENT >
void RectangularDrivenCavityProblem< ELEMENT >::sparse_assemble_row_or_column_compressed_test ( Vector< Vector< int > > &  column_or_row_index,
Vector< Vector< int > > &  row_or_column_start,
Vector< Vector< double > > &  value,
Vector< Vector< double > * > &  residuals,
bool  compressed_row_flag,
unsigned  method = 1 
)

To be killed.

Member Data Documentation

◆ F_matrix_preconditioner_pt

template<class ELEMENT >
Preconditioner * RectangularDrivenCavityProblem< ELEMENT >::F_matrix_preconditioner_pt
private

Inexact solver for F block.

◆ Line_plot_point

template<class ELEMENT >
Vector<Vector<std::pair<GeomObject*,Vector<double> > > > RectangularDrivenCavityProblem< ELEMENT >::Line_plot_point
private

Line_plot_point[i_phi][i_rho].

◆ Mesh_as_geom_object_pt

template<class ELEMENT >
MeshAsGeomObject* RectangularDrivenCavityProblem< ELEMENT >::Mesh_as_geom_object_pt
private

Mesh as geom object representation of mesh.

◆ Navier_stokes_mesh_pt

template<class ELEMENT >
Mesh* RectangularDrivenCavityProblem< ELEMENT >::Navier_stokes_mesh_pt
private

Pointer to mesh with Poisson elements.

◆ P_matrix_preconditioner_pt

template<class ELEMENT >
Preconditioner * RectangularDrivenCavityProblem< ELEMENT >::P_matrix_preconditioner_pt
private

Inexact solver for P block.

◆ Prec_pt

template<class ELEMENT >
NavierStokesSchurComplementPreconditioner * RectangularDrivenCavityProblem< ELEMENT >::Prec_pt
private

Preconditioner.

◆ Singular_navier_stokes_solution1_element_pt

template<class ELEMENT >
SingularNavierStokesSolutionElement<ELEMENT>* RectangularDrivenCavityProblem< ELEMENT >::Singular_navier_stokes_solution1_element_pt
private

Pointer to the element defining the unknown C1 (Note: eqn element is templated by the wrapped element!)

◆ Singular_navier_stokes_solution2_element_pt

template<class ELEMENT >
SingularNavierStokesSolutionElement<ELEMENT>* RectangularDrivenCavityProblem< ELEMENT >::Singular_navier_stokes_solution2_element_pt
private

Pointer to the element defining the unknown C2 (Note: eqn element is templated by the wrapped element!)

◆ Singular_navier_stokes_solution_mesh_pt

template<class ELEMENT >
Mesh* RectangularDrivenCavityProblem< ELEMENT >::Singular_navier_stokes_solution_mesh_pt
private

Pointer to the C mesh associated with the elements defining the unknowns C1 and C2

◆ Solver_pt

template<class ELEMENT >
IterativeLinearSolver * RectangularDrivenCavityProblem< ELEMENT >::Solver_pt
private

oomph-lib iterative linear solver


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