Ignore:
Timestamp:
05/04/23 17:45:09 (23 months ago)
Author:
Mathieu Morlighem
Message:

NEW: moving J to cost function itself instead of being weirdly handled

File:
1 edited

Legend:

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

    r27721 r27728  
    159159        /*Check that we have not yet calculated this cost function*/
    160160        if(this->passedflags[pos]){
    161                 return 0.;
    162                 //return this->J; //FIXME
     161                return this->J;
    163162        }
    164163
     
    172171        /*Sum across partition*/
    173172        IssmDouble J_sum;
    174         ISSM_MPI_Allreduce( (void*)&J_part,(void*)&J_sum,1,ISSM_MPI_DOUBLE,ISSM_MPI_SUM,IssmComm::GetComm());
     173        ISSM_MPI_Allreduce((void*)&J_part,(void*)&J_sum,1,ISSM_MPI_DOUBLE,ISSM_MPI_SUM,IssmComm::GetComm());
    175174        ISSM_MPI_Bcast(&J_sum,1,ISSM_MPI_DOUBLE,0,IssmComm::GetComm());
    176175
     
    180179
    181180        /*Return full cost function this far*/
    182         //return this->J; //FIXME
    183         return J_sum;
     181        return this->J;
    184182}/*}}}*/
    185183IssmDouble Cfsurfacesquaretransient::Cfsurfacesquaretransient_Calculation(Element* element, int model_enum){/*{{{*/
Note: See TracChangeset for help on using the changeset viewer.