mesh_function.C
Go to the documentation of this file.
1 // The libMesh Finite Element Library.
2 // Copyright (C) 2002-2018 Benjamin S. Kirk, John W. Peterson, Roy H. Stogner
3 
4 // This library is free software; you can redistribute it and/or
5 // modify it under the terms of the GNU Lesser General Public
6 // License as published by the Free Software Foundation; either
7 // version 2.1 of the License, or (at your option) any later version.
8 
9 // This library is distributed in the hope that it will be useful,
10 // but WITHOUT ANY WARRANTY; without even the implied warranty of
11 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 // Lesser General Public License for more details.
13 
14 // You should have received a copy of the GNU Lesser General Public
15 // License along with this library; if not, write to the Free Software
16 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17 
18 
19 
20 // C++ includes
21 
22 
23 // Local Includes
24 #include "libmesh/mesh_function.h"
25 #include "libmesh/dense_vector.h"
27 #include "libmesh/numeric_vector.h"
28 #include "libmesh/dof_map.h"
30 #include "libmesh/fe_base.h"
31 #include "libmesh/fe_interface.h"
33 #include "libmesh/mesh_base.h"
34 #include "libmesh/point.h"
35 #include "libmesh/elem.h"
36 
37 namespace libMesh
38 {
39 
40 
41 //------------------------------------------------------------------
42 // MeshFunction methods
44  const NumericVector<Number> & vec,
45  const DofMap & dof_map,
46  const std::vector<unsigned int> & vars,
47  const FunctionBase<Number> * master) :
48  FunctionBase<Number> (master),
49  ParallelObject (eqn_systems),
50  _eqn_systems (eqn_systems),
51  _vector (vec),
52  _dof_map (dof_map),
53  _system_vars (vars),
54  _point_locator (nullptr),
55  _out_of_mesh_mode (false),
56  _out_of_mesh_value ()
57 {
58 }
59 
60 
61 
63  const NumericVector<Number> & vec,
64  const DofMap & dof_map,
65  const unsigned int var,
66  const FunctionBase<Number> * master) :
67  FunctionBase<Number> (master),
68  ParallelObject (eqn_systems),
69  _eqn_systems (eqn_systems),
70  _vector (vec),
71  _dof_map (dof_map),
72  _system_vars (1,var),
73  _point_locator (nullptr),
74  _out_of_mesh_mode (false),
75  _out_of_mesh_value ()
76 {
77  // std::vector<unsigned int> buf (1);
78  // buf[0] = var;
79  // _system_vars (buf);
80 }
81 
82 
83 
84 
85 
86 
87 
89 {
90  // only delete the point locator when we are the master
91  if (this->_master == nullptr)
92  delete this->_point_locator;
93 }
94 
95 
96 
97 
98 void MeshFunction::init (const Trees::BuildType /*point_locator_build_type*/)
99 {
100  // are indices of the desired variable(s) provided?
101  libmesh_assert_greater (this->_system_vars.size(), 0);
102 
103  // Don't do twice...
104  if (this->_initialized)
105  {
106  libmesh_assert(this->_point_locator);
107  return;
108  }
109 
110  /*
111  * set up the PointLocator: either someone else
112  * is the master (go and get the address of his
113  * point locator) or this object is the master
114  * (build the point locator on our own).
115  */
116  if (this->_master != nullptr)
117  {
118  // we aren't the master
119  const MeshFunction * master =
120  cast_ptr<const MeshFunction *>(this->_master);
121 
122  if (master->_point_locator == nullptr)
123  libmesh_error_msg("ERROR: When the master-servant concept is used, the master has to be initialized first!");
124 
125  else
126  {
127  this->_point_locator = master->_point_locator;
128  }
129  }
130  else
131  {
132  // we are the master: build the point locator
133 
134  // constant reference to the other mesh
135  const MeshBase & mesh = this->_eqn_systems.get_mesh();
136 
137  // Get PointLocator object from the Mesh. We are responsible for
138  // deleting this only if we are the master.
139  this->_point_locator = mesh.sub_point_locator().release();
140  }
141 
142  // ready for use
143  this->_initialized = true;
144 }
145 
146 
147 void
149 {
150  // only delete the point locator when we are the master
151  if ((this->_point_locator != nullptr) && (this->_master == nullptr))
152  {
153  delete this->_point_locator;
154  this->_point_locator = nullptr;
155  }
156  this->_initialized = false;
157 }
158 
159 
160 
161 std::unique_ptr<FunctionBase<Number>> MeshFunction::clone () const
162 {
163  FunctionBase<Number> * mf_clone =
165 
166  if (this->initialized())
167  mf_clone->init();
168 
169  return std::unique_ptr<FunctionBase<Number>>(mf_clone);
170 }
171 
172 
173 
175  const Real time)
176 {
177  libmesh_assert (this->initialized());
178 
179  DenseVector<Number> buf (1);
180  this->operator() (p, time, buf);
181  return buf(0);
182 }
183 
184 std::map<const Elem *, Number> MeshFunction::discontinuous_value (const Point & p,
185  const Real time)
186 {
187  libmesh_assert (this->initialized());
188 
189  std::map<const Elem *, DenseVector<Number>> buffer;
190  this->discontinuous_value (p, time, buffer);
191  std::map<const Elem *, Number> return_value;
192  for (const auto & pr : buffer)
193  return_value[pr.first] = pr.second(0);
194  // NOTE: If no suitable element is found, then the map return_value is empty. This
195  // puts burden on the user of this function but I don't really see a better way.
196  return return_value;
197 }
198 
200  const Real time)
201 {
202  libmesh_assert (this->initialized());
203 
204  std::vector<Gradient> buf (1);
205  this->gradient(p, time, buf);
206  return buf[0];
207 }
208 
209 std::map<const Elem *, Gradient> MeshFunction::discontinuous_gradient (const Point & p,
210  const Real time)
211 {
212  libmesh_assert (this->initialized());
213 
214  std::map<const Elem *, std::vector<Gradient>> buffer;
215  this->discontinuous_gradient (p, time, buffer);
216  std::map<const Elem *, Gradient> return_value;
217  for (const auto & pr : buffer)
218  return_value[pr.first] = pr.second[0];
219  // NOTE: If no suitable element is found, then the map return_value is empty. This
220  // puts burden on the user of this function but I don't really see a better way.
221  return return_value;
222 }
223 
224 #ifdef LIBMESH_ENABLE_SECOND_DERIVATIVES
226  const Real time)
227 {
228  libmesh_assert (this->initialized());
229 
230  std::vector<Tensor> buf (1);
231  this->hessian(p, time, buf);
232  return buf[0];
233 }
234 #endif
235 
237  const Real time,
238  DenseVector<Number> & output)
239 {
240  this->operator() (p, time, output, nullptr);
241 }
242 
244  const Real,
245  DenseVector<Number> & output,
246  const std::set<subdomain_id_type> * subdomain_ids)
247 {
248  libmesh_assert (this->initialized());
249 
250  const Elem * element = this->find_element(p,subdomain_ids);
251 
252  if (!element)
253  {
254  // We'd better be in out_of_mesh_mode if we couldn't find an
255  // element in the mesh
256  libmesh_assert (_out_of_mesh_mode);
257  output = _out_of_mesh_value;
258  }
259  else
260  {
261  // resize the output vector to the number of output values
262  // that the user told us
263  output.resize (cast_int<unsigned int>
264  (this->_system_vars.size()));
265 
266 
267  {
268  const unsigned int dim = element->dim();
269 
270 
271  /*
272  * Get local coordinates to feed these into compute_data().
273  * Note that the fe_type can safely be used from the 0-variable,
274  * since the inverse mapping is the same for all FEFamilies
275  */
276  const Point mapped_point (FEInterface::inverse_map (dim,
277  this->_dof_map.variable_type(0),
278  element,
279  p));
280 
281 
282  // loop over all vars
283  for (unsigned int index=0,
284  sz = cast_int<unsigned int>(this->_system_vars.size());
285  index != sz; ++index)
286  {
287  /*
288  * the data for this variable
289  */
290  const unsigned int var = _system_vars[index];
291 
292  if (var == libMesh::invalid_uint)
293  {
294  libmesh_assert (_out_of_mesh_mode &&
295  index < _out_of_mesh_value.size());
296  output(index) = _out_of_mesh_value(index);
297  continue;
298  }
299 
300  const FEType & fe_type = this->_dof_map.variable_type(var);
301 
306  {
307  FEComputeData data (this->_eqn_systems, mapped_point);
308 
309  FEInterface::compute_data (dim, fe_type, element, data);
310 
311  // where the solution values for the var-th variable are stored
312  std::vector<dof_id_type> dof_indices;
313  this->_dof_map.dof_indices (element, dof_indices, var);
314 
315  // interpolate the solution
316  {
317  Number value = 0.;
318 
319  for (std::size_t i=0; i<dof_indices.size(); i++)
320  value += this->_vector(dof_indices[i]) * data.shape[i];
321 
322  output(index) = value;
323  }
324 
325  }
326 
327  // next variable
328  }
329  }
330  }
331 }
332 
333 
335  const Real time,
336  std::map<const Elem *, DenseVector<Number>> & output)
337 {
338  this->discontinuous_value (p, time, output, nullptr);
339 }
340 
341 
342 
344  const Real,
345  std::map<const Elem *, DenseVector<Number>> & output,
346  const std::set<subdomain_id_type> * subdomain_ids)
347 {
348  libmesh_assert (this->initialized());
349 
350  // clear the output map
351  output.clear();
352 
353  // get the candidate elements
354  std::set<const Elem *> candidate_element = this->find_elements(p,subdomain_ids);
355 
356  // loop through all candidates, if the set is empty this function will return an
357  // empty map
358  for (const auto & element : candidate_element)
359  {
360  const unsigned int dim = element->dim();
361 
362  // define a temporary vector to store all values
363  DenseVector<Number> temp_output (cast_int<unsigned int>(this->_system_vars.size()));
364 
365  /*
366  * Get local coordinates to feed these into compute_data().
367  * Note that the fe_type can safely be used from the 0-variable,
368  * since the inverse mapping is the same for all FEFamilies
369  */
370  const Point mapped_point (FEInterface::inverse_map (dim,
371  this->_dof_map.variable_type(0),
372  element,
373  p));
374 
375 
376  // loop over all vars
377  for (unsigned int index=0,
378  sz = cast_int<unsigned int>(this->_system_vars.size());
379  index != sz; ++index)
380  {
381  /*
382  * the data for this variable
383  */
384  const unsigned int var = _system_vars[index];
385 
386  if (var == libMesh::invalid_uint)
387  {
388  libmesh_assert (_out_of_mesh_mode &&
389  index < _out_of_mesh_value.size());
390  temp_output(index) = _out_of_mesh_value(index);
391  continue;
392  }
393 
394  const FEType & fe_type = this->_dof_map.variable_type(var);
395 
400  {
401  FEComputeData data (this->_eqn_systems, mapped_point);
402 
403  FEInterface::compute_data (dim, fe_type, element, data);
404 
405  // where the solution values for the var-th variable are stored
406  std::vector<dof_id_type> dof_indices;
407  this->_dof_map.dof_indices (element, dof_indices, var);
408 
409  // interpolate the solution
410  {
411  Number value = 0.;
412 
413  for (std::size_t i=0; i<dof_indices.size(); i++)
414  value += this->_vector(dof_indices[i]) * data.shape[i];
415 
416  temp_output(index) = value;
417  }
418 
419  }
420 
421  // next variable
422  }
423 
424  // Insert temp_output into output
425  output[element] = temp_output;
426  }
427 }
428 
429 
430 
432  const Real,
433  std::vector<Gradient> & output,
434  const std::set<subdomain_id_type> * subdomain_ids)
435 {
436  libmesh_assert (this->initialized());
437 
438  const Elem * element = this->find_element(p,subdomain_ids);
439 
440  if (!element)
441  {
442  output.resize(0);
443  }
444  else
445  {
446  // resize the output vector to the number of output values
447  // that the user told us
448  output.resize (this->_system_vars.size());
449 
450 
451  {
452  const unsigned int dim = element->dim();
453 
454 
455  /*
456  * Get local coordinates to feed these into compute_data().
457  * Note that the fe_type can safely be used from the 0-variable,
458  * since the inverse mapping is the same for all FEFamilies
459  */
460  const Point mapped_point (FEInterface::inverse_map (dim,
461  this->_dof_map.variable_type(0),
462  element,
463  p));
464 
465  std::vector<Point> point_list (1, mapped_point);
466 
467  // loop over all vars
468  for (unsigned int index=0,
469  sz = cast_int<unsigned int>(this->_system_vars.size());
470  index != sz; ++index)
471  {
472  /*
473  * the data for this variable
474  */
475  const unsigned int var = _system_vars[index];
476 
477  if (var == libMesh::invalid_uint)
478  {
479  libmesh_assert (_out_of_mesh_mode &&
480  index < _out_of_mesh_value.size());
481  output[index] = Gradient(_out_of_mesh_value(index));
482  continue;
483  }
484 
485  const FEType & fe_type = this->_dof_map.variable_type(var);
486 
487  std::unique_ptr<FEBase> point_fe (FEBase::build(dim, fe_type));
488  const std::vector<std::vector<RealGradient>> & dphi = point_fe->get_dphi();
489  point_fe->reinit(element, &point_list);
490 
491  // where the solution values for the var-th variable are stored
492  std::vector<dof_id_type> dof_indices;
493  this->_dof_map.dof_indices (element, dof_indices, var);
494 
495  // interpolate the solution
496  Gradient grad(0.);
497 
498  for (std::size_t i=0; i<dof_indices.size(); i++)
499  grad.add_scaled(dphi[i][0], this->_vector(dof_indices[i]));
500 
501  output[index] = grad;
502  }
503  }
504  }
505 }
506 
507 
509  const Real time,
510  std::map<const Elem *, std::vector<Gradient>> & output)
511 {
512  this->discontinuous_gradient (p, time, output, nullptr);
513 }
514 
515 
516 
518  const Real,
519  std::map<const Elem *, std::vector<Gradient>> & output,
520  const std::set<subdomain_id_type> * subdomain_ids)
521 {
522  libmesh_assert (this->initialized());
523 
524  // clear the output map
525  output.clear();
526 
527  // get the candidate elements
528  std::set<const Elem *> candidate_element = this->find_elements(p,subdomain_ids);
529 
530  // loop through all candidates, if the set is empty this function will return an
531  // empty map
532  for (const auto & element : candidate_element)
533  {
534  const unsigned int dim = element->dim();
535 
536  // define a temporary vector to store all values
537  std::vector<Gradient> temp_output (cast_int<unsigned int>(this->_system_vars.size()));
538 
539  /*
540  * Get local coordinates to feed these into compute_data().
541  * Note that the fe_type can safely be used from the 0-variable,
542  * since the inverse mapping is the same for all FEFamilies
543  */
544  const Point mapped_point (FEInterface::inverse_map (dim,
545  this->_dof_map.variable_type(0),
546  element,
547  p));
548 
549 
550  // loop over all vars
551  std::vector<Point> point_list (1, mapped_point);
552  for (unsigned int index=0,
553  sz = cast_int<unsigned int>(this->_system_vars.size());
554  index != sz; ++index)
555  {
556  /*
557  * the data for this variable
558  */
559  const unsigned int var = _system_vars[index];
560 
561  if (var == libMesh::invalid_uint)
562  {
563  libmesh_assert (_out_of_mesh_mode &&
564  index < _out_of_mesh_value.size());
565  temp_output[index] = Gradient(_out_of_mesh_value(index));
566  continue;
567  }
568 
569  const FEType & fe_type = this->_dof_map.variable_type(var);
570 
571  std::unique_ptr<FEBase> point_fe (FEBase::build(dim, fe_type));
572  const std::vector<std::vector<RealGradient>> & dphi = point_fe->get_dphi();
573  point_fe->reinit(element, &point_list);
574 
575  // where the solution values for the var-th variable are stored
576  std::vector<dof_id_type> dof_indices;
577  this->_dof_map.dof_indices (element, dof_indices, var);
578 
579  Gradient grad(0.);
580 
581  for (std::size_t i = 0; i < dof_indices.size(); ++i)
582  grad.add_scaled(dphi[i][0], this->_vector(dof_indices[i]));
583 
584  temp_output[index] = grad;
585 
586  // next variable
587  }
588 
589  // Insert temp_output into output
590  output[element] = temp_output;
591  }
592 }
593 
594 
595 
596 #ifdef LIBMESH_ENABLE_SECOND_DERIVATIVES
597 void MeshFunction::hessian (const Point & p,
598  const Real,
599  std::vector<Tensor> & output,
600  const std::set<subdomain_id_type> * subdomain_ids)
601 {
602  libmesh_assert (this->initialized());
603 
604  const Elem * element = this->find_element(p,subdomain_ids);
605 
606  if (!element)
607  {
608  output.resize(0);
609  }
610  else
611  {
612  // resize the output vector to the number of output values
613  // that the user told us
614  output.resize (this->_system_vars.size());
615 
616 
617  {
618  const unsigned int dim = element->dim();
619 
620 
621  /*
622  * Get local coordinates to feed these into compute_data().
623  * Note that the fe_type can safely be used from the 0-variable,
624  * since the inverse mapping is the same for all FEFamilies
625  */
626  const Point mapped_point (FEInterface::inverse_map (dim,
627  this->_dof_map.variable_type(0),
628  element,
629  p));
630 
631  std::vector<Point> point_list (1, mapped_point);
632 
633  // loop over all vars
634  for (unsigned int index=0,
635  sz = cast_int<unsigned int>(this->_system_vars.size());
636  index != sz; ++index)
637  {
638  /*
639  * the data for this variable
640  */
641  const unsigned int var = _system_vars[index];
642 
643  if (var == libMesh::invalid_uint)
644  {
645  libmesh_assert (_out_of_mesh_mode &&
646  index < _out_of_mesh_value.size());
647  output[index] = Tensor(_out_of_mesh_value(index));
648  continue;
649  }
650  const FEType & fe_type = this->_dof_map.variable_type(var);
651 
652  std::unique_ptr<FEBase> point_fe (FEBase::build(dim, fe_type));
653  const std::vector<std::vector<RealTensor>> & d2phi =
654  point_fe->get_d2phi();
655  point_fe->reinit(element, &point_list);
656 
657  // where the solution values for the var-th variable are stored
658  std::vector<dof_id_type> dof_indices;
659  this->_dof_map.dof_indices (element, dof_indices, var);
660 
661  // interpolate the solution
662  Tensor hess;
663 
664  for (std::size_t i=0; i<dof_indices.size(); i++)
665  hess.add_scaled(d2phi[i][0], this->_vector(dof_indices[i]));
666 
667  output[index] = hess;
668  }
669  }
670  }
671 }
672 #endif
673 
675  const std::set<subdomain_id_type> * subdomain_ids) const
676 {
677  /* Ensure that in the case of a master mesh function, the
678  out-of-mesh mode is enabled either for both or for none. This is
679  important because the out-of-mesh mode is also communicated to
680  the point locator. Since this is time consuming, enable it only
681  in debug mode. */
682 #ifdef DEBUG
683  if (this->_master != nullptr)
684  {
685  const MeshFunction * master =
686  cast_ptr<const MeshFunction *>(this->_master);
688  libmesh_error_msg("ERROR: If you use out-of-mesh-mode in connection with master mesh " \
689  << "functions, you must enable out-of-mesh mode for both the master and the slave mesh function.");
690  }
691 #endif
692 
693  // locate the point in the other mesh
694  const Elem * element = this->_point_locator->operator()(p,subdomain_ids);
695 
696  // If we have an element, but it's not a local element, then we
697  // either need to have a serialized vector or we need to find a
698  // local element sharing the same point.
699  if (element &&
700  (element->processor_id() != this->processor_id()) &&
701  _vector.type() != SERIAL)
702  {
703  // look for a local element containing the point
704  std::set<const Elem *> point_neighbors;
705  element->find_point_neighbors(p, point_neighbors);
706  element = nullptr;
707  for (const auto & elem : point_neighbors)
708  if (elem->processor_id() == this->processor_id())
709  {
710  element = elem;
711  break;
712  }
713  }
714 
715  return element;
716 }
717 
718 std::set<const Elem *> MeshFunction::find_elements(const Point & p,
719  const std::set<subdomain_id_type> * subdomain_ids) const
720 {
721  /* Ensure that in the case of a master mesh function, the
722  out-of-mesh mode is enabled either for both or for none. This is
723  important because the out-of-mesh mode is also communicated to
724  the point locator. Since this is time consuming, enable it only
725  in debug mode. */
726 #ifdef DEBUG
727  if (this->_master != nullptr)
728  {
729  const MeshFunction * master =
730  cast_ptr<const MeshFunction *>(this->_master);
732  libmesh_error_msg("ERROR: If you use out-of-mesh-mode in connection with master mesh " \
733  << "functions, you must enable out-of-mesh mode for both the master and the slave mesh function.");
734  }
735 #endif
736 
737  // locate the point in the other mesh
738  std::set<const Elem *> candidate_elements;
739  std::set<const Elem *> final_candidate_elements;
740  this->_point_locator->operator()(p,candidate_elements,subdomain_ids);
741  for (const auto & element : candidate_elements)
742  {
743  // If we have an element, but it's not a local element, then we
744  // either need to have a serialized vector or we need to find a
745  // local element sharing the same point.
746  if (element &&
747  (element->processor_id() != this->processor_id()) &&
748  _vector.type() != SERIAL)
749  {
750  // look for a local element containing the point
751  std::set<const Elem *> point_neighbors;
752  element->find_point_neighbors(p, point_neighbors);
753  for (const auto & elem : point_neighbors)
754  if (elem->processor_id() == this->processor_id())
755  {
756  final_candidate_elements.insert(elem);
757  break;
758  }
759  }
760  else
761  final_candidate_elements.insert(element);
762  }
763 
764  return final_candidate_elements;
765 }
766 
768 {
769  libmesh_assert (this->initialized());
770  return *_point_locator;
771 }
772 
774 {
775  libmesh_assert (this->initialized());
777  _out_of_mesh_mode = true;
779 }
780 
782 {
783  DenseVector<Number> v(1);
784  v(0) = value;
785  this->enable_out_of_mesh_mode(v);
786 }
787 
789 {
790  libmesh_assert (this->initialized());
792  _out_of_mesh_mode = false;
793 }
794 
796 {
798 }
799 
801 {
803 }
804 
805 } // namespace libMesh
Manages the family, order, etc. parameters for a given FE.
Definition: fe_type.h:179
virtual unsigned int size() const override
Definition: dense_vector.h:92
virtual void disable_out_of_mesh_mode()=0
Manages multiples systems of equations.
const EquationSystems & _eqn_systems
virtual std::unique_ptr< FunctionBase< Number > > clone() const override
const NumericVector< Number > & _vector
const unsigned int invalid_uint
Definition: libmesh.h:245
virtual void set_close_to_point_tol(Real close_to_point_tol)
std::unique_ptr< PointLocatorBase > sub_point_locator() const
Definition: mesh_base.C:496
PointLocatorBase * _point_locator
void dof_indices(const Elem *const elem, std::vector< dof_id_type > &di) const
Definition: dof_map.C:1930
void add_scaled(const TypeTensor< T2 > &, const T)
Definition: type_tensor.h:808
void add_scaled(const TypeVector< T2 > &, const T)
Definition: type_vector.h:627
Helper class used with FEInterface::compute_data().
MeshFunction(const EquationSystems &eqn_systems, const NumericVector< Number > &vec, const DofMap &dof_map, const std::vector< unsigned int > &vars, const FunctionBase< Number > *master=nullptr)
Definition: mesh_function.C:43
const DofMap & _dof_map
void resize(const unsigned int n)
Definition: dense_vector.h:355
const Elem * find_element(const Point &p, const std::set< subdomain_id_type > *subdomain_ids=nullptr) const
const FEType & variable_type(const unsigned int c) const
Definition: dof_map.h:1792
The base class for all geometric element types.
Definition: elem.h:100
MeshBase & mesh
const FunctionBase * _master
Gradient gradient(const Point &p, const Real time=0.)
virtual void init()
Definition: function_base.h:87
void disable_out_of_mesh_mode(void)
Base class for Mesh.
Definition: mesh_base.h:77
Manages the degrees of freedom (DOFs) in a simulation.
Definition: dof_map.h:176
DenseVector< Number > _out_of_mesh_value
void enable_out_of_mesh_mode(const DenseVector< Number > &value)
virtual void clear() override
std::set< const Elem * > find_elements(const Point &p, const std::set< subdomain_id_type > *subdomain_ids=nullptr) const
std::map< const Elem *, Number > discontinuous_value(const Point &p, const Real time=0.)
void find_point_neighbors(const Point &p, std::set< const Elem *> &neighbor_set) const
Definition: elem.C:498
static void compute_data(const unsigned int dim, const FEType &fe_t, const Elem *elem, FEComputeData &data)
Definition: fe_interface.C:837
NumberVectorValue Gradient
void unset_point_locator_tolerance()
static std::unique_ptr< FEGenericBase > build(const unsigned int dim, const FEType &type)
static Point inverse_map(const unsigned int dim, const FEType &fe_t, const Elem *elem, const Point &p, const Real tolerance=TOLERANCE, const bool secure=true)
Definition: fe_interface.C:590
An object whose state is distributed along a set of processors.
ParallelType type() const
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
const PointLocatorBase & get_point_locator(void) const
NumberTensorValue Tensor
virtual unsigned short dim() const =0
Number operator()(const Point &p, const Real time=0.) override
const MeshBase & get_mesh() const
static const bool value
Definition: xdr_io.C:109
BuildType
Base class for different Tree types.
Definition: tree_base.h:55
virtual void unset_close_to_point_tol()
void set_point_locator_tolerance(Real tol)
IterBase * data
virtual void enable_out_of_mesh_mode()=0
processor_id_type processor_id() const
processor_id_type processor_id() const
Definition: dof_object.h:717
std::map< const Elem *, Gradient > discontinuous_gradient(const Point &p, const Real time=0.)
A geometric point in (x,y,z) space.
Definition: point.h:38
Tensor hessian(const Point &p, const Real time=0.)
virtual void init() override
const std::vector< unsigned int > _system_vars