DGtal  1.4.beta
DGtal::concepts::CVectorSpace< T > Struct Template Reference

Aim: Base concept for vector space structure. More...

#include <DGtal/math/linalg/CVectorSpace.h>

Inheritance diagram for DGtal::concepts::CVectorSpace< T >:
[legend]

Public Types

typedef T::Scalar Scalar
 

Public Member Functions

 BOOST_CONCEPT_ASSERT ((concepts::CEuclideanRing< Scalar >))
 
 BOOST_CONCEPT_USAGE (CVectorSpace)
 

Private Attributes

const T x
 
const T y
 
z
 
Scalar a
 

Detailed Description

template<typename T>
struct DGtal::concepts::CVectorSpace< T >

Aim: Base concept for vector space structure.

Description of concept 'CVectorSpace'

Refinement of

Associated types

  • Scalar: Scalar type used for external multiplication and internal type representation.
  • Index: Random access index type.

Notation

  • VectorSpace : A type that is a model of concepts::CVectorSpace
  • x, y : const object of type VectorSpace
  • z : object of type VectorSpace
  • a : object of type VectorSpace::Scalar

Definitions

Valid expressions and semantics

Name Expression Type requirements Return type Precondition Semantics Post condition Complexity
Addition z = x + y VectorSpace
Substraction z = x - y VectorSpace
External multiplication z = a * x VectorSpace

Invariants

Models

Notes

Template Parameters
Tthe type that should be a model of CVectorSpace.

Definition at line 92 of file CVectorSpace.h.

Member Typedef Documentation

◆ Scalar

template<typename T >
typedef T::Scalar DGtal::concepts::CVectorSpace< T >::Scalar

Definition at line 96 of file CVectorSpace.h.

Member Function Documentation

◆ BOOST_CONCEPT_ASSERT()

template<typename T >
DGtal::concepts::CVectorSpace< T >::BOOST_CONCEPT_ASSERT ( (concepts::CEuclideanRing< Scalar >)  )

◆ BOOST_CONCEPT_USAGE()

template<typename T >
DGtal::concepts::CVectorSpace< T >::BOOST_CONCEPT_USAGE ( CVectorSpace< T >  )
inline

Definition at line 100 of file CVectorSpace.h.

101  {
102  z = x + y;
103  z = x - y;
104  z = a * x;
105  }

References DGtal::concepts::CVectorSpace< T >::x, and DGtal::concepts::CVectorSpace< T >::y.

Field Documentation

◆ a

template<typename T >
Scalar DGtal::concepts::CVectorSpace< T >::a
private

Definition at line 110 of file CVectorSpace.h.

◆ x

template<typename T >
const T DGtal::concepts::CVectorSpace< T >::x
private

◆ y

template<typename T >
const T DGtal::concepts::CVectorSpace< T >::y
private

◆ z

template<typename T >
T DGtal::concepts::CVectorSpace< T >::z
private

Definition at line 109 of file CVectorSpace.h.


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