Changeset 24982
- Timestamp:
- 06/08/20 16:34:18 (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
issm/trunk-jpl/src/c/cores/sealevelrise_core.cpp
r24977 r24982 73 73 /*variables:*/ 74 74 Vector<IssmDouble> *RSLg = NULL; 75 Vector<IssmDouble> *BPg = NULL; 75 76 Vector<IssmDouble> *RSLg_rate = NULL; 76 77 Vector<IssmDouble> *RSLg_eustatic = NULL; … … 95 96 int horiz; 96 97 int geodetic=0; 97 IssmDouble dt; 98 IssmDouble oceanarea; 98 IssmDouble dt; 99 IssmDouble oceanarea; 100 int bp_compute_fingerprints=0; 99 101 100 102 /*Should we even be here?:*/ … … 169 171 /*recover N_esa = U_esa + RSLg:*/ 170 172 N_esa=U_esa->Duplicate(); U_esa->Copy(N_esa); N_esa->AXPY(RSLg,1); 173 174 /*if we had bottom pressure loading, remove dynamic sea level from geoid: */ 175 femmodel->parameters->FindParam(&bp_compute_fingerprints,DslComputeFingerprintsEnum); 176 if(bp_compute_fingerprints){ 177 GetVectorFromInputsx(&BPg,femmodel,DslSeaWaterPressureChangeAtSeaFloor,VertexSIdEnum); 178 N_esa->AXPY(BPg,-1); 179 } 171 180 172 181 /*transform these values into rates (as we only run this once each frequency turn:*/ … … 218 227 delete N_esa; 219 228 delete N_esa_rate; 229 delete BPg; 220 230 221 231 if(horiz){ … … 343 353 Vector<IssmDouble> *RSLg = NULL; 344 354 Vector<IssmDouble> *RSLg_old = NULL; 355 Vector<IssmDouble> *BPg = NULL; 345 356 346 357 Vector<IssmDouble> *RSLgo = NULL; //ocean convolution of the perturbation to gravity potential. … … 360 371 IssmDouble eustatic; 361 372 IssmDouble Ixz, Iyz, Izz; 373 int bp_compute_fingerprints= 0; 362 374 363 375 if(VerboseSolution()) _printf0_(" converging on ocean components\n"); … … 425 437 /*convergence criterion:*/ 426 438 slrconvergence(&converged,RSLg,RSLg_old,eps_rel,eps_abs); 439 440 /*if we had bottom pressure loading, add dynamic sea level 441 * to RSL:*/ 442 femmodel->parameters->FindParam(&bp_compute_fingerprints,DslComputeFingerprintsEnum); 443 if(bp_compute_fingerprints){ 444 GetVectorFromInputsx(&BPg,femmodel,DslSeaWaterPressureChangeAtSeaFloor,VertexSIdEnum); 445 RSLg->AXPY(BPg,1); 446 } 427 447 428 448 /*free ressources: */ … … 448 468 449 469 delete RSLg_old; 470 delete BPg; 450 471 451 472 return RSLg;
Note:
See TracChangeset
for help on using the changeset viewer.