Main Page   Modules   Namespace List   Class Hierarchy   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

Dif Class Template Reference
[linbox/blackbox]

#include <dif.h>

Inheritance diagram for Dif:

BlackboxInterface List of all members.

Detailed Description

template<class Blackbox1, class Blackbox2>
class LinBox::Dif< Blackbox1, Blackbox2 >

Blackbox of a difference: C := A - B, i.e. Cx = Ax - Bx.

{\bf Template parameters:} Field is the class of the entry domain, Vector is a LinBox dense or sparse vector of field elements class.


Public Types

typedef Blackbox1::Field Field
typedef Blackbox1::Element Element

Public Methods

 Dif (const Blackbox1 &A, const Blackbox2 &B)
 Dif (const Blackbox1 *A_ptr, const Blackbox2 *B_ptr)
 Dif (const Dif< Blackbox1, Blackbox2 > &M)
 ~Dif (void)
 Destructor.

template<class OutVector, class InVector> OutVector & apply (OutVector &y, const InVector &x) const
template<class OutVector, class InVector> OutVector & applyTranspose (OutVector &y, const InVector &x) const
size_t rowdim (void) const
size_t coldim (void) const
const Fieldfield () const


Member Typedef Documentation

typedef Blackbox1::Element Element
 

typedef Blackbox1::Field Field
 


Constructor & Destructor Documentation

Dif const Blackbox1 &    A,
const Blackbox2 &    B
[inline]
 

Build this as A - B from blackboxes A, B. A and B must have the same shape and be over the same field. Their data is not copied. A subsequent change to one of them also changes this difference.

Dif const Blackbox1 *    A_ptr,
const Blackbox2 *    B_ptr
[inline]
 

Build this as A - B from blackbox pointers A_ptr, B_ptr. The two matrices must have the same shape and be over the same field. Their data {\it is} copied. I don't know why.

Dif const Dif< Blackbox1, Blackbox2 > &    M [inline]
 

Makes a deep copy. Creates new black box objects in dynamic memory.

Parameters:
M  constant reference to compose black box matrix

~Dif void    [inline]
 

Destructor.


Member Function Documentation

OutVector& apply OutVector &    y,
const InVector &    x
const [inline]
 

Application of BlackBox matrix. y= (A+B)*x. Requires one vector conforming to the \Ref{LinBox} vector archetype. Required by abstract base class.

Returns:
reference to vector y containing output.
Parameters:
x  constant reference to vector to contain input

OutVector& applyTranspose OutVector &    y,
const InVector &    x
const [inline]
 

Application of BlackBox matrix transpose. y= transpose(A+B)*x. Requires one vector conforming to the \Ref{LinBox} vector archetype. Required by abstract base class.

Returns:
reference to vector y containing output.
Parameters:
x  constant reference to vector to contain input

size_t coldim void    const [inline]
 

Retreive column dimensions of BlackBox matrix. Required by abstract base class.

Returns:
integer number of columns of black box matrix.

const Field& field   const [inline]
 

size_t rowdim void    const [inline]
 

Retreive row dimensions of BlackBox matrix. This may be needed for applying preconditioners. Required by abstract base class.

Returns:
integer number of rows of black box matrix.


Generated on Mon Jun 20 09:16:53 2005 for linbox by doxygen1.2.18