Changeset 17509
- Timestamp:
- 03/20/14 16:48:44 (11 years ago)
- Location:
- issm/trunk-jpl/src/c/toolkits
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
TabularUnified issm/trunk-jpl/src/c/toolkits/objects/Vector.h ¶
r16675 r17509 305 305 } 306 306 /*}}}*/ 307 /*FUNCTION Max{{{*/ 308 doubletype Max(void){_assert_(this); 309 310 doubletype max=0; 311 312 if(type==PetscVecType){ 313 #ifdef _HAVE_PETSC_ 314 max=this->pvector->Max(); 315 #endif 316 } 317 else _error_("operation not supported yet"); 318 return max; 319 } 320 /*}}}*/ 307 321 /*FUNCTION Norm{{{*/ 308 322 doubletype Norm(NormMode norm_type){_assert_(this); -
TabularUnified issm/trunk-jpl/src/c/toolkits/petsc/objects/PetscVec.cpp ¶
r13880 r17509 188 188 } 189 189 /*}}}*/ 190 /*FUNCTION PetscVec::Max{{{*/ 191 IssmDouble PetscVec::Max(void){ 192 193 _assert_(this->vector); 194 195 IssmDouble max; 196 VecMax(this->vector,NULL,&max); 197 return max; 198 199 } 200 /*}}}*/ 190 201 /*FUNCTION PetscVec::Norm{{{*/ 191 202 IssmDouble PetscVec::Norm(NormMode mode){ -
TabularUnified issm/trunk-jpl/src/c/toolkits/petsc/objects/PetscVec.h ¶
r14917 r17509 38 38 39 39 /*PetscVec specific routines*/ 40 void Echo(void);41 void Assemble(void);42 void SetValues(int ssize, int* list, IssmDouble* values, InsMode mode);43 void SetValue(int dof, IssmDouble value, InsMode mode);44 void GetValue(IssmDouble* pvalue, int dof);45 void GetSize(int* pM);46 void GetLocalSize(int* pM);47 PetscVec* Duplicate(void);48 void Set(IssmDouble value);49 void AXPY(PetscVec* X, IssmDouble a);50 void AYPX(PetscVec* X, IssmDouble a);40 void Echo(void); 41 void Assemble(void); 42 void SetValues(int ssize, int* list, IssmDouble* values, InsMode mode); 43 void SetValue(int dof, IssmDouble value, InsMode mode); 44 void GetValue(IssmDouble* pvalue, int dof); 45 void GetSize(int* pM); 46 void GetLocalSize(int* pM); 47 PetscVec* Duplicate(void); 48 void Set(IssmDouble value); 49 void AXPY(PetscVec* X, IssmDouble a); 50 void AYPX(PetscVec* X, IssmDouble a); 51 51 IssmDouble* ToMPISerial(void); 52 void Copy(PetscVec* to); 53 IssmDouble Norm(NormMode norm_type); 54 void Scale(IssmDouble scale_factor); 55 void PointwiseDivide(PetscVec* x,PetscVec* y); 56 IssmDouble Dot(PetscVec* vector); 52 void Copy(PetscVec* to); 53 IssmDouble Norm(NormMode norm_type); 54 IssmDouble Max(void); 55 void Scale(IssmDouble scale_factor); 56 void PointwiseDivide(PetscVec* x,PetscVec* y); 57 IssmDouble Dot(PetscVec* vector); 57 58 }; 58 59
Note:
See TracChangeset
for help on using the changeset viewer.