Changeset 11393


Ignore:
Timestamp:
02/10/12 10:05:41 (13 years ago)
Author:
seroussi
Message:

minor enthalpy

File:
1 edited

Legend:

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

    r11392 r11393  
    37083708        double rho_ice,heatcapacity;
    37093709        double thermalconductivity,kappa;
    3710         double viscosity,enthalpy,pressure;
     3710        double viscosity,pressure;
     3711        double enthalpy,enthalpypicard;
    37113712        double tau_parameter,diameter;
    37123713        double u,v,w;
     
    37333734        Input* vz_input=inputs->GetInput(VzEnum);                                  _assert_(vz_input);
    37343735        Input* pressure_input=inputs->GetInput(PressureEnum);                      _assert_(pressure_input);
    3735         Input* enthalpy_input=NULL; enthalpy_input=inputs->GetInput(EnthalpyEnum); _assert_(enthalpy_input);
    3736         if (stabilization==2) diameter=MinEdgeLength(xyz_list);
     3736        Input* enthalpy_input=NULL;
     3737        Input* enthalpypicard_input=NULL;
     3738        if(dt){
     3739                enthalpy_input=inputs->GetInput(EnthalpyEnum); _assert_(enthalpy_input);
     3740        }
     3741        if (stabilization==2){
     3742                diameter=MinEdgeLength(xyz_list);
     3743                enthalpypicard_input=inputs->GetInput(EnthalpyPicardEnum); _assert_(enthalpypicard_input);
     3744        }
    37373745
    37383746        /* Start  looping on the number of gaussian points: */
     
    37473755                this->GetStrainRate3d(&epsilon[0],&xyz_list[0][0],gauss,vx_input,vy_input,vz_input);
    37483756                matice->GetViscosity3dStokes(&viscosity,&epsilon[0]);
    3749                 enthalpy_input->GetInputValue(&enthalpy, gauss);
    37503757                GetPhi(&phi, &epsilon[0], viscosity);
    37513758
     
    37573764                /* Build transient now */
    37583765                if(dt){
     3766                        enthalpy_input->GetInputValue(&enthalpy, gauss);
    37593767                        scalar_transient=enthalpy*Jdet*gauss->weight;
    37603768                        for(i=0;i<NUMVERTICES;i++)  pe->values[i]+=scalar_transient*L[i];
     
    37683776                        vz_input->GetInputValue(&w, gauss);
    37693777                        pressure_input->GetInputValue(&pressure, gauss);
     3778                        enthalpypicard_input->GetInputValue(&enthalpypicard, gauss);
    37703779                        kappa=matpar->GetEnthalpyDiffusionParameter(enthalpy,pressure);
    37713780                        tau_parameter=GetStabilizationParameter(u,v,w,diameter,kappa);
     
    43324341                        matpar->EnthalpyToThermal(&temperatures[i],&waterfraction[i],values[i],pressure[i]);
    43334342                        if(waterfraction[i]<0) _error_("Negative water fraction found in solution vector");
    4334                         if(waterfraction[i]>1) _error_("Water fraction >1 found in solution vector");
     4343                        //if(waterfraction[i]>1) _error_("Water fraction >1 found in solution vector");
    43354344                }
    43364345                       
Note: See TracChangeset for help on using the changeset viewer.