source:
issm/oecreview/Archive/12678-13393/ISSM-12862-12863.diff
Last change on this file was 13394, checked in by , 13 years ago | |
---|---|
File size: 1.8 KB |
-
u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/c/toolkits/issm/SeqVec.cpp
41 41 this->M=pM; 42 42 this->vector=NULL; 43 43 if(this->M){ 44 this->vector=xNew ZeroInit<IssmDouble>(pM);44 this->vector=xNew<IssmDouble>(pM); 45 45 xMemCpy<IssmDouble>(this->vector,buffer,pM); 46 46 } 47 47 } -
u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/c/toolkits/petsc/objects/PetscVec.cpp
33 33 34 34 } 35 35 /*}}}*/ 36 /*FUNCTION PetscVec::PetscVec(Vec petsc_vec){{{*/ 37 PetscVec::PetscVec(Vec petsc_vec){ 38 39 if(petsc_vec==NULL){ 40 this->vector=NewVec(0); 41 } 42 else{ 43 /*copy vector*/ 44 VecDuplicate(petsc_vec,&this->vector); 45 VecCopy(petsc_vec,this->vector); 46 } 47 48 } 49 /*}}}*/ 36 50 /*FUNCTION PetscVec::PetscVec(IssmDouble* serial_vec,int M){{{*/ 37 51 PetscVec::PetscVec(IssmDouble* serial_vec,int M){ 38 52 … … 53 67 VecFree(&this->vector); 54 68 } 55 69 /*}}}*/ 56 /*FUNCTION Vector::Vector(Vec petsc_vec){{{*/57 PetscVec::PetscVec(Vec petsc_vec){58 70 59 if(petsc_vec==NULL){60 this->vector=NewVec(0);61 }62 else{63 /*copy vector*/64 VecDuplicate(petsc_vec,&this->vector);65 VecCopy(petsc_vec,this->vector);66 }67 68 }69 /*}}}*/70 71 71 /*PetscVec specific routines: */ 72 72 /*FUNCTION PetscVec::Echo{{{*/ 73 73 void PetscVec::Echo(void){
Note:
See TracBrowser
for help on using the repository browser.