The ChainCon Software (Release 0.03)
Classes | Functions
linmap.h File Reference

A linear map for coefficients in an arbitrary commutative ring. More...

#include <istream>
#include <ostream>
#include "chomp/system/config.h"
#include "chomp/struct/hashsets.h"
#include "chomp/struct/multitab.h"
#include "chaincon/chain.h"
#include "chaincon/tensor.h"

Go to the source code of this file.

Classes

class  tLinMap< CellDomT, CellImgT, CoefT >
 A linear map. More...
 

Functions

template<class CellDomT , class CellImgT , class CoefT >
std::ostream & operator<< (std::ostream &out, const tLinMap< CellDomT, CellImgT, CoefT > &f)
 Writes a linear map to an output stream in the text mode. More...
 
template<class CellDomT , class CellImgT , class CoefT >
std::istream & operator>> (std::istream &in, tLinMap< CellDomT, CellImgT, CoefT > &f)
 Reads a linear map from an input stream. More...
 
template<class CellArray , class CellT , class CoefT >
void addIdentity (const CellArray &domain, tLinMap< CellT, CellT, CoefT > &f)
 Adds the identity map on the given domain to the map 'f'. More...
 
template<class CellArray , class CellT , class CoefT >
tLinMap< CellT, CellT, CoefT > identity (const CellArray &domain)
 Returns the identity map on the given domain. More...
 
template<class CellXT , class CellYT , class CellZT , class CoefT >
tLinMap< CellXT, CellZT, CoefT > operator* (const tLinMap< CellYT, CellZT, CoefT > &f, const tLinMap< CellXT, CellYT, CoefT > &g)
 Computes the composition of the two given maps. More...
 

Detailed Description

A linear map for coefficients in an arbitrary commutative ring.

Definition in file linmap.h.

Function Documentation

◆ addIdentity()

template<class CellArray , class CellT , class CoefT >
void addIdentity ( const CellArray &  domain,
tLinMap< CellT, CellT, CoefT > &  f 
)
inline

Adds the identity map on the given domain to the map 'f'.

Definition at line 460 of file linmap.h.

References tLinMap< CellDomT, CellImgT, CoefT >::add(), and tLinMap< CellDomT, CellImgT, CoefT >::size().

Referenced by identity().

◆ identity()

template<class CellArray , class CellT , class CoefT >
tLinMap<CellT,CellT,CoefT> identity ( const CellArray &  domain)
inline

Returns the identity map on the given domain.

Definition at line 474 of file linmap.h.

References addIdentity().

◆ operator*()

template<class CellXT , class CellYT , class CellZT , class CoefT >
tLinMap<CellXT,CellZT,CoefT> operator* ( const tLinMap< CellYT, CellZT, CoefT > &  f,
const tLinMap< CellXT, CellYT, CoefT > &  g 
)
inline

Computes the composition of the two given maps.

More precisely, for each x in the domain of g, the new map on x is defined as f(g(x)).

Definition at line 486 of file linmap.h.

References tLinMap< CellDomT, CellImgT, CoefT >::add(), and tLinMap< CellDomT, CellImgT, CoefT >::size().

◆ operator<<()

template<class CellDomT , class CellImgT , class CoefT >
std::ostream& operator<< ( std::ostream &  out,
const tLinMap< CellDomT, CellImgT, CoefT > &  f 
)
inline

Writes a linear map to an output stream in the text mode.

Definition at line 428 of file linmap.h.

References tLinMap< CellDomT, CellImgT, CoefT >::size().

◆ operator>>()

template<class CellDomT , class CellImgT , class CoefT >
std::istream& operator>> ( std::istream &  in,
tLinMap< CellDomT, CellImgT, CoefT > &  f 
)
inline

Reads a linear map from an input stream.

Definition at line 449 of file linmap.h.