KADATH
domain_nucleus_export_tau_boundary.cpp
1 /*
2  Copyright 2017 Philippe Grandclement
3 
4  This file is part of Kadath.
5 
6  Kadath is free software: you can redistribute it and/or modify
7  it under the terms of the GNU General Public License as published by
8  the Free Software Foundation, either version 3 of the License, or
9  (at your option) any later version.
10 
11  Kadath is distributed in the hope that it will be useful,
12  but WITHOUT ANY WARRANTY; without even the implied warranty of
13  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14  GNU General Public License for more details.
15 
16  You should have received a copy of the GNU General Public License
17  along with Kadath. If not, see <http://www.gnu.org/licenses/>.
18 */
19 
20 #include "headcpp.hpp"
21 
22 #include "spheric.hpp"
23 #include "scalar.hpp"
24 #include "tensor_impl.hpp"
25 #include "tensor.hpp"
26 
27 namespace Kadath {
28 void Domain_nucleus::export_tau_val_domain_boundary_vr (const Val_domain& so, int bound, Array<double>& sec, int& pos_sec, int ncond) const {
29 
30  if (so.check_if_zero())
31  pos_sec += ncond ;
32  else {
33  so.coef() ;
34  Index pos_cf (nbr_coefs) ;
35  Index pos_galerkin (nbr_coefs) ;
36 
37  //k==0 ;
38  {
39  pos_cf.set(2) = 0 ;
40  int baset = (*so.get_base().bases_1d[1]) (0) ;
41  assert (baset==COS_EVEN) ;
42  for (int j=0 ; j<nbr_coefs(1) ; j++) {
43  pos_cf.set(1) = j ;
44  sec.set(pos_sec) = val_boundary(bound, so, pos_cf) ;
45  pos_sec ++ ;
46  }
47  }
48 
49  // k==2
50  if (nbr_coefs(2)-1>2)
51  {
52  pos_cf.set(2) = 2 ;
53  int baset = (*so.get_base().bases_1d[1]) (2) ;
54  assert (baset==SIN_ODD) ;
55  for (int j=0 ; j<nbr_coefs(1)-1 ; j++) {
56  pos_cf.set(1) = j ;
57  sec.set(pos_sec) = val_boundary(bound, so, pos_cf) ;
58  pos_sec ++ ;
59  }
60  }
61 
62  // k==3
63  if (nbr_coefs(2)-1>3)
64  {
65  pos_cf.set(2) = 3 ;
66  int baset = (*so.get_base().bases_1d[1]) (3) ;
67  assert (baset==SIN_ODD) ;
68  for (int j=0 ; j<nbr_coefs(1)-1 ; j++) {
69  pos_cf.set(1) = j ;
70  sec.set(pos_sec) = val_boundary(bound, so, pos_cf) ;
71  pos_sec ++ ;
72  }
73  }
74 
75  // others
76  for (int k=4 ; k<nbr_coefs(2)-1 ; k++) {
77 
78  pos_cf.set(2) = k ;
79  int baset = (*so.get_base().bases_1d[1]) (k) ;
80  int mquant = (k%2==0) ? int(k/2) : int((k-1)/2) ;
81 
82  if (mquant%2==0) {
83  assert (baset==COS_EVEN) ;
84  for (int j=1 ; j<nbr_coefs(1) ; j++) {
85  pos_cf.set(1) = j ;
86  pos_galerkin = pos_cf ;
87  pos_galerkin.set(1) = 0 ;
88  sec.set(pos_sec) = val_boundary(bound, so, pos_cf) -2.*val_boundary(bound, so, pos_galerkin) ;
89  pos_sec ++ ;
90  }
91  }
92 
93  if (mquant%2==1) {
94  assert (baset==SIN_ODD) ;
95  for (int j=0 ; j<nbr_coefs(1)-1 ; j++) {
96  pos_cf.set(1) = j ;
97  sec.set(pos_sec) = val_boundary(bound, so, pos_cf) ;
98  pos_sec ++ ;
99  }
100  }
101  }
102  }
103 }
104 
105 void Domain_nucleus::export_tau_val_domain_boundary_vt (const Val_domain& so, int bound, Array<double>& sec, int& pos_sec, int ncond) const {
106 
107  if (so.check_if_zero())
108  pos_sec += ncond ;
109  else {
110 
111  so.coef() ;
112  Index pos_cf (nbr_coefs) ;
113  Index pos_galerkin (nbr_coefs) ;
114 
115  //k==0 ;
116  {
117  pos_cf.set(2) = 0 ;
118  int baset = (*so.get_base().bases_1d[1]) (0) ;
119  assert (baset==SIN_EVEN) ;
120  for (int j=1 ; j<nbr_coefs(1)-1 ; j++) {
121  pos_cf.set(1) = j ;
122  sec.set(pos_sec) = val_boundary(bound, so, pos_cf) ;
123  pos_sec ++ ;
124  }
125  }
126 
127  // k==2
128  if (nbr_coefs(2)-1>2)
129  {
130  pos_cf.set(2) = 2 ;
131  int baset = (*so.get_base().bases_1d[1]) (2) ;
132  assert (baset==COS_ODD) ;
133  for (int j=0 ; j<nbr_coefs(1)-1 ; j++) {
134  pos_cf.set(1) = j ;
135  sec.set(pos_sec) = val_boundary(bound, so, pos_cf) ;
136  pos_sec ++ ;
137  }
138  }
139 
140  // k==3
141  if (nbr_coefs(2)-1>3)
142  {
143  pos_cf.set(2) = 3 ;
144  int baset = (*so.get_base().bases_1d[1]) (3) ;
145  assert (baset==COS_ODD) ;
146  for (int j=0 ; j<nbr_coefs(1)-1 ; j++) {
147  pos_cf.set(1) = j ;
148  sec.set(pos_sec) = val_boundary(bound, so, pos_cf) ;
149  pos_sec ++ ;
150  }
151  }
152 
153  // others
154  for (int k=4 ; k<nbr_coefs(2)-1 ; k++) {
155 
156  pos_cf.set(2) = k ;
157  int baset = (*so.get_base().bases_1d[1]) (k) ;
158  int mquant = (k%2==0) ? int(k/2) : int((k-1)/2) ;
159 
160  if (mquant%2==0) {
161  assert (baset==SIN_EVEN) ;
162  for (int j= 1 ; j<nbr_coefs(1)-1 ; j++) {
163  pos_cf.set(1) = j ;
164  sec.set(pos_sec) = val_boundary(bound, so, pos_cf) ;
165  pos_sec ++ ;
166  }
167  }
168 
169  if (mquant%2==1) {
170  assert (baset==COS_ODD) ;
171  for (int j=1 ; j<nbr_coefs(1)-1 ; j++) {
172  pos_cf.set(1) = j ;
173  pos_galerkin = pos_cf ;
174  pos_galerkin.set(1) = 0 ;
175  sec.set(pos_sec) = val_boundary(bound, so, pos_cf) -val_boundary(bound, so, pos_galerkin) ;
176  pos_sec ++ ;
177  }
178  }
179  }
180  }
181 
182  }
183 
184 
185 
186 void Domain_nucleus::export_tau_val_domain_boundary_vp (const Val_domain& so, int bound, Array<double>& sec, int& pos_sec, int ncond) const {
187 
188  if (so.check_if_zero())
189  pos_sec += ncond ;
190  else {
191  so.coef() ;
192  Index pos_cf (nbr_coefs) ;
193  Index pos_galerkin (nbr_coefs) ;
194 
195  // k==0
196  {
197  pos_cf.set(2) = 0 ;
198  int baset = (*so.get_base().bases_1d[1]) (0) ;
199  assert (baset==SIN_ODD) ;
200  for (int j=0 ; j<nbr_coefs(1)-1 ; j++) {
201  pos_cf.set(1) = j ;
202  sec.set(pos_sec) = val_boundary(bound, so, pos_cf) ;
203  pos_sec ++ ;
204  }
205  }
206 
207  // k==2
208  if (nbr_coefs(2)-1>2)
209  {
210  pos_cf.set(2) = 2 ;
211  int baset = (*so.get_base().bases_1d[1]) (2) ;
212  assert (baset==COS_EVEN) ;
213  for (int j=0 ; j<nbr_coefs(1) ; j++) {
214  pos_cf.set(1) = j ;
215  sec.set(pos_sec) = val_boundary(bound, so, pos_cf) ;
216  pos_sec ++ ;
217  }
218  }
219 
220  // k==3
221  if (nbr_coefs(2)-1>3)
222  {
223  pos_cf.set(2) = 3 ;
224  int baset = (*so.get_base().bases_1d[1]) (3) ;
225  assert (baset==COS_EVEN) ;
226  for (int j=0 ; j<nbr_coefs(1) ; j++) {
227  pos_cf.set(1) = j ;
228  sec.set(pos_sec) = val_boundary(bound, so, pos_cf) ;
229  pos_sec ++ ;
230  }
231  }
232 
233  // others
234  for (int k=4 ; k<nbr_coefs(2)-1 ; k++) {
235 
236  pos_cf.set(2) = k ;
237  int baset = (*so.get_base().bases_1d[1]) (k) ;
238  int mquant = (k%2==0) ? int(k/2) : int((k-1)/2) ;
239 
240  if (mquant%2==0) {
241  assert (baset==SIN_ODD) ;
242  for (int j= 0 ; j<nbr_coefs(1)-1 ; j++) {
243  pos_cf.set(1) = j ;
244  sec.set(pos_sec) = val_boundary(bound, so, pos_cf) ;
245  pos_sec ++ ;
246  }
247  }
248 
249  if (mquant%2==1) {
250  assert (baset==COS_EVEN) ;
251  for (int j=1 ; j<nbr_coefs(1) ; j++) {
252  pos_cf.set(1) = j ;
253  pos_galerkin = pos_cf ;
254  pos_galerkin.set(1) = 0 ;
255  sec.set(pos_sec) = val_boundary(bound, so, pos_cf) -2.*val_boundary(bound, so, pos_galerkin) ;
256  pos_sec ++ ;
257  }
258  }
259  }
260  }
261 }
262 
263 void Domain_nucleus::export_tau_val_domain_boundary (const Val_domain& so, int mlim, int bound, Array<double>& sec, int& pos_sec, int ncond) const {
264 
265  if (so.check_if_zero())
266  pos_sec += ncond ;
267  else {
268  so.coef() ;
269  int kmin = 2*mlim + 2 ;
270  Index pos_cf (nbr_coefs) ;
271  Index pos_galerkin (nbr_coefs) ;
272 
273  // Loop on phi :
274  for (int k=0 ; k<nbr_coefs(2)-1 ; k++)
275  if (k!=1) {
276  pos_cf.set(2) = k ;
277  // Loop on theta
278  int baset = (*so.get_base().bases_1d[1]) (k) ;
279  for (int j=0 ; j<nbr_coefs(1) ; j++) {
280  pos_cf.set(1) = j ;
281  switch (baset) {
282  case COS_EVEN:
283  if (k<kmin) {
284  sec.set(pos_sec) = val_boundary(bound, so, pos_cf) ;
285  pos_sec ++ ;
286  }
287  else if (j!=0) {
288  // Galerkin base
289  pos_galerkin = pos_cf ;
290  pos_galerkin.set(1) = 0 ;
291  sec.set(pos_sec) = val_boundary(bound, so, pos_cf)
292  -2.*val_boundary(bound, so, pos_galerkin) ;
293  pos_sec ++ ;
294  }
295  break ;
296  case COS_ODD:
297  if (j!=nbr_coefs(1)-1) {
298  if (k<kmin) {
299  sec.set(pos_sec) = val_boundary(bound, so, pos_cf) ;
300  pos_sec ++ ;
301  }
302  else if (j!=0) {
303  // Galerkin base
304  pos_galerkin = pos_cf ;
305  pos_galerkin.set(1) = 0 ;
306  sec.set(pos_sec) = val_boundary(bound, so, pos_cf)
307  -val_boundary(bound, so, pos_galerkin) ;
308  pos_sec ++ ;
309  }}
310  break ;
311  case SIN_EVEN:
312  if ((j!=0) && (j!=nbr_coefs(1)-1)) {
313  if (k<kmin+2) {
314  sec.set(pos_sec) = val_boundary(bound, so, pos_cf) ;
315  pos_sec ++ ;
316  }
317  else if (j!=1) {
318  // Galerkin base
319  // Galerkin base
320  pos_galerkin = pos_cf ;
321  pos_galerkin.set(1) = 1 ;
322  sec.set(pos_sec) = val_boundary(bound, so, pos_cf)
323  -j*val_boundary(bound, so, pos_galerkin) ;
324  pos_sec ++ ;
325  }
326  }
327  break ;
328  case SIN_ODD:
329  if (j!=nbr_coefs(1)-1) {
330  if (k<kmin+2) {
331  sec.set(pos_sec) = val_boundary(bound, so, pos_cf) ;
332  pos_sec ++ ;
333  }
334  else if (j!=0) {
335  // Galerkin base
336  pos_galerkin = pos_cf ;
337  pos_galerkin.set(1) = 0 ;
338  sec.set(pos_sec) = val_boundary(bound, so, pos_cf)
339  -(2*j+1)*val_boundary(bound, so, pos_galerkin) ;
340  pos_sec ++ ;
341  }}
342  break ;
343  default:
344  cerr << "Unknow theta basis in Domain_nucleus::export_tau_val_domain_boundary" << endl ;
345  abort() ;
346  }
347  }
348  }
349  }
350 }
351 
352 void Domain_nucleus::export_tau_boundary (const Tensor& tt, int dom, int bound, Array<double>& res, int& pos_res, const Array<int>& ncond,
353  int n_cmp, Array<int>** p_cmp) const {
354 
355  // Check boundary
356  if (bound!=OUTER_BC) {
357  cerr << "Unknown boundary in Domain_nucleus::export_tau_boundary" << endl ;
358  abort() ;
359  }
360 
361  int val = tt.get_valence() ;
362  switch (val) {
363  case 0 :
364  if (!tt.is_m_order_affected())
365  export_tau_val_domain_boundary (tt()(dom), 0, bound, res, pos_res, ncond(0)) ;
366  else
367  export_tau_val_domain_boundary (tt()(dom), tt.get_parameters().get_m_order(), bound, res, pos_res, ncond(0)) ;
368  break ;
369  case 1 : {
370  bool found = false ;
371  // Cartesian basis
372  if (tt.get_basis().get_basis(dom)==CARTESIAN_BASIS) {
373  if (n_cmp==-1) {
374  export_tau_val_domain_boundary (tt(1)(dom), 0, bound, res, pos_res, ncond(0)) ;
375  export_tau_val_domain_boundary (tt(2)(dom), 0, bound, res, pos_res, ncond(1)) ;
376  export_tau_val_domain_boundary (tt(3)(dom), 0, bound, res, pos_res, ncond(2)) ;
377  }
378  else for (int i=0 ; i<n_cmp ; i++) {
379  if ((*p_cmp[i])(0)==1)
380  export_tau_val_domain_boundary (tt(1)(dom), 0, bound, res, pos_res, ncond(i)) ;
381  if ((*p_cmp[i])(0)==2)
382  export_tau_val_domain_boundary (tt(2)(dom), 0, bound, res, pos_res, ncond(i)) ;
383  if ((*p_cmp[i])(0)==3)
384  export_tau_val_domain_boundary (tt(3)(dom), 0, bound, res, pos_res, ncond(i)) ;
385  }
386  found = true ;
387  }
388  // Spherical coordinates
389  if (tt.get_basis().get_basis(dom)==SPHERICAL_BASIS) {
390  if (n_cmp==-1) {
391  export_tau_val_domain_boundary_vr (tt(1)(dom), bound, res, pos_res, ncond(0)) ;
392  export_tau_val_domain_boundary_vt (tt(2)(dom), bound, res, pos_res, ncond(1)) ;
393  export_tau_val_domain_boundary_vp (tt(3)(dom), bound, res, pos_res, ncond(2)) ;
394  }
395  else for (int i=0 ; i<n_cmp ; i++) {
396  if ((*p_cmp[i])(0)==1)
397  export_tau_val_domain_boundary_vr (tt(1)(dom), bound, res, pos_res, ncond(i)) ;
398  if ((*p_cmp[i])(0)==2)
399  export_tau_val_domain_boundary_vt (tt(2)(dom), bound, res, pos_res, ncond(i)) ;
400  if ((*p_cmp[i])(0)==3)
401  export_tau_val_domain_boundary_vp (tt(3)(dom), bound, res, pos_res, ncond(i)) ;
402  }
403  found = true ;
404  }
405  if (!found) {
406  cerr << "Unknown type of vector Domain_nucleus::export_tau_boundary" << endl ;
407  abort() ;
408  }
409  }
410  break ;
411  case 2 : {
412  bool found = false ;
413  // Cartesian basis and symetric
414  if ((tt.get_basis().get_basis(dom)==CARTESIAN_BASIS) && (tt.get_n_comp()==6)) {
415  if (n_cmp==-1) {
416  export_tau_val_domain_boundary (tt(1,1)(dom), 0, bound, res, pos_res, ncond(0)) ;
417  export_tau_val_domain_boundary (tt(1,2)(dom), 0, bound, res, pos_res, ncond(1)) ;
418  export_tau_val_domain_boundary (tt(1,3)(dom), 0, bound, res, pos_res, ncond(2)) ;
419  export_tau_val_domain_boundary (tt(2,2)(dom), 0, bound, res, pos_res, ncond(3)) ;
420  export_tau_val_domain_boundary (tt(2,3)(dom), 0, bound, res, pos_res, ncond(4)) ;
421  export_tau_val_domain_boundary (tt(3,3)(dom), 0, bound, res, pos_res, ncond(5)) ;
422  }
423  else for (int i=0 ; i<n_cmp ; i++) {
424  if (((*p_cmp[i])(0)==1) && ((*p_cmp[i])(1)==1))
425  export_tau_val_domain_boundary (tt(1, 1)(dom), 0, bound, res, pos_res, ncond(i)) ;
426  if (((*p_cmp[i])(0)==1) && ((*p_cmp[i])(1)==2))
427  export_tau_val_domain_boundary (tt(1, 2)(dom), 0, bound, res, pos_res, ncond(i)) ;
428  if (((*p_cmp[i])(0)==1) && ((*p_cmp[i])(1)==3))
429  export_tau_val_domain_boundary (tt(1, 3)(dom), 0, bound, res, pos_res, ncond(i)) ;
430  if (((*p_cmp[i])(0)==2) && ((*p_cmp[i])(1)==2))
431  export_tau_val_domain_boundary (tt(2, 2)(dom), 0, bound, res, pos_res, ncond(i)) ;
432  if (((*p_cmp[i])(0)==2) && ((*p_cmp[i])(1)==3))
433  export_tau_val_domain_boundary (tt(2, 3)(dom), 0, bound, res, pos_res, ncond(i)) ;
434  if (((*p_cmp[i])(0)==3) && ((*p_cmp[i])(1)==3))
435  export_tau_val_domain_boundary (tt(3, 3)(dom), 0, bound, res, pos_res, ncond(i)) ;
436  }
437  found = true ;
438  }
439  // Cartesian basis and not symetric
440  if ((tt.get_basis().get_basis(dom)==CARTESIAN_BASIS) && (tt.get_n_comp()==9)) {
441  if (n_cmp==-1) {
442  export_tau_val_domain_boundary (tt(1,1)(dom), 0, bound, res, pos_res, ncond(0)) ;
443  export_tau_val_domain_boundary (tt(1,2)(dom), 0, bound, res, pos_res, ncond(1)) ;
444  export_tau_val_domain_boundary (tt(1,3)(dom), 0, bound, res, pos_res, ncond(2)) ;
445  export_tau_val_domain_boundary (tt(2,1)(dom), 0, bound, res, pos_res, ncond(3)) ;
446  export_tau_val_domain_boundary (tt(2,2)(dom), 0, bound, res, pos_res, ncond(4)) ;
447  export_tau_val_domain_boundary (tt(2,3)(dom), 0, bound, res, pos_res, ncond(5)) ;
448  export_tau_val_domain_boundary (tt(3,1)(dom), 0, bound, res, pos_res, ncond(6)) ;
449  export_tau_val_domain_boundary (tt(3,2)(dom), 0, bound, res, pos_res, ncond(7)) ;
450  export_tau_val_domain_boundary (tt(3,3)(dom), 0, bound, res, pos_res, ncond(8)) ;
451 
452  }
453  else for (int i=0 ; i<n_cmp ; i++) {
454  if (((*p_cmp[i])(0)==1) && ((*p_cmp[i])(1)==1))
455  export_tau_val_domain_boundary (tt(1, 1)(dom), 0, bound, res, pos_res, ncond(i)) ;
456  if (((*p_cmp[i])(0)==1) && ((*p_cmp[i])(1)==2))
457  export_tau_val_domain_boundary (tt(1, 2)(dom), 0, bound, res, pos_res, ncond(i)) ;
458  if (((*p_cmp[i])(0)==1) && ((*p_cmp[i])(1)==3))
459  export_tau_val_domain_boundary (tt(1, 3)(dom), 0, bound, res, pos_res, ncond(i)) ;
460  if (((*p_cmp[i])(0)==2) && ((*p_cmp[i])(1)==1))
461  export_tau_val_domain_boundary (tt(2, 1)(dom), 0, bound, res, pos_res, ncond(i)) ;
462  if (((*p_cmp[i])(0)==2) && ((*p_cmp[i])(1)==2))
463  export_tau_val_domain_boundary (tt(2, 2)(dom), 0, bound, res, pos_res, ncond(i)) ;
464  if (((*p_cmp[i])(0)==2) && ((*p_cmp[i])(1)==3))
465  export_tau_val_domain_boundary (tt(2, 3)(dom), 0, bound, res, pos_res, ncond(i)) ;
466  if (((*p_cmp[i])(0)==3) && ((*p_cmp[i])(1)==1))
467  export_tau_val_domain_boundary (tt(3, 1)(dom), 0, bound, res, pos_res, ncond(i)) ;
468  if (((*p_cmp[i])(0)==3) && ((*p_cmp[i])(1)==2))
469  export_tau_val_domain_boundary (tt(3, 2)(dom), 0, bound, res, pos_res, ncond(i)) ;
470  if (((*p_cmp[i])(0)==3) && ((*p_cmp[i])(1)==3))
471  export_tau_val_domain_boundary (tt(3, 3)(dom), 0, bound, res, pos_res, ncond(i)) ;
472  }
473  found = true ;
474  }
475  if (!found) {
476  cerr << "Unknown type of 2-tensor Domain_nucleus::export_tau_boundary" << endl ;
477  abort() ;
478  }
479  }
480  break ;
481  default :
482  cerr << "Valence " << val << " not implemented in Domain_nucleus::export_tau_boundary" << endl ;
483  break ;
484  }
485 }}
reference set(const Index &pos)
Read/write of an element.
Definition: array.hpp:186
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.
Definition: base_tensor.hpp:93
void export_tau_val_domain_boundary_vr(const Val_domain &eq, int bound, Array< double > &res, int &pos_res, int ncond) const
Exports all the residual equations corresponding to a tensorial one on a given boundary It makes use ...
void export_tau_val_domain_boundary(const Val_domain &eq, int mlim, int bound, Array< double > &res, int &pos_res, int ncond) const
Exports all the residual equations corresponding to a tensorial one on a given boundary It makes use ...
virtual double val_boundary(int, const Val_domain &, const Index &) const
Computes the value of a field at a boundary.
void export_tau_val_domain_boundary_vp(const Val_domain &eq, int bound, Array< double > &res, int &pos_res, int ncond) const
Exports all the residual equations corresponding to a tensorial one on a given boundary It makes use ...
void export_tau_val_domain_boundary_vt(const Val_domain &eq, int bound, Array< double > &res, int &pos_res, int ncond) const
Exports all the residual equations corresponding to a tensorial one on a given boundary It makes use ...
virtual void export_tau_boundary(const Tensor &, int, int, Array< double > &, int &, const Array< int > &, int n_cmp=-1, Array< int > **p_cmp=0x0) const
Exports all the residual equations corresponding to a tensorial one on a given boundary It makes use ...
Dim_array nbr_coefs
Number of coefficients.
Definition: space.hpp:66
Class that gives the position inside a multi-dimensional Array.
Definition: index.hpp:38
int & set(int i)
Read/write of the position in a given dimension.
Definition: index.hpp:72
int get_m_order() const
Returns .
Definition: tensor.hpp:737
Tensor handling.
Definition: tensor.hpp:149
bool is_m_order_affected() const
Checks whether the additional parameter order is affected (not very used).
Definition: tensor.hpp:323
const Param_tensor & get_parameters() const
Returns a pointer on the possible additional parameter.
Definition: tensor.hpp:311
const Base_tensor & get_basis() const
Returns the vectorial basis (triad) on which the components are defined.
Definition: tensor.hpp:504
int get_n_comp() const
Returns the number of stored components.
Definition: tensor.hpp:514
int get_valence() const
Returns the valence.
Definition: tensor.hpp:509
Class for storing the basis of decompositions of a field and its values on both the configuration and...
Definition: val_domain.hpp:69
bool check_if_zero() const
Check whether the logical state is zero or not.
Definition: val_domain.hpp:142
void coef() const
Computes the coefficients.
Definition: val_domain.cpp:622
const Base_spectral & get_base() const
Returns the basis of decomposition.
Definition: val_domain.hpp:122