GiNaC  1.6.2
Public Member Functions | Protected Member Functions | Private Attributes
GiNaC::tensepsilon Class Reference

This class represents the totally antisymmetric epsilon tensor. More...

#include <tensor.h>

Inheritance diagram for GiNaC::tensepsilon:
GiNaC::tensor GiNaC::basic GiNaC::refcounted

List of all members.

Public Member Functions

 tensepsilon (bool minkowski, bool pos_sig)
bool info (unsigned inf) const
 Information about the object.
ex eval_indexed (const basic &i) const
 Automatic symbolic evaluation of an indexed epsilon tensor.
bool contract_with (exvector::iterator self, exvector::iterator other, exvector &v) const
 Contraction of epsilon tensor with something else.
void archive (archive_node &n) const
 Save (a.k.a.
void read_archive (const archive_node &n, lst &syms)
 Read (a.k.a.

Protected Member Functions

unsigned return_type () const
void do_print (const print_context &c, unsigned level) const
 Default output to stream.
void do_print_latex (const print_latex &c, unsigned level) const

Private Attributes

bool minkowski
 If true, tensor is in Minkowski-type space.
bool pos_sig
 If true, the metric is assumed to be diag(-1,1,1...).

Detailed Description

This class represents the totally antisymmetric epsilon tensor.

If indexed, all indices must be of the same type and their number must be equal to the dimension of the index space.

Definition at line 151 of file tensor.h.


Constructor & Destructor Documentation

GiNaC::tensepsilon::tensepsilon ( bool  minkowski,
bool  pos_sig 
)

Definition at line 87 of file tensor.cpp.


Member Function Documentation

bool GiNaC::tensepsilon::info ( unsigned  inf) const [virtual]

Information about the object.

See also:
class info_flags

Reimplemented from GiNaC::basic.

Definition at line 188 of file tensor.cpp.

References GiNaC::info_flags::real.

ex GiNaC::tensepsilon::eval_indexed ( const basic i) const [virtual]

Automatic symbolic evaluation of an indexed epsilon tensor.

Reimplemented from GiNaC::basic.

Definition at line 342 of file tensor.cpp.

References GiNaC::_ex0, GINAC_ASSERT, GiNaC::basic::hold(), GiNaC::is_zero(), minkowski, GiNaC::info_flags::nonnegint, GiNaC::basic::nops(), GiNaC::basic::op(), GiNaC::permutation_sign(), pos_sig, GiNaC::to_int(), and x.

bool GiNaC::tensepsilon::contract_with ( exvector::iterator  self,
exvector::iterator  other,
exvector v 
) const [virtual]

Contraction of epsilon tensor with something else.

Reimplemented from GiNaC::basic.

Definition at line 542 of file tensor.cpp.

References GiNaC::_ex1, GiNaC::delta_tensor(), GINAC_ASSERT, GiNaC::lorentz_g(), GiNaC::metric_tensor(), minkowski, and pos_sig.

void GiNaC::tensepsilon::archive ( archive_node n) const [virtual]

Save (a.k.a.

serialize) object into archive.

Reimplemented from GiNaC::basic.

Definition at line 120 of file tensor.cpp.

References GiNaC::archive_node::add_bool(), minkowski, and pos_sig.

void GiNaC::tensepsilon::read_archive ( const archive_node n,
lst syms 
) [virtual]

Read (a.k.a.

deserialize) object from archive.

Reimplemented from GiNaC::basic.

Definition at line 112 of file tensor.cpp.

References GiNaC::archive_node::find_bool(), minkowski, and pos_sig.

unsigned GiNaC::tensepsilon::return_type ( ) const [inline, protected, virtual]

Reimplemented from GiNaC::tensor.

Definition at line 171 of file tensor.h.

References GiNaC::return_types::commutative.

void GiNaC::tensepsilon::do_print ( const print_context c,
unsigned  level 
) const [protected]

Default output to stream.

Reimplemented from GiNaC::basic.

void GiNaC::tensepsilon::do_print_latex ( const print_latex c,
unsigned  level 
) const [protected]

Member Data Documentation

If true, tensor is in Minkowski-type space.

Otherwise it is in a Euclidean space.

Definition at line 177 of file tensor.h.

Referenced by archive(), contract_with(), eval_indexed(), and read_archive().

If true, the metric is assumed to be diag(-1,1,1...).

Otherwise it is diag(1,-1,-1,...). This is only relevant if minkowski = true.

Definition at line 178 of file tensor.h.

Referenced by archive(), contract_with(), eval_indexed(), and read_archive().


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

This page is part of the GiNaC developer's reference. It was generated automatically by doxygen. For an introduction, see the tutorial.