So-Bogus
A c++ sparse block matrix library aimed at Second Order cone problems
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Pages
bogus::CompoundBlockMatrix< ColWise, MatrixT1, MatrixT2 > Class Template Reference

A matrix made by concatenating two other matrices of possibly different types. More...

#include <CompoundMatrix.hpp>

Inheritance diagram for bogus::CompoundBlockMatrix< ColWise, MatrixT1, MatrixT2 >:
bogus::IterableBlockObject< CompoundBlockMatrix< ColWise, MatrixT1, MatrixT2 > > bogus::BlockObjectBase< Derived >

Public Types

typedef IterableBlockObject
< CompoundBlockMatrix< ColWise,
MatrixT1, MatrixT2 > > 
Base
 
typedef Base::Index Index
 
typedef Base::Scalar Scalar
 
typedef
Base::ConstTransposeReturnType 
ConstTransposeReturnType
 
typedef BlockMatrixTraits
< CompoundBlockMatrix< ColWise,
MatrixT1, MatrixT2 > > 
Traits
 
enum  { is_transposed = Traits::is_transposed }
 
enum  { RowsAtCompileTime = internal::DYNAMIC, ColsAtCompileTime = internal::DYNAMIC, is_self_transpose = Traits::is_symmetric }
 
typedef Traits::TransposeObjectType TransposeObjectType
 
typedef Traits::PlainObjectType PlainObjectType
 

Public Member Functions

 CompoundBlockMatrix (const IterableBlockObject< MatrixT1 > &first, const IterableBlockObject< MatrixT2 > &second)
 
Index rows () const
 
Index cols () const
 
Index blockRows (Index row) const
 
Index blockCols (Index col) const
 
Index rowsOfBlocks () const
 
Index colsOfBlocks () const
 
const Index * rowOffsets () const
 
const Index * colOffsets () const
 
ConstTransposeReturnType transpose () const
 
template<bool DoTranspose, typename RhsT , typename ResT >
void multiply (const RhsT &rhs, ResT &res, Scalar alpha=1, Scalar beta=0) const
 
Index size () const
 
template<typename Func >
void eachBlockOfRow (const Index row, Func func) const
 
template<typename Func >
void eachBlockOfCol (const Index col, Func func) const
 
template<bool DoTranspose, typename RhsT , typename ResT , typename PreOp >
void rowMultiplyPrecompose (const Index row, const RhsT &rhs, ResT &res, const PreOp &op) const
 
template<bool DoTranspose, typename RhsT , typename ResT , typename PostOp >
void colMultiplyPostcompose (const Index col, const RhsT &rhs, ResT &res, const PostOp &op) const
 
const IterableBlockObject
< MatrixT1 > & 
first () const
 
const IterableBlockObject
< MatrixT2 > & 
second () const
 
const Index * compoundOffsets () const
 
Index secondBegin () const
 
void rowMultiply (const Index row, const RhsT &rhs, ResT &res) const
 Multiplication with a single row.
 
void colMultiply (const Index col, const RhsT &rhs, ResT &res) const
 Multiplication with a single column.
 
const Derived & derived () const
 Returns a const reference to the implementation.
 
Derived & derived ()
 Returns a reference to the implementation.
 
Index rowOffset (Index row) const
 Returns an array containing the first index of a given row.
 
Index colOffset (Index col) const
 Returns an array containing the first index of a given columns.
 

Detailed Description

template<bool ColWise, typename MatrixT1, typename MatrixT2>
class bogus::CompoundBlockMatrix< ColWise, MatrixT1, MatrixT2 >

A matrix made by concatenating two other matrices of possibly different types.

Template Parameters
ColWiseIf true, the two matrices are side-by-side (column concatenation), otherwise they are on top of another

If ColWise, the two matrices must have the same number and size of rows of blocks. Otherwise, they must have the same number and size of columns of blocks.

Implements IterableBlockObject


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