OpenFCST: The open-source Fuel Cell Simulation Toolbox
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
picard.h
Go to the documentation of this file.
1 //---------------------------------------------------------------------------
2 //
3 // FCST: Fuel Cell Simulation Toolbox
4 //
5 // Copyright (C) 2009-13 by Energy Systems Design Laboratory, University of Alberta
6 //
7 // This software is distributed under the MIT License.
8 // For more information, see the README file in /doc/LICENSE
9 //
10 // - Class: picard.h
11 // - Description: Picard Solver for Non-linear problems
12 // - Developers: Mayank Sabharwal
13 //
14 //---------------------------------------------------------------------------
15 
16 #ifndef __deal2__appframe__picard_h
17 #define __deal2__appframe__picard_h
18 
19 #include <solvers/picard_base.h>
20 
21 namespace FuelCell
22 {
23 namespace ApplicationCore
24 {
54  class Picard : public PicardBase
55  {
56  public:
62 
64  virtual void declare_parameters (ParameterHandler& param);
65 
67  virtual void initialize (ParameterHandler& param);
68 
73  const FuelCell::ApplicationCore::FEVectors& in_vectors);
74  private:
75 
80 
84  double alpha;
85 
89  double gamma_min;
90 
91  void compute_errors ( FEVector &u, FEVector &u_n, FEVector &error, double &abs_error, double &rel_error, double &delta);
92 
93 
94  };
95 }
96 }
97 
98 #endif
bool underrelaxation
Flag for using adaptive under-relaxation.
Definition: picard.h:79
virtual void solve(FuelCell::ApplicationCore::FEVector &u, const FuelCell::ApplicationCore::FEVectors &in_vectors)
The actual Picard solver.
Picard(ApplicationBase &app)
Constructor, receiving the application computing the residual and solving the linear problem...
void compute_errors(FEVector &u, FEVector &u_n, FEVector &error, double &abs_error, double &rel_error, double &delta)
double alpha
Alpha value to be used in the under-relaxation scheme proposed in Durbin and Delemos(2007) ...
Definition: picard.h:84
double gamma_min
Gamma_min value to be used in the under-relaxation scheme proposed in Durbin and Delemos(2007) ...
Definition: picard.h:89
virtual void declare_parameters(ParameterHandler &param)
Declare the input parameters.
SmartPointer< ApplicationBase > app
Pointer to the application this one depends upon.
Definition: application_wrapper.h:106
Base class for all classes performing Picard iterations.
Definition: picard_base.h:53
Base class for applications.
Definition: application_base.h:113
virtual void initialize(ParameterHandler &param)
Read the parameters.
Application class performing a Picard iteration as described in the PicardBase.
Definition: picard.h:54
BlockVector< double > FEVector
The vector class used by applications.
Definition: application_data.h:46
The data type used in function calls of Application.
Definition: fe_vectors.h:59