Rheolef  7.2
an efficient C++ finite element environment
 
Loading...
Searching...
No Matches
field_expr_terminal.cc
Go to the documentation of this file.
1//
21//
22// field_expr_terminal: terminals of nonn-linear expressions
23// 1) class-function
24// 1.1) base class for the class-function family
25// 1.2) general function or class-function
26// 1.3) normal to a surface
27// 1.4) h_local
28// 1.5) penalty
29// 2) field and such
30// 2.1) field
31// 2.2) jump of a field
32// 3) convected field, as compose(uh,X) where X is a characteristic
33//
34#include "rheolef/field_expr_terminal.h"
35#include "rheolef/geo_domain.h"
36#include "rheolef/piola_util.h"
37#include "rheolef/field_evaluate.h"
38#include "rheolef/memorized_disarray.h"
39
40namespace rheolef { namespace details {
41
42// ---------------------------------------------------------------------------
43// 1.1) base class for all class-functions
44// ---------------------------------------------------------------------------
45template<class T>
50template<class T>
55template<class T>
56void
63template<class T>
64void
72// TODO: move as geo::get_side (K, sid) ?
73template<class T, class M>
74const geo_element&
76 const geo_basic<T,M>& omega_L,
77 const geo_element& L,
78 const side_information_type& sid)
79{
81 size_type dis_isid = std::numeric_limits<size_type>::max();
82 switch (sid.dim) {
83 case 0: {
84 size_type dis_inod = L [sid.loc_isid];
85 dis_isid = omega_L.dis_inod2dis_iv (dis_inod);
86 break;
87 }
88 case 1: dis_isid = L.edge (sid.loc_isid); break;
89 case 2: dis_isid = L.face (sid.loc_isid); break;
90 default: error_macro ("domain: unexpected side dimension " << sid.dim);
91 }
92 // TODO: pas tres clair quand on est sur un geo_domain_indirect ou un geo_domain
93 // dans quel systeme de numerotation doit appartenir la face ?
94 if (omega_L.variant() != geo_abstract_base_rep<T>::geo_domain_indirect) {
95 return omega_L.dis_get_geo_element (sid.dim, dis_isid);
96 } else {
97 return omega_L.get_background_geo().dis_get_geo_element (sid.dim, dis_isid);
98 }
99}
100template<class T>
101template<class M>
102const geo_element&
104 const geo_basic<T,M>& omega_L,
105 const geo_element& L,
106 const side_information_type& sid) const
107{
108 return global_get_side (omega_L, L, sid);
109}
110// ----------------------------------------------------------------------------
111// 1.3) normal() class-function
112// ----------------------------------------------------------------------------
113template<class T>
114field_expr_v2_nonlinear_terminal_function_rep<normal_pseudo_function<T> >::field_expr_v2_nonlinear_terminal_function_rep(
115 const function_type&)
116 : base(),
117 _is_on_interface (false),
118 _is_inside_on_local_sides(false)
119{
120}
121template<class T>
122field_expr_v2_nonlinear_terminal_function_rep<normal_pseudo_function<T> >::field_expr_v2_nonlinear_terminal_function_rep(
124 : base(x),
125 _is_on_interface (x._is_on_interface),
126 _is_inside_on_local_sides(x._is_inside_on_local_sides)
127{
129template<class T>
130void
133 const integrate_option& iopt)
134{
135 base::initialize (pops, iopt);
136 _is_on_interface = iopt._is_on_interface;
137 _is_inside_on_local_sides = iopt._is_inside_on_local_sides;
138}
139template<class T>
140void
144 const integrate_option& iopt)
145{
146 base::initialize (Xh, pops, iopt);
147 _is_on_interface = iopt._is_on_interface;
148 _is_inside_on_local_sides = iopt._is_inside_on_local_sides;
149}
150template<class T>
151void
154 const geo_element& K,
155 const T& sign,
156 Eigen::Matrix<result_type,Eigen::Dynamic,1>& value) const
157{
158 const Eigen::Matrix<piola<float_type>,Eigen::Dynamic,1>& piola = base::_pops.get_piola (omega_K, K);
159 size_type d = omega_K.dimension();
160 size_type loc_nnod = piola.size();
161 value.resize (loc_nnod);
162 for (size_type loc_inod = 0; loc_inod < loc_nnod; ++loc_inod) {
163 const point_basic<float_type>& xi = piola[loc_inod].F;
164 value[loc_inod] = sign*normal_from_piola_transformation (omega_K, K, piola[loc_inod].DF, d);
165 }
166}
167template<class T>
168void
171 const geo_element& K,
172 Eigen::Matrix<result_type,Eigen::Dynamic,1>& value) const
173{
174 evaluate_internal (omega_K, K, T(1), value);
175}
176template<class T>
177void
180 const geo_element& L,
181 const side_information_type& sid,
182 Eigen::Matrix<result_type,Eigen::Dynamic,1>& value) const
183{
184 if (_is_inside_on_local_sides) {
185 T sign = (L.dimension() > 1) ? sid.orient : ((sid.loc_isid == 0) ? -1 : 1);
186 evaluate_internal (omega_L, global_get_side(omega_L, L, sid), sign, value);
187 } else {
188 // BUG_INT_BDR_JUMP: check _is_on_interface and send sign of side in base::_omega
189 evaluate_internal (omega_L, global_get_side(omega_L, L, sid), T(1), value);
190 }
191}
192// ----------------------------------------------------------------------------
193// 1.4) h_local() class-function
194// ----------------------------------------------------------------------------
195template<class T>
197 const function_type&)
198 : base()
199{
200}
201template<class T>
207template<class T>
208void
215template<class T>
216void
224template<class T>
225void
228 const geo_element& K,
229 Eigen::Matrix<result_type,Eigen::Dynamic,1>& value) const
230{
231 const Eigen::Matrix<piola<float_type>,Eigen::Dynamic,1>& piola = base::_pops.get_piola (omega_K, K);
232 size_type loc_nnod = piola.size();
233 value.resize (loc_nnod);
234 size_type K_map_d = K.dimension();
235 if (K_map_d > 0) {
236 // usual case: K is at least one edge
237 reference_element hat_K = K.variant();
238 T meas_hat_K = measure(hat_K);
239 size_type d = omega_K.dimension();
240 for (size_type loc_inod = 0; loc_inod < loc_nnod; ++loc_inod) {
241 // TODO DVT_PIOLA_LOOP_ORDER_1: improve: when omega_K.order=1 then DF=constant and value[*]=constant
242 T det_DF_i = det_jacobian_piola_transformation (piola[loc_inod].DF, d, K_map_d);
243 value[loc_inod] = pow (abs(det_DF_i)/meas_hat_K, 1./K_map_d);
244 trace_macro("h_local("<<omega_K.name()<<",K="<<K.name()<<K.dis_ie()<<")="<< value[loc_inod]);
245 }
246 return;
247 }
248 // special case: d == 0 i.e. an "interface" between two edges in 1D
249 // then h_local = average of two edge length
250 size_type L_dis_ie[2] = {K.master(0), K.master(1)};
251 size_t n = (L_dis_ie[0] == std::numeric_limits<size_type>::max()) ? 0 :
252 (L_dis_ie[1] == std::numeric_limits<size_type>::max()) ? 1 : 2;
253 if (n == 0) {
254 // special 0d meshes:
255 // dis_nelt_1d=0: special 0d mesh, e.g. omega["sides"] when omega is 1d
256 // n=0: isolated point(s) in a 0D mesh
257 // => h_local=1 by default
258 value.fill (result_type(1));
259 trace_macro("h_local("<<omega_K.name()<<",K="<<K.name()<<K.dis_ie()<<")=1");
260 } else {
261 size_t dis_nelt_1d = omega_K.sizes().ownership_by_dimension[1].dis_size();
262 check_macro (dis_nelt_1d != 0, "h_local: invalid \""<<omega_K.name()<<"\" mesh with missing 1D connectivity");
263 size_t L_map_d = 1;
264 Float h_loc = 0;
265 for (size_type i = 0; i < n; ++i) {
266 const geo_element& Li = omega_K.dis_get_geo_element (L_map_d, L_dis_ie[i]);
267 const point_basic<float_type>& x0 = omega_K.dis_node (Li[0]);
268 const point_basic<float_type>& x1 = omega_K.dis_node (Li[1]);
269 h_loc += norm (x1-x0)/n;
270 }
271 value.fill (result_type(h_loc));
272 trace_macro("h_local("<<omega_K.name()<<",K="<<K.name()<<K.dis_ie()<<")="<< h_loc);
273 }
274}
275template<class T>
276void
278 const geo_basic<float_type,memory_type>& omega_L,
279 const geo_element& L,
280 const side_information_type& sid,
281 Eigen::Matrix<result_type,Eigen::Dynamic,1>& value) const
282{
283 evaluate (omega_L, global_get_side(omega_L, L, sid), value);
284}
285// ----------------------------------------------------------------------------
286// 1.5) penalty() class-function
287// ----------------------------------------------------------------------------
288template<class T>
290 const function_type&)
291 : base()
292{
293}
294template<class T>
300template<class T>
301void
308template<class T>
309void
317template<class T>
318T
321 const geo_element& K) const
322{
323 const Eigen::Matrix<piola<float_type>,Eigen::Dynamic,1>& piola = base::_pops.get_piola (omega_K, K);
324 size_type loc_nnod = piola.size();
325 size_type d = omega_K.dimension();
326 size_type map_d = K.dimension();
327 T meas_max_K = 0;
328 for (size_type loc_inod = 0; loc_inod < loc_nnod; ++loc_inod) {
329 // TODO DVT_PIOLA_LOOP_ORDER_1: improve: when omega_K.order=1 then DF=constant and value[*]=constant
330 T meas_K = det_jacobian_piola_transformation (piola[loc_inod].DF, d, map_d);
331 meas_max_K = std::max (meas_max_K, abs(meas_K));
332 }
333trace_macro("meas("<<omega_K.name()<<",K="<<K.name()<<K.dis_ie()<<")="<< meas_max_K);
334 return meas_max_K;
335}
336template<class T>
337void
340 const geo_element& K,
341 const geo_element& L,
342 Eigen::Matrix<result_type,Eigen::Dynamic,1>& value) const
343{
344 // meas(partial L)/meas(L) ~= nside*meas(K)/meas(L) : TODO try to improve it for non-uniform meshes
345 size_type n_sides = L.n_subgeo (K.dimension());
346 T meas_side_L = evaluate_measure (omega_K, K);
347 T meas_L = evaluate_measure (omega_K, L);
348 T result = n_sides*meas_side_L/meas_L;
349trace_macro("penalty("<<omega_K.name()<<",K="<<K.name()<<K.dis_ie()<<")="<< result);
350 const Eigen::Matrix<piola<float_type>,Eigen::Dynamic,1>& piola = base::_pops.get_piola (omega_K, K);
351 size_type loc_nnod = piola.size();
352 value.resize (loc_nnod);
353 for (size_type loc_inod = 0; loc_inod < loc_nnod; ++loc_inod) {
354 value[loc_inod] = result;
355 }
356}
357template<class T>
358void
361 const geo_element& K,
362 Eigen::Matrix<result_type,Eigen::Dynamic,1>& value) const
363{
364 size_type L_map_d = K.dimension() + 1;
365 size_type L_dis_ie0 = K.master(0);
366 check_macro (L_dis_ie0 != std::numeric_limits<size_type>::max(),
367 "unexpected isolated side K="<<K.name()<<K.dis_ie()<< " in mesh \""<<omega_K.name()<<"\"");
368 const geo_element& L0 = omega_K.dis_get_geo_element (L_map_d, L_dis_ie0);
369 evaluate_internal (omega_K, K, L0, value);
370 size_type L_dis_ie1 = K.master(1);
371 if (L_dis_ie1 == std::numeric_limits<size_type>::max()) {
372 // K is a boundary side: nothing more to do
373 true;
374 } else {
375 // K is an internal side
376 const geo_element& L1 = omega_K.dis_get_geo_element (L_map_d, L_dis_ie1);
377 Eigen::Matrix<result_type,Eigen::Dynamic,1> value1;
378 evaluate_internal (omega_K, K, L0, value);
379 evaluate_internal (omega_K, K, L1, value1);
380 for (size_type loc_idof = 0, loc_ndof = value.size(); loc_idof < loc_ndof; ++loc_idof) {
381 value[loc_idof] = std::max (value [loc_idof], value1 [loc_idof]);
382 }
383 }
384}
385template<class T>
386void
388 const geo_basic<float_type,memory_type>& omega_L,
389 const geo_element& L,
390 const side_information_type& sid,
391 Eigen::Matrix<result_type,Eigen::Dynamic,1>& value) const
392{
393 evaluate (omega_L, global_get_side(omega_L, L, sid), value);
394}
395// ----------------------------------------------------------------------------
396// 2) field and such
397// ----------------------------------------------------------------------------
398// 2.1) field
399// ----------------------------------------------------------------------------
400template<class T, class M, details::differentiate_option::type Diff>
401void
403 const piola_on_pointset<T>& pops,
404 const integrate_option& iopt)
405{
406 _uh.dis_dof_update();
407 _u_test.initialize (pops, iopt);
408}
409template<class T, class M, details::differentiate_option::type Diff>
410void
412 const space_basic<T,M>& Xh,
414 const integrate_option& iopt)
415{
416 check_macro (_uh.get_geo().get_background_geo().name() == Xh.get_geo().get_background_geo().name(),
417 "incompatible field on " << _uh.get_geo().get_background_geo().name() << " for evaluation on " << Xh.get_geo().get_background_geo().name());
418 _uh.dis_dof_update();
419 _u_test.initialize (Xh, pops, iopt);
420}
421template<class T, class M, details::differentiate_option::type Diff>
422template<class Value>
423void
426 const geo_element& K,
427 Eigen::Matrix<Value,Eigen::Dynamic,1>& value) const
428{
429 Eigen::Matrix<Value,Eigen::Dynamic,Eigen::Dynamic> diff_phij_xi;
430 _u_test.template evaluate <Value,Diff> (omega_K, K, _gopt, diff_phij_xi);
431 field_evaluate_continued (_uh, omega_K, K, diff_phij_xi, value);
432}
433template<class T, class M, details::differentiate_option::type Diff>
434template<class Value>
435void
438 const geo_element& K,
439 const side_information_type& sid,
440 Eigen::Matrix<Value,Eigen::Dynamic,1>& value) const
441{
442 Eigen::Matrix<Value,Eigen::Dynamic,Eigen::Dynamic> diff_phij_xi;
443 bool do_local_component_assembly = true;
444 _u_test.template evaluate_on_side<Value,Diff> (omega_K, K, sid, _gopt, diff_phij_xi, do_local_component_assembly);
445 field_evaluate_continued (_uh, omega_K, K, diff_phij_xi, value);
446}
447template<class T, class M, details::differentiate_option::type Diff>
450{
451 switch (Diff) {
453 return _uh.valued_tag();
454 }
456 space_constant::valued_type uh_valued_tag = _uh.valued_tag();
457 switch (uh_valued_tag) {
463 default:
464 error_macro ("unsupported "<<uh_valued_tag<< "-valued field for the grad() operator");
466 }
467 }
469 space_constant::valued_type uh_valued_tag = _uh.valued_tag();
470 switch (uh_valued_tag) {
475 default:
476 error_macro ("unsupported "<<uh_valued_tag<< "-valued field for the div() operator");
478 }
479 }
481 space_constant::valued_type uh_valued_tag = _uh.valued_tag();
482 switch (uh_valued_tag) {
485 size_type d = _uh.get_geo().dimension();
487 }
488 default:
489 error_macro ("unsupported "<<uh_valued_tag<< "-valued field for the curl() operator");
491 }
492 }
493 }
494}
495// ----------------------------------------------------------------------------
496// 2.2) field jump
497// ----------------------------------------------------------------------------
498template<class T, class M>
499void
502 const integrate_option& iopt)
503{
504 _expr0.initialize (pops, iopt);
505 _expr1.initialize (pops, iopt);
506}
507template<class T, class M>
508void
512 const integrate_option& iopt)
513{
514 _expr0.initialize (Xh, pops, iopt);
515 _expr1.initialize (Xh, pops, iopt);
516}
517template<class T, class M>
518template<class Result>
519void
522 const geo_element& K,
523 Eigen::Matrix<Result,Eigen::Dynamic,1>& value) const
524{
525 size_type L_map_d = K.dimension() + 1;
526 size_type L_dis_ie0, L_dis_ie1;
527 side_information_type sid0, sid1;
528 L_dis_ie0 = K.master(0);
529 const geo_basic<T,M>& omega_L = omega_K.get_background_geo();
530 check_macro (L_dis_ie0 != std::numeric_limits<size_type>::max(),
531 "unexpected isolated mesh side K.dis_ie="<<K.dis_ie());
532 const geo_element& L0 = omega_L.dis_get_geo_element (L_map_d, L_dis_ie0);
533 L0.get_side_informations (K, sid0);
534 _expr0.evaluate_on_side (omega_L, L0, sid0, value);
535 L_dis_ie1 = K.master(1);
536 if (L_dis_ie1 == std::numeric_limits<size_type>::max()) {
537 // K is a boundary side
538 // jump(v)=average(v)=inner(v)=outer(v)=v on the boundary
539 // TODO: DVT_EIGEN_BLAS2 : pb when Value=point
540 for (size_type loc_inod = 0, loc_nnod = value.rows(); loc_inod < loc_nnod; ++loc_inod) {
541 for (size_type loc_jdof = 0, loc_ndof = value.cols(); loc_jdof < loc_ndof; ++loc_jdof) {
542 value(loc_inod,loc_jdof) = value(loc_inod,loc_jdof);
543 }}
544 } else {
545 // K is an internal side
546 Eigen::Matrix<Result,Eigen::Dynamic,1> value1;
547 const geo_element& L1 = omega_L.dis_get_geo_element (L_map_d, L_dis_ie1);
548 L1.get_side_informations (K, sid1);
549 _expr1.evaluate_on_side (omega_L, L1, sid1, value1);
550 for (size_type loc_inod = 0, loc_nnod = value.rows(); loc_inod < loc_nnod; ++loc_inod) {
551 for (size_type loc_jdof = 0, loc_ndof = value.cols(); loc_jdof < loc_ndof; ++loc_jdof) {
552 value(loc_inod,loc_jdof) = _c0*value(loc_inod,loc_jdof) + _c1*value1(loc_inod,loc_jdof);
553 }}
554 }
555}
556// ---------------------------------------------------------------------------
557// 3) contains a convected field, as compose(uh,X) where X is a characteristic
558// ---------------------------------------------------------------------------
559template<class T, class M, class Value>
560void
562 const field_basic<T,M>& uh,
563 const disarray<point_basic<T>,M>& x,
564 const disarray<index_set,M>& ie2dis_ix, // K -> list of ix
565 const disarray<point_basic<T>,M>& hat_y, // ix -> hat_y
567
568template<class T, class M>
569void
572 const integrate_option& iopt)
573{
574 // handle the case when omega (destination) is different from _X.get_displacement.get_geo (origin)
575 // as in mesh adaptation loops
576 _uh.dis_dof_update();
577 _fops.initialize (_uh.get_space().get_basis(), pops);
578
579 // coq is stored in _X : it is independent of _uh ; depend only of _uh.space and quadrature nodes (qopt)
580 const characteristic_on_quadrature<T,M> coq = _X.get_pre_computed (_uh.get_space(), _X.get_displacement(), pops);
581 const characteristic_on_quadrature_rep<T,M>& coq_r = coq.data();
582 switch (_uh.valued_tag()) {
584 _scalar_val.resize (coq_r._yq.ownership());
585 interpolate_pass2_valued (_uh, coq_r._yq, coq_r._ie2dis_ix, coq_r._hat_y, _scalar_val);
586 break;
588 _vector_val.resize (coq_r._yq.ownership());
589 interpolate_pass2_valued (_uh, coq_r._yq, coq_r._ie2dis_ix, coq_r._hat_y, _vector_val);
590 break;
591 default: error_macro("unsupported "<<_uh.valued()<<"-valued charateristic");
592 }
593 _start_q = 0;
594}
595template<class T, class M>
596void
600 const integrate_option& iopt)
601{
602 fatal_macro ("characteristic: not supported with interpolate (HINT: use integrate with Gauss-Lobatto quadrature)");
603}
604template<class T, class M>
605template<class Value>
606void
609 const geo_element& K,
610 Eigen::Matrix<Value,Eigen::Dynamic,1>& value) const
611{
612 const disarray<Value,M>& uq = memorized_disarray<T,Value>().get (*this);
613 typename disarray<Value>::const_iterator uq_K = uq.begin();
614 size_type loc_nnod = _fops.get_piola_on_pointset().get_basis_on_pointset().nnod(K);
615 value.resize (loc_nnod);
616 for (size_type loc_inod = 0; loc_inod < loc_nnod; loc_inod++, _start_q++) {
617 value [loc_inod] = uq_K [_start_q];
618 }
619}
620// ----------------------------------------------------------------------------
621// instanciation in library (v2)
622// ----------------------------------------------------------------------------
623#define _RHEOLEF_instanciation_base_seq_only(T) \
624template class field_expr_v2_nonlinear_terminal_function_base_rep<T>; \
625template class field_expr_v2_nonlinear_terminal_function_rep< normal_pseudo_function<T> >; \
626template class field_expr_v2_nonlinear_terminal_function_rep<h_local_pseudo_function<T> >; \
627template class field_expr_v2_nonlinear_terminal_function_rep<penalty_pseudo_function<T> >; \
628
629// extra when Result=tensor3, tensor4
630#define _RHEOLEF_instanciation_base_both_members_diff(T,M,Result,Diff) \
631template void field_expr_v2_nonlinear_terminal_field_rep<T,M,Diff>::evaluate ( \
632 const geo_basic<T,M>& omega_K, \
633 const geo_element& K, \
634 Eigen::Matrix<Result,Eigen::Dynamic,1>& value) const; \
635template void field_expr_v2_nonlinear_terminal_field_rep<T,M,Diff>::evaluate_on_side ( \
636 const geo_basic<T,M>& omega_L, \
637 const geo_element& L, \
638 const side_information_type& sid, \
639 Eigen::Matrix<Result,Eigen::Dynamic,1>& value) const; \
640
641#define _RHEOLEF_instanciation_base_both_members_alls(T,M,Result) \
642_RHEOLEF_instanciation_base_both_members_diff(T,M,Result,details::differentiate_option::none) \
643_RHEOLEF_instanciation_base_both_members_diff(T,M,Result,details::differentiate_option::gradient) \
644_RHEOLEF_instanciation_base_both_members_diff(T,M,Result,details::differentiate_option::divergence) \
645_RHEOLEF_instanciation_base_both_members_diff(T,M,Result,details::differentiate_option::curl) \
646template void field_expr_v2_nonlinear_terminal_field_o_characteristic_rep<T,M>::evaluate ( \
647 const geo_basic<float_type,memory_type>& omega_K, \
648 const geo_element& K, \
649 Eigen::Matrix<Result,Eigen::Dynamic,1>& value) const; \
650template void field_expr_v2_nonlinear_terminal_field_dg_rep<T,M>::evaluate ( \
651 const geo_basic<float_type,memory_type>& omega_K, \
652 const geo_element& K, \
653 Eigen::Matrix<Result,Eigen::Dynamic,1>& value) const; \
654
655#define _RHEOLEF_instanciation_base_both(T,M) \
656template const geo_element& global_get_side ( \
657 const geo_basic<T,M>&, const geo_element&, const side_information_type&); \
658template const geo_element& field_expr_v2_nonlinear_terminal_function_base_rep<T>::get_side ( \
659 const geo_basic<T,M>& omega_L, \
660 const geo_element& L, \
661 const side_information_type& sid) const; \
662template class field_expr_v2_nonlinear_terminal_field_rep<T,M,details::differentiate_option::none>; \
663template class field_expr_v2_nonlinear_terminal_field_rep<T,M,details::differentiate_option::gradient>; \
664template class field_expr_v2_nonlinear_terminal_field_rep<T,M,details::differentiate_option::divergence>; \
665template class field_expr_v2_nonlinear_terminal_field_rep<T,M,details::differentiate_option::curl>; \
666template class field_expr_v2_nonlinear_terminal_field_dg_rep<T,M>; \
667template class field_expr_v2_nonlinear_terminal_field_o_characteristic_rep<T,M>; \
668 _RHEOLEF_instanciation_base_both_members_alls(T,M,T) \
669 _RHEOLEF_instanciation_base_both_members_alls(T,M,point_basic<T>) \
670 _RHEOLEF_instanciation_base_both_members_alls(T,M,tensor_basic<T>) \
671 _RHEOLEF_instanciation_base_both_members_alls(T,M,tensor3_basic<T>) \
672 _RHEOLEF_instanciation_base_both_members_alls(T,M,tensor4_basic<T>) \
673
674#define _RHEOLEF_instanciation_seq(T) \
675 _RHEOLEF_instanciation_base_seq_only(T) \
676 _RHEOLEF_instanciation_base_both(T,sequential) \
677
678#define _RHEOLEF_instanciation_dis(T) \
679 _RHEOLEF_instanciation_base_both(T,distributed) \
680
682#ifdef _RHEOLEF_HAVE_MPI
684#endif // _RHEOLEF_HAVE_MPI
685
686}} // namespace rheolef::details
field::size_type size_type
Definition branch.cc:430
see the Float page for the full documentation
void initialize(const piola_on_pointset< float_type > &pops, const integrate_option &iopt)
void evaluate(const geo_basic< float_type, memory_type > &omega_K, const geo_element &K, Eigen::Matrix< Value, Eigen::Dynamic, 1 > &value) const
void initialize(const piola_on_pointset< float_type > &pops, const integrate_option &iopt)
void evaluate(const geo_basic< float_type, memory_type > &omega_K, const geo_element &K, Eigen::Matrix< Value, Eigen::Dynamic, 1 > &value) const
void initialize(const piola_on_pointset< T > &pops, const integrate_option &iopt)
void evaluate(const geo_basic< float_type, memory_type > &omega_K, const geo_element &K, Eigen::Matrix< Value, Eigen::Dynamic, 1 > &value) const
void evaluate_on_side(const geo_basic< float_type, memory_type > &omega_L, const geo_element &L, const side_information_type &sid, Eigen::Matrix< Value, Eigen::Dynamic, 1 > &value) const
void initialize(const piola_on_pointset< float_type > &pops, const integrate_option &iopt)
const geo_element & get_side(const geo_basic< float_type, M > &omega_K, const geo_element &K, const side_information_type &sid) const
see the disarray page for the full documentation
Definition disarray.h:497
rep::base::const_iterator const_iterator
Definition disarray.h:503
abstract base interface class
Definition geo.h:248
generic mesh with rerefence counting
Definition geo.h:1089
see the geo_element page for the full documentation
reference_element::size_type size_type
size_type dimension() const
size_type master(bool i) const
variant_type variant() const
orientation_type get_side_informations(const geo_element &S, size_type &loc_isid, size_type &shift) const
size_type dis_ie() const
see the integrate_option page for the full documentation
see the reference_element page for the full documentation
the finite element space
Definition space.h:382
#define trace_macro(message)
Definition dis_macros.h:111
#define error_macro(message)
Definition dis_macros.h:49
#define fatal_macro(message)
Definition dis_macros.h:33
const Float measure
Definition edge.icc:65
Expr1::float_type T
Definition field_expr.h:230
check_macro(expr1.have_homogeneous_space(Xh1), "dual(expr1,expr2); expr1 should have homogeneous space. HINT: use dual(interpolate(Xh, expr1),expr2)")
#define _RHEOLEF_instanciation_seq(T)
#define _RHEOLEF_instanciation_dis(T)
const geo_element & global_get_side(const geo_basic< T, M > &omega_L, const geo_element &L, const side_information_type &sid)
void interpolate_pass2_valued(const field_basic< T, M > &uh, const disarray< point_basic< T >, M > &x, const disarray< index_set, M > &ie2dis_ix, const disarray< point_basic< T >, M > &hat_y, disarray< Value, M > &ux)
This file is part of Rheolef.
point_basic< T > normal_from_piola_transformation(const geo_basic< T, M > &omega, const geo_element &S, const tensor_basic< T > &DF, size_t d)
void initialize(const piola_on_pointset< float_type > &pops, const integrate_option &iopt)
space_mult_list< T, M > pow(const space_basic< T, M > &X, size_t n)
Definition space_mult.h:120
void field_evaluate_continued(const field_basic< T, M > &uh, const geo_basic< T, M > &omega_K, const geo_element &K, const Eigen::Matrix< Value, Eigen::Dynamic, Eigen::Dynamic > &phij_xi, Eigen::Matrix< Value, Eigen::Dynamic, 1 > &value)
void evaluate(const geo_basic< float_type, M > &omega_K, const geo_element &K, Eigen::Matrix< Result, Eigen::Dynamic, 1 > &value) const
T det_jacobian_piola_transformation(const tensor_basic< T > &DF, size_t d, size_t map_d)
void evaluate_on_side(const geo_basic< float_type, M > &omega_K, const geo_element &K, const side_information_type &sid, Eigen::Matrix< Result, Eigen::Dynamic, 1 > &value) const
T norm(const vec< T, M > &x)
norm(x): see the expression page for the full documentation
Definition vec.h:387
disarray< point_basic< T >, M > _hat_y
disarray< point_basic< T >, M > _yq
point_basic< T > F
Definition piola.h:79
geo_element_indirect::orientation_type orient
Expr1::memory_type M