PyTrilinos  Development
 All Classes Functions
Public Member Functions | Public Attributes | Static Public Attributes
PyTrilinos.NOX.Epetra.Vector Class Reference
Inheritance diagram for PyTrilinos.NOX.Epetra.Vector:
Inheritance graph
[legend]
Collaboration diagram for PyTrilinos.NOX.Epetra.Vector:
Collaboration graph
[legend]

List of all members.

Public Member Functions

def __init__
def getEpetraVector
def init
def random
def abs
def reciprocal
def scale
def update
def clone
def createMultiVector
def norm
def innerProduct
def length
def getVectorSpace

Public Attributes

 this

Static Public Attributes

 CreateView = ___init__.Vector_CreateView
 CreateCopy = ___init__.Vector_CreateCopy

Detailed Description

Implementation of NOX::Abstract::Vector for Epetra vectors.

C++ includes: NOX_Epetra_Vector.H 

Constructor & Destructor Documentation

def PyTrilinos.NOX.Epetra.Vector.__init__ (   self,
  args 
)
__init__(NOX::Epetra::Vector self, Teuchos::RCP< Epetra_Vector > const & source, NOX::Epetra::Vector::MemoryType memoryType=CreateCopy, 
    NOX::CopyType type=DeepCopy, Teuchos::RCP< NOX::Epetra::VectorSpace > vs=Teuchos::null) -> Vector
__init__(NOX::Epetra::Vector self, Epetra_Vector source, NOX::CopyType type=DeepCopy, Teuchos::RCP< NOX::Epetra::VectorSpace > vs=Teuchos::null) -> Vector
__init__(NOX::Epetra::Vector self, Vector source, NOX::CopyType type=DeepCopy) -> Vector

NOX::Epetra::Vector::Vector(const NOX::Epetra::Vector &source,
NOX::CopyType type=NOX::DeepCopy)

Copy constructor. 

Member Function Documentation

def PyTrilinos.NOX.Epetra.Vector.abs (   self,
  args 
)
abs(Vector self, Vector y) -> Vector
abs(Vector self, Vector y) -> Vector

NOX::Abstract::Vector & NOX::Epetra::Vector::abs(const
NOX::Abstract::Vector &y)

Put element-wise absolute values of source vector y into this vector.

Here x represents this vector, and we update it as \\[ x_i = | y_i |
\\quad \\mbox{for } i=1,\\dots,n \\]

Reference to this object 

Reimplemented from PyTrilinos.NOX.Abstract.Vector.

def PyTrilinos.NOX.Epetra.Vector.clone (   self,
  args 
)
clone(Vector self, NOX::CopyType type=DeepCopy) -> Teuchos::RCP< NOX::Abstract::Vector >

Teuchos::RCP<
NOX::Abstract::Vector > NOX::Epetra::Vector::clone(CopyType
type=DeepCopy) const

Create a new Vector of the same underlying type by cloning "this",
and return a pointer to the new vector.

If type is NOX::DeepCopy, then we need to create an exact replica of
"this". Otherwise, if type is NOX::ShapeCopy, we need only replicate
the shape of "this" (the memory is allocated for the objects, but
the current values are not copied into the vector). Note that there is
no assumption that a vector created by ShapeCopy is initialized to
zeros.

Pointer to newly created vector or NULL if clone is not supported. 

Reimplemented from PyTrilinos.NOX.Abstract.Vector.

createMultiVector(Vector self, NOX::Abstract::Vector const *const * vecs, int numVecs, NOX::CopyType type=DeepCopy) -> Teuchos::RCP< NOX::Abstract::MultiVector >
createMultiVector(Vector self, int numVecs, NOX::CopyType type=DeepCopy) -> Teuchos::RCP< NOX::Abstract::MultiVector >

Teuchos::RCP< NOX::Abstract::MultiVector >
NOX::Epetra::Vector::createMultiVector(int numVecs, NOX::CopyType
type=NOX::DeepCopy) const

Create a MultiVector with numVecs columns.

The implementation here creates a NOX::Epetra::MultiVector with either
Shape or Deep copies of the supplied vector. 

Reimplemented from PyTrilinos.NOX.Abstract.Vector.

getEpetraVector(Vector self) -> Epetra_Vector

const
Epetra_Vector & NOX::Epetra::Vector::getEpetraVector() const

Get const reference to underlying Epetra vector. 
def PyTrilinos.NOX.Epetra.Vector.getVectorSpace (   self,
  args 
)
getVectorSpace(Vector self) -> Teuchos::RCP< NOX::Epetra::VectorSpace >

Teuchos::RCP< NOX::Epetra::VectorSpace >
NOX::Epetra::Vector::getVectorSpace() const

Returns the NOX::Epetra::VectorSpace associated with this vector. 
def PyTrilinos.NOX.Epetra.Vector.init (   self,
  args 
)
init(Vector self, double gamma) -> Vector

NOX::Abstract::Vector & NOX::Epetra::Vector::init(double gamma)

Initialize every element of this vector with gamma.

Here x represents this vector, and we update it as \\[ x_i =
\\gamma \\quad \\mbox{for } i=1,\\dots,n \\] Reference to
this object 

Reimplemented from PyTrilinos.NOX.Abstract.Vector.

def PyTrilinos.NOX.Epetra.Vector.innerProduct (   self,
  args 
)
innerProduct(Vector self, Vector y) -> double
innerProduct(Vector self, Vector y) -> double

double
NOX::Epetra::Vector::innerProduct(const NOX::Abstract::Vector &y)
const

Inner product with y.

Here x represents this vector, and we compute its inner product with y
as follows: \\[ \\langle x,y \\rangle = \\sum_{i=1}^n x_i y_i
\\]  $\\langle x,y \\rangle$ 

Reimplemented from PyTrilinos.NOX.Abstract.Vector.

def PyTrilinos.NOX.Epetra.Vector.length (   self,
  args 
)
length(Vector self) -> int

int
NOX::Epetra::Vector::length() const

Return the length of vector.

The length of this vector

Even if the vector is distributed across processors, this should
return the  global length of the vector. 

Reimplemented from PyTrilinos.NOX.Abstract.Vector.

def PyTrilinos.NOX.Epetra.Vector.norm (   self,
  args 
)
norm(Vector self, NOX::Abstract::Vector::NormType type=TwoNorm) -> double
norm(Vector self, Vector weights) -> double
norm(Vector self, Vector weights) -> double

double
NOX::Epetra::Vector::norm(const NOX::Abstract::Vector &weights) const

Weighted 2-Norm.

Here x represents this vector, and we compute its weighted norm as
follows: \\[ \\|x\\|_w = \\sqrt{\\sum_{i=1}^{n} w_i \\;
x_i^2} \\]  $ \\|x\\|_w $ 

Reimplemented from PyTrilinos.NOX.Abstract.Vector.

def PyTrilinos.NOX.Epetra.Vector.random (   self,
  args 
)
random(Vector self, bool useSeed=False, int seed=1) -> Vector

NOX::Abstract::Vector & NOX::Epetra::Vector::random(bool
useSeed=false, int seed=1)

Initialize each element of this vector with a random value.

If useSeed is true, uses the value of seed to seed the random number
generator before filling the entries of this vector. So, if two calls
are made where useSeed is true and seed is the same, then the vectors
returned should be the same.

Default implementation throw an error. Only referenced by LOCA
methods.

Reference to this object 

Reimplemented from PyTrilinos.NOX.Abstract.Vector.

def PyTrilinos.NOX.Epetra.Vector.reciprocal (   self,
  args 
)
reciprocal(Vector self, Vector y) -> Vector
reciprocal(Vector self, Vector y) -> Vector

NOX::Abstract::Vector & NOX::Epetra::Vector::reciprocal(const
NOX::Abstract::Vector &y)

Put element-wise reciprocal of source vector y into this vector.

Here x represents this vector, and we update it as \\[ x_i =
\\frac{1}{y_i} \\quad \\mbox{for } i=1,\\dots,n \\]

Reference to this object 

Reimplemented from PyTrilinos.NOX.Abstract.Vector.

def PyTrilinos.NOX.Epetra.Vector.scale (   self,
  args 
)
scale(Vector self, double gamma) -> Vector
scale(Vector self, Vector a) -> Vector
scale(Vector self, Vector a) -> Vector

NOX::Abstract::Vector & NOX::Epetra::Vector::scale(const
NOX::Abstract::Vector &a)

Scale this vector element-by-element by the vector a.

Here x represents this vector, and we update it as \\[ x_i = x_i
\\cdot a_i \\quad \\mbox{for } i=1,\\dots,n \\]

Reference to this object 

Reimplemented from PyTrilinos.NOX.Abstract.Vector.

def PyTrilinos.NOX.Epetra.Vector.update (   self,
  args 
)
update(Vector self, double alpha, Vector a, double gamma=0.0) -> Vector
update(Vector self, double alpha, Vector a, double gamma=0.0) -> Vector
update(Vector self, double alpha, Vector a, double beta, Vector b, double gamma=0.0) -> Vector
update(Vector self, double alpha, Vector a, double beta, Vector b, double gamma=0.0) -> Vector

NOX::Abstract::Vector & NOX::Epetra::Vector::update(double alpha,
const NOX::Abstract::Vector &a, double beta, const
NOX::Abstract::Vector &b, double gamma=0.0)

Compute x = (alpha * a) + (beta * b) + (gamma * x) where x is this
vector.

Here x represents this vector, and we update it as \\[ x_i =
\\alpha \\; a_i + \\beta \\; b_i + \\gamma \\; x_i
\\quad \\mbox{for } i=1,\\dots,n \\]

Reference to this object 

Reimplemented from PyTrilinos.NOX.Abstract.Vector.


The documentation for this class was generated from the following file:
 All Classes Functions