00001 #ifndef FETI1_H 00002 #define FETI1_H 00003 00004 #include <stdio.h> 00005 #include "mpi.h" 00006 #include "../GEFEL/gtopology.h" 00007 #include "../GEFEL/gmatrix.h" 00008 00009 /** 00010 class paral contains information about local-global ordering 00011 00012 ************************************************* 00013 FINITE ELEMENT TEARING AND INTERCONNECTING METHOD 00014 ************************************************* 00015 nproc, myrank, ndom 00016 number of processors, myrank and number of domain are established 00017 after constructor execution 00018 00019 ndof 00020 total number of local unknowns is established after execution 00021 of function schurordering 00022 00023 nbndom (M) 00024 array of numbers of boundary nodes on subdomains is established after 00025 execution of function globcnnum_feti 00026 00027 maxnbn, totmaxndofn 00028 maximum number of boundary nodes and maximum number of degrees of freedom 00029 on node are established after execution of globcnnum_feti 00030 00031 maxinc 00032 maximum number of incidencies is established after execution of globcnnum_feti 00033 00034 ngdof (M) 00035 total number of global unknowns is established after execution of 00036 function globcnnum_feti 00037 00038 nodnum 00039 array of legth nbn containing global node numbers; components correspond 00040 only to boundary nodes, internal nodes are excluded 00041 array is established after execution of function globcnnum_feti 00042 00043 inc, lcngcn 00044 array of numbers of incidencies of nodes to subdomains and 00045 global code numbers in FETI method are established after execution 00046 of function globcnnum_feti 00047 00048 00049 */ 00050 class feti1 00051 { 00052 public: 00053 feti1 (int np,int mr,int nd); 00054 ~feti1(); 00055 void globcnnum_feti (gtopology *top,long *ltg,long *domproc,FILE *out); 00056 void locglobfeti (gtopology *top,double *gv,double *lv); 00057 void globlocfeti (gtopology *top,double *gv,double *lv); 00058 00059 void hmatrixsize (double *rbm,long &maxnrbm,long *domproc); 00060 void hmatrix (gtopology *top,double *h,double *rbm,long maxnrbm,long *domproc); 00061 void qvector (double *q,double *rbm,double *f,long maxnrbm,long *domproc); 00062 void feti_projection (double *v,double *h,double *h1); 00063 void mpcg (gtopology *top,gmatrix *gm, 00064 double *w,double *rhs,double *q,double *h,double *h1,long *rbmi,FILE *out); 00065 void lagrmultdispl (gtopology *top,gmatrix *gm,long *domproc, 00066 double *w,double *d,double *f,double *rbm,long *rbmi, 00067 double *h,double *h1); 00068 void lumpedprec (gtopology *top,double *v,double *pv); 00069 00070 00071 void solve_system (gtopology *top,gmatrix *gm, 00072 long *domproc,double *lhs,double *rhs,FILE *out); 00073 00074 00075 // number of processors 00076 int nproc; 00077 // rank of processor 00078 int myrank; 00079 // number of subdomain 00080 int ndom; 00081 00082 // number of degrees of freedom on subdomain 00083 long ndof; 00084 // number of boundary nodes 00085 long nbn; 00086 // maximum number of degrees of freedom on node 00087 long totmaxndofn; 00088 00089 // array containing global code numbers in FETI method 00090 long **lcngcn; 00091 // array containing numbers of incidencies of nodes to subdomains 00092 long *inc; 00093 // array containing global node numbers of boundary nodes 00094 long *nodnum; 00095 00096 // estimate of number of rigid body motions 00097 long enrbm; 00098 // threshold for linear dependence 00099 double lithr; 00100 // number of ridig body motions 00101 long nrbm; 00102 // size of matrix H 00103 long hsize; 00104 00105 // maximum number of iterations in conjugate gradient method 00106 long nicg; 00107 // number of performed iterations in conjugate gradient method 00108 long anicg; 00109 // required error 00110 double errcg; 00111 // attained error 00112 double aerrcg; 00113 // computer zero 00114 double zero; 00115 00116 //******************************************** 00117 // VARIABLES DEFINED ONLY ON MASTER PROCESSOR 00118 // 00119 // number of global DOFs = total number of boundary DOFs 00120 long ngdof; 00121 00122 // array containing numbers of boundary nodes on subdomains 00123 long *nbndom; 00124 // array containing numbers of RBM on subdomains 00125 long *nrbmdom; 00126 // array containing addresses of first RBM in coarse matrix 00127 long *rbmadr; 00128 00129 }; 00130 00131 00132 #endif