Changeset 3976


Ignore:
Timestamp:
05/27/10 15:26:16 (15 years ago)
Author:
seroussi
Message:

added UpdateInputsFromSolution for balancedthickness in Tria

Location:
issm/trunk/src/c/objects/Elements
Files:
2 edited

Legend:

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

    r3956 r3976  
    21162116                }
    21172117        }
    2118 
    21192118
    21202119        /*Add Ke_gg to global matrix Kgg: */
  • issm/trunk/src/c/objects/Elements/Tria.cpp

    r3965 r3976  
    599599/*FUNCTION Tria::UpdateInputsFromSolutionBalancedthickness {{{1*/
    600600void  Tria::UpdateInputsFromSolutionBalancedthickness(double* solution, int analysis_type, int sub_analysis_type){
    601         ISSMERROR(" not supported yet!");
     601
     602        int i;
     603
     604        const int    numvertices=3;
     605        const int    numdofpervertex=1;
     606        const int    numdof=numdofpervertex*numvertices;
     607
     608        int          doflist[numdof];
     609        double       values[numdof];
     610        double       thickness[numvertices];
     611
     612        int          dummy;
     613
     614        /*Get dof list: */
     615        GetDofList(&doflist[0],&dummy);
     616
     617        /*Use the dof list to index into the solution vector: */
     618        for(i=0;i<numdof;i++){
     619                values[i]=solution[doflist[i]];
     620        }
     621
     622        /*Add thickness as inputs to the tria element: */
     623        this->inputs->AddInput(new TriaVertexInput(ThicknessEnum,values));
    602624}
    603625/*}}}*/
Note: See TracChangeset for help on using the changeset viewer.