00001 #include "hvisolver.h"
00002 #include "global.h"
00003 #include "globmat.h"
00004
00005 #include "gmatrix.h"
00006 #include "mechprint.h"
00007
00008
00009
00010 #include <stdlib.h>
00011
00012
00013
00014
00015
00016
00017
00018 void solve_hemivariational_inequalities ()
00019 {
00020 long i,j,lcid,nbdof,nidof;
00021 double *lhs,*rhs,*condmat,*condvec;
00022
00023
00024 lcid=0;
00025
00026
00027 stiffness_matrix (lcid);
00028
00029
00030 lhs = Lsrs->give_lhs (lcid);
00031 rhs = Lsrs->give_rhs (lcid);
00032
00033
00034 mefel_right_hand_side (lcid,rhs);
00035
00036
00037
00038
00039
00040 nbdof=Gtm->nbdof;
00041
00042 nidof=Gtm->nidof;
00043
00044 condmat = new double [nbdof*nbdof];
00045 condvec = new double [nbdof];
00046
00047
00048
00049 j=0;
00050 for (i=nidof;i<Ndofm;i++){
00051 condvec[j]=rhs[i]; j++;
00052 }
00053
00054
00055
00056
00057
00058 print_init(-1, "wt");
00059 for (i=0;i<Lsrs->nlc;i++){
00060
00061
00062
00063 compute_req_val (i);
00064 print_step(i, 0, 0.0, NULL);
00065 }
00066 print_close();
00067
00068 delete [] condvec;
00069 delete [] condmat;
00070 }
00071
00072