20 #include "headcpp.hpp"
21 #include "adapted.hpp"
23 #include "array_math.hpp"
25 #include "tensor_impl.hpp"
32 int kmin = 2*mlim + 2 ;
38 if ((pos(2)==1) || (pos(2)==
nbr_coefs(2)-1))
44 if ((pos(1)==0) && (pos(2)>=kmin))
48 if ((pos(1)==
nbr_coefs(1)-1) || ((pos(1)==0) && (pos(2)>=kmin)))
52 if (((pos(1)==1)&&(pos(2)>=kmin+2)) || (pos(1)==0) || (pos(1)==
nbr_coefs(1)-1))
56 if (((pos(1)==0)&&(pos(2)>=kmin+2)) || (pos(1)==
nbr_coefs(1)-1))
60 cerr <<
"Unknow theta basis in Domain_shell_inner_adapted::nbr_conditions_val_domain" << endl ;
77 int size = (n_cmp==-1) ? tt.
get_n_comp() : n_cmp ;
96 else for (
int i=0 ; i<n_cmp ; i++) {
97 if ((*p_cmp[i])(0)==1)
99 if ((*p_cmp[i])(0)==2)
101 if ((*p_cmp[i])(0)==3)
113 else for (
int i=0 ; i<n_cmp ; i++) {
114 if ((*p_cmp[i])(0)==1)
116 if ((*p_cmp[i])(0)==2)
118 if ((*p_cmp[i])(0)==3)
124 cerr <<
"Unknown type of vector Domain_shell_inner_adapted::nbr_conditions" << endl ;
141 else for (
int i=0 ; i<n_cmp ; i++) {
142 if (((*p_cmp[i])(0)==1) && ((*p_cmp[i])(1)==1))
144 if (((*p_cmp[i])(0)==1) && ((*p_cmp[i])(1)==2))
146 if (((*p_cmp[i])(0)==1) && ((*p_cmp[i])(1)==3))
148 if (((*p_cmp[i])(0)==2) && ((*p_cmp[i])(1)==2))
150 if (((*p_cmp[i])(0)==2) && ((*p_cmp[i])(1)==3))
152 if (((*p_cmp[i])(0)==3) && ((*p_cmp[i])(1)==3))
170 else for (
int i=0 ; i<n_cmp ; i++) {
171 if (((*p_cmp[i])(0)==1) && ((*p_cmp[i])(1)==1))
173 if (((*p_cmp[i])(0)==1) && ((*p_cmp[i])(1)==2))
175 if (((*p_cmp[i])(0)==1) && ((*p_cmp[i])(1)==3))
177 if (((*p_cmp[i])(0)==2) && ((*p_cmp[i])(1)==1))
179 if (((*p_cmp[i])(0)==2) && ((*p_cmp[i])(1)==2))
181 if (((*p_cmp[i])(0)==2) && ((*p_cmp[i])(1)==3))
183 if (((*p_cmp[i])(0)==3) && ((*p_cmp[i])(1)==1))
185 if (((*p_cmp[i])(0)==3) && ((*p_cmp[i])(1)==2))
187 if (((*p_cmp[i])(0)==3) && ((*p_cmp[i])(1)==3))
202 else for (
int i=0 ; i<n_cmp ; i++) {
203 if (((*p_cmp[i])(0)==1) && ((*p_cmp[i])(1)==1))
205 if (((*p_cmp[i])(0)==1) && ((*p_cmp[i])(1)==2))
207 if (((*p_cmp[i])(0)==1) && ((*p_cmp[i])(1)==3))
209 if (((*p_cmp[i])(0)==2) && ((*p_cmp[i])(1)==2))
211 if (((*p_cmp[i])(0)==2) && ((*p_cmp[i])(1)==3))
213 if (((*p_cmp[i])(0)==3) && ((*p_cmp[i])(1)==3))
232 else for (
int i=0 ; i<n_cmp ; i++) {
233 if (((*p_cmp[i])(0)==1) && ((*p_cmp[i])(1)==1))
235 if (((*p_cmp[i])(0)==1) && ((*p_cmp[i])(1)==2))
237 if (((*p_cmp[i])(0)==1) && ((*p_cmp[i])(1)==3))
239 if (((*p_cmp[i])(0)==2) && ((*p_cmp[i])(1)==1))
241 if (((*p_cmp[i])(0)==2) && ((*p_cmp[i])(1)==2))
243 if (((*p_cmp[i])(0)==2) && ((*p_cmp[i])(1)==3))
245 if (((*p_cmp[i])(0)==3) && ((*p_cmp[i])(1)==1))
247 if (((*p_cmp[i])(0)==3) && ((*p_cmp[i])(1)==2))
249 if (((*p_cmp[i])(0)==3) && ((*p_cmp[i])(1)==3))
255 cerr <<
"Unknown type of 2-tensor Domain_shell_inner_adapted::nbr_conditions" << endl ;
261 cerr <<
"Valence " << val <<
" not implemented in Domain_shell_inner_adapted::nbr_conditions" << endl ;
reference set(const Index &pos)
Read/write of an element.
Bases_container bases_1d
Arrays containing the various basis of decomposition.
int get_basis(int nd) const
Read only the basis in a given domain.
int nbr_conditions_val_domain(const Val_domain &so, int mlim, int order) const
Computes number of discretized equations associated with a given tensorial equation in the bulk.
virtual Array< int > nbr_conditions(const Tensor &, int, int, int n_cmp=-1, Array< int > **p_cmp=0x0) const
Computes number of discretized equations associated with a given tensorial equation in the bulk.
Dim_array nbr_coefs
Number of coefficients.
Class that gives the position inside a multi-dimensional Array.
bool inc(int increm, int var=0)
Increments the position of the Index.
int get_m_order() const
Returns .
bool is_m_order_affected() const
Checks whether the additional parameter order is affected (not very used).
const Param_tensor & get_parameters() const
Returns a pointer on the possible additional parameter.
const Base_tensor & get_basis() const
Returns the vectorial basis (triad) on which the components are defined.
int get_n_comp() const
Returns the number of stored components.
int get_valence() const
Returns the valence.
Class for storing the basis of decompositions of a field and its values on both the configuration and...
const Base_spectral & get_base() const
Returns the basis of decomposition.