44 #ifndef EPETRA_MULTIVECTOR_H
45 #define EPETRA_MULTIVECTOR_H
235 double *
A,
int MyLDA,
int NumVectors);
254 double **ArrayOfPointers,
int NumVectors);
320 #ifndef EPETRA_NO_32BIT_GLOBAL_INDICES
321 int ReplaceGlobalValue(
int GlobalRow,
int VectorIndex,
double ScalarValue);
323 #ifndef EPETRA_NO_64BIT_GLOBAL_INDICES
324 int ReplaceGlobalValue(
long long GlobalRow,
int VectorIndex,
double ScalarValue);
347 #ifndef EPETRA_NO_32BIT_GLOBAL_INDICES
348 int ReplaceGlobalValue(
int GlobalBlockRow,
int BlockRowOffset,
int VectorIndex,
double ScalarValue);
350 #ifndef EPETRA_NO_64BIT_GLOBAL_INDICES
351 int ReplaceGlobalValue(
long long GlobalBlockRow,
int BlockRowOffset,
int VectorIndex,
double ScalarValue);
375 #ifndef EPETRA_NO_32BIT_GLOBAL_INDICES
376 int SumIntoGlobalValue(
int GlobalRow,
int VectorIndex,
double ScalarValue);
378 #ifndef EPETRA_NO_64BIT_GLOBAL_INDICES
379 int SumIntoGlobalValue(
long long GlobalRow,
int VectorIndex,
double ScalarValue);
402 #ifndef EPETRA_NO_32BIT_GLOBAL_INDICES
403 int SumIntoGlobalValue(
int GlobalBlockRow,
int BlockRowOffset,
int VectorIndex,
double ScalarValue);
405 #ifndef EPETRA_NO_64BIT_GLOBAL_INDICES
406 int SumIntoGlobalValue(
long long GlobalBlockRow,
int BlockRowOffset,
int VectorIndex,
double ScalarValue);
434 int ReplaceMyValue(
int MyRow,
int VectorIndex,
double ScalarValue);
456 int ReplaceMyValue(
int MyBlockRow,
int BlockRowOffset,
int VectorIndex,
double ScalarValue);
479 int SumIntoMyValue(
int MyRow,
int VectorIndex,
double ScalarValue);
501 int SumIntoMyValue(
int MyBlockRow,
int BlockRowOffset,
int VectorIndex,
double ScalarValue);
510 int PutScalar (
double ScalarConstant);
541 int ExtractCopy(
double *A,
int MyLDA)
const;
554 int ExtractCopy(
double **ArrayOfPointers)
const;
574 int ExtractView(
double **A,
int *MyLDA)
const;
587 int ExtractView(
double ***ArrayOfPointers)
const;
645 int Scale(
double ScalarValue);
703 int Norm1 (
double * Result)
const;
713 int Norm2 (
double * Result)
const;
722 int NormInf (
double * Result)
const;
752 int MinValue (
double * Result)
const;
764 int MaxValue (
double * Result)
const;
774 int MeanValue (
double * Result)
const;
830 int Multiply(
char TransA,
char TransB,
double ScalarAB,
870 int SetSeed(
unsigned int Seed_in){
return(Util_.SetSeed(Seed_in));};
876 unsigned int Seed(){
return(Util_.Seed());};
900 double*& operator [] (
int i) {
return Pointers_[i]; }
906 double *
const & operator [] (
int i)
const {
return Pointers_[i]; }
931 int GlobalLength()
const {
int ret_val = GlobalLength_;
return ret_val; }
952 virtual void Print(std::ostream & os)
const;
978 int ResetView(
double ** ArrayOfPointers);
981 double*
Values()
const {
return Values_;};
1006 int AllocateForCopy(
void);
1010 {
if (DoubleTemp_==0) DoubleTemp_=
new double[NumVectors_+1];
return;}
1013 for (
int i=0; i<NumVectors_; i++) Vectors_[i] = 0;}
1017 int AllocateForView(
void);
1019 template<
typename int_type>
1020 int ChangeGlobalValue(int_type GlobalBlockRow,
1025 int ChangeMyValue(
int MyBlockRow,
1036 int * PermuteToLIDs,
1037 int * PermuteFromLIDs,
1078 #if defined(Epetra_SHOW_DEPRECATED_WARNINGS)
1080 #warning "The Epetra package is deprecated"
Epetra_MultiVector: A class for constructing and using dense multi-vectors, vectors and matrices in p...
int GlobalLength() const
Returns the global vector length of vectors in the multi-vector.
Epetra_Map: A class for partitioning vectors and matrices.
Epetra_Distributor: The Epetra Gather/Scatter Setup Base Class.
virtual int CopyAndPermute(const Epetra_SrcDistObject &Source, int NumSameIDs, int NumPermuteIDs, int *PermuteToLIDs, int *PermuteFromLIDs, const Epetra_OffsetIndex *Indexor, Epetra_CombineMode CombineMode=Zero)=0
Perform ID copies and permutations that are on processor.
Epetra_OffsetIndex: This class builds index for efficient mapping of data from one Epetra_CrsGraph ba...
virtual void Print(std::ostream &os) const
Print method.
int MyLength() const
Returns the local vector length on the calling processor of vectors in the multi-vector.
double ** Pointers() const
Get pointer to individual vector pointers.
Epetra_Export: This class builds an export object for efficient exporting of off-processor elements...
Epetra_Vector: A class for constructing and using dense vectors on a parallel computer.
Epetra_CompObject & operator=(const Epetra_CompObject &src)
int SetSeed(unsigned int Seed_in)
Set seed for Random function.
Epetra_Import: This class builds an import object for efficient importing of off-processor elements...
int NumVectors() const
Returns the number of vectors in the multi-vector.
virtual int CheckSizes(const Epetra_SrcDistObject &Source)=0
Allows the source and target (this) objects to be compared for compatibility, return nonzero if not...
void UpdateDoubleTemp() const
Epetra_Vector ** Vectors_
Epetra_Util: The Epetra Util Wrapper Class.
Epetra_BLAS: The Epetra BLAS Wrapper Class.
Epetra_Comm: The Epetra Communication Abstract Base Class.
long long GlobalLength64() const
Returns the 64-bit global vector length of vectors in the multi-vector.
void UpdateVectors() const
Epetra_CompObject: Functionality and data that is common to all computational classes.
virtual int UnpackAndCombine(const Epetra_SrcDistObject &Source, int NumImportIDs, int *ImportLIDs, int LenImports, char *Imports, int &SizeOfPacket, Epetra_Distributor &Distor, Epetra_CombineMode CombineMode, const Epetra_OffsetIndex *Indexor)=0
Perform any unpacking and combining after call to DoTransfer().
Epetra_BlockMap: A class for partitioning block element vectors and matrices.
int Stride() const
Returns the stride between vectors in the multi-vector (only meaningful if ConstantStride() is true)...
bool ConstantStride() const
Returns true if this multi-vector has constant stride between vectors.
double * Values() const
Get pointer to MultiVector values.
unsigned int Seed()
Get seed from Random function.
Epetra_SrcDistObject: A class for supporting flexible source distributed objects for import/export op...
Epetra_DistObject: A class for constructing and using dense multi-vectors, vectors and matrices in pa...
virtual int PackAndPrepare(const Epetra_SrcDistObject &Source, int NumExportIDs, int *ExportLIDs, int &LenExports, char *&Exports, int &SizeOfPacket, int *Sizes, bool &VarSizes, Epetra_Distributor &Distor)=0
Perform any packing or preparation required for call to DoTransfer().