00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013 #ifndef _CTRL_H
00014 #define _CTRL_H
00015
00016
00017
00018
00019 typedef enum _ctrltype
00020 {
00021 PATH,
00022 STABILITY
00023 } eCtrlType;
00024
00025
00026
00027
00028 typedef enum _updtype
00029 {
00030 STANDARD,
00031 MODIFIED
00032 } eUpdType;
00033
00034
00035
00036
00037 typedef enum _linsoltype
00038 {
00039 LDLT,
00040 PCG
00041 } eLinSolType;
00042
00043
00044
00045
00046 class cFem;
00047 class cSysMatrix;
00048
00049
00050
00051
00052 class cCtrl
00053 {
00054 protected:
00055 static int _PrintStep;
00056 static int _CurrIte;
00057 static int _CurrStep;
00058 static int _NumEq;
00059 static int _NumMaxIte;
00060 static int _NumMaxStep;
00061 static int _NumPrintStep;
00062 static int *_Profile;
00063 static double _Tol;
00064 static double _TotFactor;
00065 static double _StepFactor;
00066 static eCtrlType _CtrlType;
00067 static eLinSolType _LinSolType;
00068 static eUpdType _UpdType;
00069 static cFem *_Fem;
00070
00071 public:
00072 static int GetNumMaxIter (void) { return _NumMaxIte; }
00073 static int GetNumMaxStep (void) { return _NumMaxStep; }
00074 static int GetNumPrintStep(void) { return _NumPrintStep; }
00075 static int GetNumStep (void) { return _CurrStep; }
00076 static double GetTol (void) { return _Tol; }
00077 static double GetTotFactor (void) { return _TotFactor; }
00078 static void SetTotFactor (double tf) { _TotFactor = tf; }
00079 static cCtrl *Read (void);
00080 cCtrl (void);
00081 virtual ~cCtrl (void);
00082 virtual void Analysis (cFem * );
00083 virtual void Init (void);
00084 virtual void Solver (void) { }
00085
00086 protected:
00087 static cSysMatrix *CreateSysMatrix(void);
00088 static void PrintStep (void);
00089
00090 private:
00091 static void ReadLinSolver(void);
00092 static cCtrl *ReadAlgorithm(void);
00093 static void PrintInData (void);
00094 };
00095
00096 #endif