Changeset 25267


Ignore:
Timestamp:
07/10/20 23:01:28 (5 years ago)
Author:
Eric.Larour
Message:

CHG: added assert and fixed pretty big bug.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • issm/trunk-jpl/src/c/classes/Elements/Tria.cpp

    r25256 r25267  
    60586058        else if(type==TransientInput2Enum){
    60596059
    6060 
    60616060                IssmDouble* steps=NULL;
    60626061                int nsteps;
     
    60656064
    60666065                /*retrieve transient input:*/
    6067                 transientinput= this->inputs2->GetTransientInput(name);
    6068                 transientinput2= this->inputs2->GetTransientInput(DummyEnum);
     6066                transientinput= this->inputs2->GetTransientInput(name); _assert_(transientinput);
     6067                transientinput2= this->inputs2->GetTransientInput(DummyEnum); _assert_(transientinput2);
    60696068
    60706069                /*retrieve time steps: */
     
    61016100                                for (int j=0;j<NUMVERTICES;j++){
    61026101                                        values[j]=triainput->element_values[j];
    6103                                         if(partition[this->vertices[i]->Sid()]!=-1){
     6102                                        if(partition[this->vertices[j]->Sid()]!=-1){
    61046103                                                if(nt==1) values[j]*=distributed_values[(int)partition[this->vertices[j]->Sid()]];//we scale all the time steps  with the same distributed_value
    61056104                                                else values[j]*=distributed_values[(int)partition[this->vertices[j]->Sid()]*nsteps+i];//we scale all the time steps with distributed value for each step
Note: See TracChangeset for help on using the changeset viewer.