|
| | Space (const std::string &t_name, int t_dim, std::vector< std::string > const &indexNames={"i", "j", "k", "l"}) |
| | Initializes the name and the dimension of the space, no metric so only the kronecker delta is relevant, and indices are not signed. More...
|
| |
| | Space (const std::string &t_name, int t_dim, const std::string &name_metric, const Expr &t_metric, std::vector< std::string > const &indexNames={"i", "j", "k", "l"}) |
| | Initializes name, dimension of the space. Here the metrix is given by the user (also its explicit tensor, like diag (-1,1,1,1) for the Minkowski Space). This constructor constructs then a Space with signed indices and a non-trivial metric. More...
|
| |
|
virtual | ~Space () |
| | Destructor.
|
| |
|
virtual void | printCode (std::ostream &out, int indentSize) const |
| |
|
virtual void | printDefinition (std::ostream &out, int indentSize, bool header=false) const |
| |
| virtual std::string | getName () const |
| |
|
std::string | getNextIndexName () const |
| |
|
std::string | getIndexName (char spec) const |
| |
|
std::string_view | getIndexNameView (char spec) const |
| |
|
char | getSpecFromIndexName (std::string const &t_name) const |
| |
| int | getDim () const |
| |
| bool | getSignedIndex () const |
| |
|
virtual bool | hasSpecialTraceProperty (const csl::vector_expr &tensors) const |
| |
|
csl::vector_expr | getSignature () const |
| |
|
Tensor | getMetric () const |
| |
|
Tensor | getInverseMetric () const |
| |
|
Tensor | getDelta () const |
| |
|
Tensor | getEpsilon () const |
| |
|
Expr | applyMetricOnTensor (Expr const &tensor, size_t axis, bool covariant) const |
| |
| Index | generateIndex (const std::string &name) const |
| | Generates and returns an index in the right Space (itself) of name name. More...
|
| |
| Index | generateIndex () const |
| | Generates and returns an index in the right Space (itself) of name defined by the program. For now the index is name i_{number}, but in the future one should be able to defined a set of names for a given space, for example {"mu", "nu", "rhi", "sigma"}... More...
|
| |
|
std::vector< Index > | generateIndices (size_t N) const |
| |
|
std::vector< Index > | generateIndices (size_t N, const std::string &name) const |
| |
|
Index | generateSimilar (const Index &model) const |
| |
|
void | resetIndexNumber () const |
| |
|
void | refreshIndexName (Index &index) const |
| |
| Expr | generateVector (const std::string &t_name) const |
| | Generates and returns a Vector in the right Space (itself) of name name, filled with Variable objects as components (X_0, X_1, ...) for a name "X". More...
|
| |
|
std::string | generateVectorName (const std::string &t_name) const |
| |
|
void | addIndexNames (const std::string &name) const |
| |
|
void | addVectorNames (const std::string &name) const |
| |
|
void | addIndexNames (const std::vector< std::string > &names) const |
| |
|
void | addVectorNames (const std::vector< std::string > &names) const |
| |
|
virtual Expr | calculateTrace (csl::vector_expr tensors) const |
| |
|
|
std::string | name |
| | Name of the vector space.
|
| |
|
int | dim |
| | Dimension of the space.
|
| |
|
bool | signedIndex |
| | Property of indices: if true, it means that the metric is non trivial (given by the user at initialization) and that up- or down- position of indices matter in expressions.
|
| |
|
std::map< char, std::string > | nameIndices |
| |
|
std::map< std::string, char > | specIndices |
| |
|
std::vector< std::pair< std::string, Index::ID_type > > | availableIndices |
| |
|
std::vector< std::pair< std::string, unsigned short > > | availableVectors |
| |
|
std::vector< std::string >::const_iterator | defaultName |
| |
|
std::vector< std::string > | defaultIndexNames |
| |
| Tensor | delta |
| | Kronecker delta, public attribute for readability in usage. Element i,j of the tensor is then accessible by space.delta({i,j}) with i,j indices in this space. More...
|
| |
| Tensor | metric |
| | Public attribute for readability in usage. Element i,j of the tensor is then accessible by space.metric({i,j}) with i,j indices in this space. It corresponds to the metric of the space if it is non trivial, or is redirected to the kronecker delta else. More...
|
| |
|
Tensor | inverseMetric |
| |
|
Tensor | epsilon |
| |
Vector space that has a name, a dimension, a delta tensor and possibly a non-trivial metric. If a metric is given, the indices in this space are signed, i.e. their up- or down- position matter in expressions.
Kronecker delta, public attribute for readability in usage. Element i,j of the tensor is then accessible by space.delta({i,j}) with i,j indices in this space.
This attribute is mutable because access functions for parents (operator() to get TensorElement) is not const, and all many Space objects are declared const. So we declare this attribute mutable so that the compiler allows it to be changed, event for Space objets declared const.
Public attribute for readability in usage. Element i,j of the tensor is then accessible by space.metric({i,j}) with i,j indices in this space. It corresponds to the metric of the space if it is non trivial, or is redirected to the kronecker delta else.
This attribute is mutable because access functions for parents (operator() to get TensorElement) is not const, and all many Space objects are declared const. So we declare this attribute mutable so that the compiler allows it to be changed, event for Space objets declared const.