Ignore:
Timestamp:
05/22/13 11:24:30 (12 years ago)
Author:
Mathieu Morlighem
Message:

DEL: removed InputConvergence module that is not used anymore and calls GetValuesPtr, which HAS to be deleted because it is wrong to plya with the pointer of another object's field

File:
1 edited

Legend:

Unmodified
Added
Removed
  • issm/trunk-jpl/src/c/classes/Inputs/PentaP1Input.cpp

    r15012 r15082  
    477477void PentaP1Input::VerticallyIntegrate(Input* thickness_input){
    478478
    479         /*Intermediaries*/
    480         int i;
    481         const int  numnodes = 6;
    482         int        num_thickness_values;
    483         IssmDouble    *thickness_values = NULL;
     479        IssmDouble thickness;
    484480
    485481        /*Check that input provided is a thickness*/
    486482        if (thickness_input->InstanceEnum()!=ThicknessEnum) _error_("Input provided is not a Thickness (enum_type is " << EnumToStringx(thickness_input->InstanceEnum()) << ")");
    487483
    488         /*Get Thickness value pointer*/
    489         thickness_input->GetValuesPtr(&thickness_values,&num_thickness_values);
    490 
    491484        /*vertically integrate depending on type:*/
    492485        switch(thickness_input->ObjectEnum()){
    493486
    494                 case PentaP1InputEnum:
    495                         for(i=0;i<3;i++){
    496                                 this->values[i]=0.5*(this->values[i]+this->values[i+3]) * thickness_values[i];
    497                                 this->values[i+3]=this->values[i];
     487                case PentaP1InputEnum:{
     488                        GaussPenta *gauss=new GaussPenta();
     489                        for(int iv=0;iv<3;iv++){
     490                                gauss->GaussVertex(iv);
     491                                thickness_input->GetInputValue(&thickness,gauss);
     492                                this->values[iv]=0.5*(this->values[iv]+this->values[iv+3]) * thickness;
     493                                this->values[iv+3]=this->values[iv];
    498494                        }
    499                         return;
     495                        delete gauss;
     496                        return; }
    500497
    501498                default:
     
    600597
    601598} /*}}}*/
    602 /*FUNCTION PentaP1Input::GetValuesPtr{{{*/
    603 void PentaP1Input::GetValuesPtr(IssmDouble** pvalues,int* pnum_values){
    604 
    605         *pvalues=this->values;
    606         *pnum_values=6;
    607 
    608 }
    609 /*}}}*/
    610599/*FUNCTION PentaP1Input::Configure{{{*/
    611600void PentaP1Input::Configure(Parameters* parameters){
Note: See TracChangeset for help on using the changeset viewer.