Changeset 7369


Ignore:
Timestamp:
02/07/11 10:03:50 (14 years ago)
Author:
Eric.Larour
Message:

thermal and water elements creating problems

File:
1 edited

Legend:

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

    r7367 r7369  
    16501650/*FUNCTION Penta::CreateKMatrixThermal {{{1*/
    16511651ElementMatrix* Penta::CreateKMatrixThermal(void){
     1652       
     1653        ElementMatrix* Ke =NULL;
    16521654
    16531655        /*compute all stiffness matrices for this element*/
    16541656        ElementMatrix* Ke1=CreateKMatrixThermalVolume();
    16551657        ElementMatrix* Ke2=CreateKMatrixThermalShelf();
    1656         ElementMatrix* Ke =new ElementMatrix(Ke1,Ke2);
    1657 
    1658         /*clean-up and return*/
    1659         delete Ke1;
    1660         delete Ke2;
     1658       
     1659        if(Ke1 || Ke2){
     1660                 Ke=new ElementMatrix(Ke1,Ke2);
     1661
     1662                /*clean-up and return*/
     1663                delete Ke1;
     1664                delete Ke2;
     1665        }
    16611666        return Ke;
    16621667}
Note: See TracChangeset for help on using the changeset viewer.