20 #include "headcpp.hpp"
22 #include "bispheric.hpp"
23 #include "term_eq.hpp"
26 #include "tensor_impl.hpp"
31 bool doder = (so.
der_t==0x0) ?
false :
true ;
35 assert ((type_der==COV) || (type_der==CON)) ;
44 type_ind.
set(0) = COV ;
45 for (
int i=1 ; i<val_res ; i++)
49 bool need_sum = false ;
51 for (
int i=1 ; i<val_res ; i++)
64 for (
int i=1 ; i<val_res ; i++)
69 Index pos_auxi(auxi_val) ;
72 for (
int i=0 ; i<val_res-1 ; i++)
73 pos_so.
set(i) = pos_auxi(i+1) ;
76 while (pos_auxi.
inc()) ;
97 for (
int i=1 ; i<val_res ; i++)
101 Index pos_auxi_der(auxi_der) ;
103 for (
int i=0 ; i<val_res-1 ; i++)
104 pos_so.
set(i) = pos_auxi_der(i+1) ;
107 while (pos_auxi_der.
inc()) ;
reference set(const Index &pos)
Read/write of an element.
Describes the tensorial basis used by the various tensors.
virtual Term_eq derive_flat_cart(int, char, const Term_eq &, const Metric *) const
Computes the flat derivative of a Term_eq, in Cartesian coordinates.
int num_dom
Number of the current domain (used by the Space)
Class that gives the position inside a multi-dimensional Array.
int & set(int i)
Read/write of the position in a given dimension.
bool inc(int increm, int var=0)
Increments the position of the Index.
Purely abstract class for metric handling.
MMPtr_array< Term_eq > p_met_con
Array of pointers on various Term_eq.
virtual void manipulate_ind(Term_eq &so, int ind) const
Uses the Metric to manipulate one of the index of a Term_eq (i.e.
Val_domain & set_domain(int)
Read/write of a particular Val_domain.
void set_name_ind(int dd, char name)
Sets the name of one index ; the names must have been affected first.
void set_name_affected()
Affects the name of the indices.
Scalar & set(const Array< int > &ind)
Returns the value of a component (read/write version).
char const * get_name_ind() const
int get_index_type(int i) const
Gives the type (covariant or contravariant) of a given index.
int get_valence() const
Returns the valence.
bool is_name_affected() const
Check whether the names of the indices have been affected.
Tensor do_summation_one_dom(int dd) const
Does the inner contraction of the Tensor in a given domain.
const Space & get_space() const
Returns the Space.
This class is intended to describe the manage objects appearing in the equations.
Tensor * der_t
Pointer on the variation, if the Term_eq is a Tensor.
Tensor * val_t
Pointer on the value, if the Term_eq is a Tensor.