Changeset 9843


Ignore:
Timestamp:
09/19/11 15:12:14 (14 years ago)
Author:
Mathieu Morlighem
Message:

artfidd is now a variable of the model for hydrology solution

File:
1 edited

Legend:

Unmodified
Added
Removed
  • issm/trunk/src/c/objects/Elements/Tria.cpp

    r9817 r9843  
    49054905        Input* vx_input=inputs->GetInput(HydrologyWaterVxEnum); _assert_(vx_input);
    49064906        Input* vy_input=inputs->GetInput(HydrologyWaterVyEnum); _assert_(vy_input);
    4907         h=this->GetArea();
     4907        h=sqrt(2*this->GetArea());
    49084908
    49094909        /* Start  looping on the number of gaussian points: */
     
    49504950                                        &Ke->values[0],1);
    49514951
    4952                 if(artdiff){
    4953                         vel=sqrt(pow(vx,2.)+pow(vy,2.));
    4954                         K[0][0]=h/(2*vel)*vx*vx;
    4955                         K[1][0]=h/(2*vel)*vy*vx;
    4956                         K[0][1]=h/(2*vel)*vx*vy;
    4957                         K[1][1]=h/(2*vel)*vy*vy;
    4958                         KDL[0][0]=DL_scalar*K[0][0];
    4959                         KDL[1][0]=DL_scalar*K[1][0];
    4960                         KDL[0][1]=DL_scalar*K[0][1];
    4961                         KDL[1][1]=DL_scalar*K[1][1];
    4962 
    4963                         TripleMultiply( &Bprime[0][0],2,numdof,1,
    4964                                                 &KDL[0][0],2,2,0,
    4965                                                 &Bprime[0][0],2,numdof,0,
    4966                                                 &Ke->values[0],1);
    4967                 }
     4952                /*Artificial diffusivity*/
     4953                vel=sqrt(pow(vx,2.)+pow(vy,2.));
     4954                K[0][0]=artdiff*h/(2*vel)*vx*vx;
     4955                K[1][0]=artdiff*h/(2*vel)*vy*vx;
     4956                K[0][1]=artdiff*h/(2*vel)*vx*vy;
     4957                K[1][1]=artdiff*h/(2*vel)*vy*vy;
     4958                KDL[0][0]=DL_scalar*K[0][0];
     4959                KDL[1][0]=DL_scalar*K[1][0];
     4960                KDL[0][1]=DL_scalar*K[0][1];
     4961                KDL[1][1]=DL_scalar*K[1][1];
     4962
     4963                TripleMultiply( &Bprime[0][0],2,numdof,1,
     4964                                        &KDL[0][0],2,2,0,
     4965                                        &Bprime[0][0],2,numdof,0,
     4966                                        &Ke->values[0],1);
    49684967        }
    49694968
Note: See TracChangeset for help on using the changeset viewer.