element_with_external_element.h
Go to the documentation of this file.
1 //LIC// ====================================================================
2 //LIC// This file forms part of oomph-lib, the object-oriented,
3 //LIC// multi-physics finite-element library, available
4 //LIC// at http://www.oomph-lib.org.
5 //LIC//
6 //LIC// Version 1.0; svn revision $LastChangedRevision$
7 //LIC//
8 //LIC// $LastChangedDate$
9 //LIC//
10 //LIC// Copyright (C) 2006-2016 Matthias Heil and Andrew Hazel
11 //LIC//
12 //LIC// This library is free software; you can redistribute it and/or
13 //LIC// modify it under the terms of the GNU Lesser General Public
14 //LIC// License as published by the Free Software Foundation; either
15 //LIC// version 2.1 of the License, or (at your option) any later version.
16 //LIC//
17 //LIC// This library is distributed in the hope that it will be useful,
18 //LIC// but WITHOUT ANY WARRANTY; without even the implied warranty of
19 //LIC// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
20 //LIC// Lesser General Public License for more details.
21 //LIC//
22 //LIC// You should have received a copy of the GNU Lesser General Public
23 //LIC// License along with this library; if not, write to the Free Software
24 //LIC// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
25 //LIC// 02110-1301 USA.
26 //LIC//
27 //LIC// The authors may be contacted at oomph-lib@maths.man.ac.uk.
28 //LIC//
29 //LIC//====================================================================
30 //Header file for the class
31 //ElementWithExternalElement which stores pointers to external elements
32 
33 //Include guards to prevent multiple inclusion of the header
34 #ifndef OOMPH_ELEMENT_WITH_EXTERNAL_ELEMENT_HEADER
35 #define OOMPH_ELEMENT_WITH_EXTERNAL_ELEMENT_HEADER
36 
37 // Config header generated by autoconfig
38 #ifdef HAVE_CONFIG_H
39 #include <oomph-lib-config.h>
40 #endif
41 
42 //Oomph-lib headers
43 #include "elements.h"
44 
45 namespace oomph
46 {
47 //========================================================================
48 /// This is a base class for all elements that require external sources
49 /// (e.g. FSI, multi-domain problems such as Helmholtz, multi-mesh
50 /// Boussinesq convection, etc.). It provides storage for the source
51 /// element and corresponding local coordinate at each integration point,
52 /// and allows use of locate_zeta to obtain such source elements. In
53 /// addition separate storage is allocated for all field data in the
54 /// external elements and all geometric data that can affect the field
55 /// data in the external elements. Generic finite difference routines
56 /// are provided to calculate entries in the Jacobian from the data
57 /// of the external elements.
58 //========================================================================
60  {
61  public:
62 
63  /// \short Constructor. Initialise member data and pointers to data
64  /// associated with the external elements to zero.
70  Ninteraction(0),
71  Nintpt(0),
81  { }
82 
83  /// \short The destructor, clean up any allocated memory
85 
86  /// Broken copy constructor
88  {
89  BrokenCopy::broken_copy("ElementWithExternalElement");
90  }
91 
92  /// Broken assignment operator
94  {
95  BrokenCopy::broken_assign("ElementWithExternalElement");
96  }
97 
98 
99  /// \short Helper function to check if storage has actually been allocated
101  {
102  //If either of the storage arrays is zero, then storage has not
103  //yet been allocated. Both arrays are allocated at once, so
104  //if one is zero both will (should) be
106  {
107  return false;
108  }
109  else
110  {
111  return true;
112  }
113  }
114 
115  /// \short Access function to source element for specified interaction
116  /// index at specified integration point
117  FiniteElement*& external_element_pt(const unsigned &interaction_index,
118  const unsigned &ipt)
119  {
120 #ifdef PARANOID
122 #endif
123 #ifdef RANGE_CHECKING
124  range_check(interaction_index,ipt);
125 #endif
126  //Return the appropriate entry in the storage array
127  return External_element_pt[Nintpt*interaction_index + ipt];
128  }
129 
130  /// \short Access function to source element, const version
131  FiniteElement* const &external_element_pt(const unsigned &interaction_index,
132  const unsigned &ipt) const
133  {
134 #ifdef PARANOID
136 #endif
137 #ifdef RANGE_CHECKING
138  range_check(interaction_index,ipt);
139 #endif
140  //Return the appropriate entry in the storage array
141  return External_element_pt[Nintpt*interaction_index + ipt];
142  }
143 
144  /// \short Access function to get source element's local coords for
145  /// specified interaction index at specified integration point
147  const unsigned &interaction_index,
148  const unsigned &ipt)
149  {
150 #ifdef PARANOID
152 #endif
153 #ifdef RANGE_CHECKING
154  range_check(interaction_index,ipt);
155 #endif
156  return External_element_local_coord[Nintpt*interaction_index + ipt];
157  }
158 
159  /// \short Access function to get source element's coords, const version
161  (const unsigned &interaction_index, const unsigned &ipt) const
162  {
163 #ifdef PARANOID
165 #endif
166 #ifdef RANGE_CHECKING
167  range_check(interaction_index,ipt);
168 #endif
169  return External_element_local_coord[Nintpt*interaction_index + ipt];
170  }
171 
172 
173  /// \short Output by plotting vector from integration point to
174  /// corresponding point in external element for specified interaction
175  /// index
176  void output_external_elements(std::ostream &outfile,
177  const unsigned &interaction_index);
178 
179  /// \short Initialise storage for pointers to external elements and their
180  /// local coordinates. This must be called before any of
181  /// the access functions are used.
183 
184  /// \short Flush the storage for external elements
186 
187  /// \short Set the number of interactions in the element
188  /// This function is usually called in the specific element's constructor
189  inline void set_ninteraction(const unsigned &n_interaction)
190  {Ninteraction = n_interaction;}
191 
192  /// \short Return the number of interactions in the element
193  unsigned ninteraction() const {return Ninteraction;}
194 
195  /// \short Function that must return all the data involved
196  /// in the desired interactions from the external element
198  Vector<std::set<FiniteElement*> > const &external_elements_pt,
199  std::set<std::pair<Data*,unsigned> > &paired_interaction_data);
200 
201  /// \short Function that must return all geometric data involved
202  /// in the desired interactions from the external element
204  Vector<std::set<FiniteElement*> > const &external_elements_pt,
205  std::set<Data*> &external_geometric_data_pt);
206 
207  /// \short Return the number of Data items that affect the
208  /// external interactions in this element.
209  /// This includes e.g. fluid velocities
210  /// and pressures in adjacent fluid elements in an FSI problem
213 
214  /// \short Return vector of pointers to the field Data objects that
215  /// affect the interactions on the element.
217  {
218  //Find out how many external field data there are
219  const unsigned n_external_interaction_field_data =
221  //Create and populate a temporary vector
222  Vector<Data*> temp_data(n_external_interaction_field_data);
223  for(unsigned i=0;i<n_external_interaction_field_data;i++)
224  {temp_data[i] = External_interaction_field_data_pt[i];}
225  //Return the temporary data
226  return temp_data;
227  }
228 
229 
230  /// \short Return the number of geometric Data items that affect the
231  /// external interactions in this element: i.e. any geometric Data
232  /// in the problem that affects the nodal positions in the
233  /// external elements.
236 
237  /// Are we including external geometric data in the element's Jacobian
240 
241  /// Are we including external data in the element's Jacobian
244 
245  /// \short Return vector of pointers to the geometric Data objects that
246  /// affect the interactions on the element.
248  {
249  //Find out how many external field data there are
250  const unsigned n_external_interaction_geometric_data =
252  //Create and populate a temporary vector
253  Vector<Data*> temp_data(n_external_interaction_geometric_data);
254  for(unsigned i=0;i<n_external_interaction_geometric_data;i++)
256  //Return the temporary data
257  return temp_data;
258  }
259 
260  /// \short Do not include any external geometric data when computing
261  /// the element's Jacobian. This function should be
262  /// called if the external element does not move and/or if
263  /// the "source term" does not depend on spatial derivatives
264  /// of the field computed by the other element.
266 
267  /// \short Do not include any external interaction data when computing
268  /// the element's Jacobian
271 
272  /// \short Do include external geometric data when computing
273  /// the element's Jacobian. This function should be called
274  /// to re-enable inclusion of external geometric data.
277 
278  /// \short Do include external geometric data when computing the element's
279  /// Jacobian This function should be called
280  /// to re-enable inclusion of external interaction data
283 
284  /// \short Is the external geometric data taken into account when forming
285  /// the Jacobian?
288 
289  /// \short Function to describe the local dofs of the element. The ostream
290  /// specifies the output stream to which the description
291  /// is written; the string stores the currently
292  /// assembled output that is ultimately written to the
293  /// output stream by Data::describe_dofs(...); it is typically
294  /// built up incrementally as we descend through the
295  /// call hierarchy of this function when called from
296  /// Problem::describe_dofs(...)
297  void describe_local_dofs(std::ostream& out,
298  const std::string& curr_string) const;
299 
300  protected:
301 
302  /// \short Overload the assign internal and external local equation
303  /// number scheme so that the interaction data is taken into account
305  const bool &store_local_dof_pt)
306  {
307  //Call the external stuff first so that it is near the front of the
308  //list for fast searches when using indexing by global dof for
309  //analytic calculation of interaction blocks.
311  store_local_dof_pt);
312  //Now call the underlying equation numbering
315  }
316 
317  /// \short Assign the local equation numbers for those
318  /// Data values involved in the external interactions that
319  /// affect the residuals of the element
321  const bool &store_local_dof_pt);
322 
323 
324  /// \short Calculate the contributions to the jacobian from all external
325  /// interaction degrees of freedom (geometric and field data) in
326  /// the external element using finite differences.
327  /// This version of the function assumes that the residuals vector has
328  /// already been calculated.
330  Vector<double> &residuals, DenseMatrix<double> &jacobian)
331  {
332  //Get the contribution from the external field data
334  jacobian);
335  //Get the contribution from the external geometric data
337  jacobian);
338  }
339 
340  /// \short Calculate the contributions to the jacobian from all enternal
341  /// interaction degrees of freedom (geometric and field data) in
342  /// the external element using finite differences. This version computes
343  /// the residuals vector before calculating the jacobian terms.
345  DenseMatrix<double> &jacobian)
346  {
347  const unsigned n_dof = this->ndof();
348  //Allocate storage for the residuals
349  Vector<double> residuals(n_dof,0.0);
350  //Get the residuals for the entire element
351  get_residuals(residuals);
352  //Call the jacobian calculation
354  jacobian);
355  }
356 
357 
358  /// \short Calculate the contributions to the jacobian from the external
359  /// interaction degrees of freedom associated with fields interpolated by
360  /// the external element using finite differences.
361  /// This version of the function assumes that the residuals vector has
362  /// already been calculated.
364  Vector<double> &residuals, DenseMatrix<double> &jacobian);
365 
366  /// \short Calculate the contributions to the jacobian from the enternal
367  /// interaction degrees of freedom associated with fields interpolated by
368  /// the external element using finite differences. This version computes
369  /// the residuals vector before calculating the jacobian terms.
371  DenseMatrix<double> &jacobian)
372  {
373  const unsigned n_dof = this->ndof();
374  //Allocate storage for the residuals
375  Vector<double> residuals(n_dof,0.0);
376  //Get the residuals for the entire element
377  get_residuals(residuals);
378  //Call the jacobian calculation
380  jacobian);
381  }
382 
383  /// \short Calculate the contributions to the jacobian from the external
384  /// interaction degrees of freedom associated with the geometry of
385  /// the external elements using finite differences.
386  /// This version of the function assumes that the residuals vector has
387  /// already been calculated.
389  Vector<double> &residuals, DenseMatrix<double> &jacobian);
390 
391  /// \short Calculate the contributions to the jacobian from the
392  /// external
393  /// interaction degrees of freedom associated with the geometry of
394  /// the external elements using finite differences. This version computes
395  /// the residuals vector before calculating the jacobian terms.
397  DenseMatrix<double> &jacobian)
398  {
399  const unsigned n_dof = this->ndof();
400  //Allocate storage for the residuals
401  Vector<double> residuals(n_dof,0.0);
402  //Get the residuals for the entire element
403  get_residuals(residuals);
404  //Call the jacobian calculation
406  jacobian);
407  }
408 
409  /// Fill in the element's contribution to the Jacobian matrix
410  /// and the residual vector: Done by finite differencing the
411  /// residual vector w.r.t. all nodal, internal, external and load Data.
413  DenseMatrix<double> &jacobian)
414  {
415  //Add the contribution to the residuals
417  //Allocate storage for the full residuals (residuals of entire element)
418  const unsigned n_dof = this->ndof();
419  Vector<double> full_residuals(n_dof);
420  //Get the residuals for the entire element
421  get_residuals(full_residuals);
422  //Add the internal and external by finite differences
423  fill_in_jacobian_from_internal_by_fd(full_residuals,jacobian);
424  fill_in_jacobian_from_external_by_fd(full_residuals,jacobian);
425  fill_in_jacobian_from_nodal_by_fd(full_residuals,jacobian);
426  fill_in_jacobian_from_external_interaction_by_fd(full_residuals,jacobian);
427  }
428 
429 
430 
431  /// \short Function that is called before the finite differencing of
432  /// any external interaction data associated with external fields.
433  /// This may be overloaded to update any slaved
434  /// data before finite differencing takes place.
436 
437  /// \short Function that is call after the finite differencing of
438  /// the external interaction data associated with external fields
439  /// This may be overloaded to reset any slaved
440  /// variables that may have changed during the finite differencing.
442 
443  /// \short Function called within the finite difference loop for
444  /// external interaction data after a change in any values in the i-th
445  /// external interaction data object associated with external fields.
446  virtual inline
447  void update_in_external_interaction_field_fd(const unsigned &i) { }
448 
449  /// \short Function called within the finite difference loop for
450  /// external interaction data after the values in the
451  /// i-th external interaction data object associated with external fields
452  /// are reset. The default behaviour is to call the update function.
453  virtual inline
456 
457 
458  /// \short Function that is called before the finite differencing of
459  /// any external interaction data associated with external geometry.
460  /// This may be overloaded to update any slaved
461  /// data before finite differencing takes place.
463 
464  /// \short Function that is call after the finite differencing of
465  /// the external interaction data associated with external geometry.
466  /// This may be overloaded to reset any slaved
467  /// variables that may have changed during the finite differencing.
469 
470  /// \short Function called within the finite difference loop for
471  /// external interaction data after a change in any values in the i-th
472  /// external interaction data object associated with external geometry.
473  virtual inline
475 
476  /// \short Function called within the finite difference loop for
477  /// external interaction data after the values in the
478  /// i-th external interaction data object associated with external geometry
479  /// are reset. The default behaviour is to call the update function.
480  virtual inline
483 
484  ///Boolean flag to indicate whether to include the external data
486 
487  ///Boolean flag to indicate whether to include the external geometric data
489 
490  //// Storage for pointers to external field Data that affect the
491  /// interactions in the elemenet
493 
494  //// Storage for pointers to external geometric Data that affect the
495  /// interactions in the elemenet
497 
498  private:
499 
500  /// \short Helper function to check that storage has actually been allocated
502  {
503  //If either of the storage arrays is zero, then storage has not
504  //yet been allocated. Both arrays are allocated at once, so
505  //if one is zero both will (should) be
507  {
508  std::ostringstream error_stream;
509  error_stream
510  << "Storage for the external elements has not been allocated.\n"
511  << "initialise_external_element_storage() must be called.\n"
512  << "This tends to be done automatically during the multi-domain\n"
513  << "setup procedures -- you're most likely to get this error\n"
514  << "because you have not specified the number of interactions\n"
515  << "that your ElementWithExternalElement is involved in.\n"
516  << "You ought to specify this with a call to\n\n"
517  << " ElementWithExternalElement::set_ninteraction(...)\n\n";
518  throw OomphLibError(
519  error_stream.str(),
520  OOMPH_CURRENT_FUNCTION,
521  OOMPH_EXCEPTION_LOCATION);
522  }
523  }
524 
525  /// Helper function for range checking in the access functions
526  void range_check(const unsigned& interaction_index, const unsigned& ipt)
527  const
528  {
529  //Boolean flag used to indicate range error
530  bool range_error = false;
531  //String for the error message
532  std::ostringstream error_message;
533  //If there is a range error in the interaction index
534  if(interaction_index >= Ninteraction)
535  {
536  error_message << "Range Error: Interaction " << interaction_index
537  << " is not in the range (0,"
538  << Ninteraction-1 << ")";
539  //There has been a range error
540  range_error=true;
541  }
542 
543  //If there is a range error in the integration point
544  if(ipt >= Nintpt)
545  {
546  error_message << "Range Error: Integration point " << ipt
547  << " is not in the range (0,"
548  << Nintpt-1 << ")";
549  range_error=true;
550  }
551 
552 
553  //If there has been a range error report it
554  if(range_error)
555  {
556  throw OomphLibError(error_message.str(),
557  OOMPH_CURRENT_FUNCTION,
558  OOMPH_EXCEPTION_LOCATION);
559  }
560  }
561 
562  /// Number of interactions
563  unsigned Ninteraction;
564 
565  /// Number of intergation point in the element
566  unsigned Nintpt;
567 
568  /// \short Number of entries in the external element storage schemes
569  /// (Nintergation_pt * Ninteraction)
571 
572  /// Number of external interaction field data
574 
575  /// Number of external interaction geometric data
577 
578 
579  /// \short Storage for pointers to elements that provide contributions
580  /// to the residuals of the current element. Potentially a different
581  /// element contributes to each integration point.
583 
584  /// \short Storage for vectors of local coordinates in
585  /// external elements that correspond to the appropriate integration
586  //// point.
588 
589  /// \short Storage for the index of the values in the external field data
590  /// that affect the interactions in the element
592 
593  /// \short Storage for the local equation number associated with the
594  /// external field data the affect the interactions in the element
596 
597  /// \short Storage for the index of the values in the external
598  /// geometric data
599  /// that affect the interactions in the element
601 
602  /// \short Storage for the local equation number associated with the
603  /// external geometric data the affect the interactions in the element
605 
606  };
607 }
608 
609 #endif
void initialise_external_element_storage()
Initialise storage for pointers to external elements and their local coordinates. This must be called...
virtual void get_residuals(Vector< double > &residuals)
Calculate the vector of residuals of the equations in the element. By default initialise the vector t...
Definition: elements.h:975
void broken_copy(const std::string &class_name)
Issue error message and terminate execution.
Vector< Data * > external_interaction_geometric_data_pt() const
Return vector of pointers to the geometric Data objects that affect the interactions on the element...
virtual void fill_in_contribution_to_residuals(Vector< double > &residuals)
Add the elemental contribution to the residuals vector. Note that this function will NOT initialise t...
Definition: elements.h:360
virtual void identify_all_field_data_for_external_interaction(Vector< std::set< FiniteElement *> > const &external_elements_pt, std::set< std::pair< Data *, unsigned > > &paired_interaction_data)
Function that must return all the data involved in the desired interactions from the external element...
unsigned Nexternal_interaction_field_data
Number of external interaction field data.
Vector< double > & external_element_local_coord(const unsigned &interaction_index, const unsigned &ipt)
Access function to get source element&#39;s local coords for specified interaction index at specified int...
void fill_in_jacobian_from_internal_by_fd(Vector< double > &residuals, DenseMatrix< double > &jacobian, const bool &fd_all_data=false)
Calculate the contributions to the jacobian from the internal degrees of freedom using finite differe...
Definition: elements.cc:1064
int * External_interaction_field_data_local_eqn
Storage for the local equation number associated with the external field data the affect the interact...
void flush_all_external_element_storage()
Flush the storage for external elements.
cstr elem_len * i
Definition: cfortran.h:607
bool Add_external_interaction_data
Boolean flag to indicate whether to include the external data.
void fill_in_jacobian_from_external_interaction_by_fd(Vector< double > &residuals, DenseMatrix< double > &jacobian)
Calculate the contributions to the jacobian from all external interaction degrees of freedom (geometr...
virtual void reset_in_external_interaction_field_fd(const unsigned &i)
Function called within the finite difference loop for external interaction data after the values in t...
A general Finite Element class.
Definition: elements.h:1274
virtual void reset_after_external_interaction_geometric_fd()
Function that is call after the finite differencing of the external interaction data associated with ...
void fill_in_jacobian_from_external_interaction_geometric_by_fd(DenseMatrix< double > &jacobian)
Calculate the contributions to the jacobian from the external interaction degrees of freedom associat...
void set_ninteraction(const unsigned &n_interaction)
Set the number of interactions in the element This function is usually called in the specific element...
int * External_interaction_geometric_data_local_eqn
Storage for the local equation number associated with the external geometric data the affect the inte...
void check_storage_allocated() const
Helper function to check that storage has actually been allocated.
ElementWithExternalElement()
Constructor. Initialise member data and pointers to data associated with the external elements to zer...
Vector< Data * > external_interaction_field_data_pt() const
Return vector of pointers to the field Data objects that affect the interactions on the element...
void fill_in_jacobian_from_external_by_fd(Vector< double > &residuals, DenseMatrix< double > &jacobian, const bool &fd_all_data=false)
Calculate the contributions to the jacobian from the external degrees of freedom using finite differe...
Definition: elements.cc:1158
void ignore_external_interaction_data()
Do not include any external interaction data when computing the element&#39;s Jacobian.
unsigned Nexternal_element_storage
Number of entries in the external element storage schemes (Nintergation_pt * Ninteraction) ...
unsigned ndof() const
Return the number of equations/dofs in the element.
Definition: elements.h:834
bool add_external_geometric_data()
Are we including external geometric data in the element&#39;s Jacobian.
void output_external_elements(std::ostream &outfile, const unsigned &interaction_index)
Output by plotting vector from integration point to corresponding point in external element for speci...
bool Add_external_geometric_data
Boolean flag to indicate whether to include the external geometric data.
void assign_external_interaction_data_local_eqn_numbers(const bool &store_local_dof_pt)
Assign the local equation numbers for those Data values involved in the external interactions that af...
unsigned Nexternal_interaction_geometric_data
Number of external interaction geometric data.
unsigned * External_interaction_geometric_data_index
Storage for the index of the values in the external geometric data that affect the interactions in th...
A class that represents a collection of data; each Data object may contain many different individual ...
Definition: nodes.h:89
unsigned nexternal_interaction_field_data() const
Return the number of Data items that affect the external interactions in this element. This includes e.g. fluid velocities and pressures in adjacent fluid elements in an FSI problem.
unsigned nexternal_interaction_geometric_data() const
Return the number of geometric Data items that affect the external interactions in this element: i...
virtual void reset_in_external_interaction_geometric_fd(const unsigned &i)
Function called within the finite difference loop for external interaction data after the values in t...
unsigned Ninteraction
Number of interactions.
void fill_in_jacobian_from_external_interaction_field_by_fd(DenseMatrix< double > &jacobian)
Calculate the contributions to the jacobian from the enternal interaction degrees of freedom associat...
Vector< double > * External_element_local_coord
Storage for vectors of local coordinates in external elements that correspond to the appropriate inte...
virtual void identify_all_geometric_data_for_external_interaction(Vector< std::set< FiniteElement *> > const &external_elements_pt, std::set< Data *> &external_geometric_data_pt)
Function that must return all geometric data involved in the desired interactions from the external e...
unsigned ninteraction() const
Return the number of interactions in the element.
unsigned * External_interaction_field_data_index
Storage for the index of the values in the external field data that affect the interactions in the el...
void fill_in_contribution_to_jacobian(Vector< double > &residuals, DenseMatrix< double > &jacobian)
bool add_external_interaction_data()
Are we including external data in the element&#39;s Jacobian.
void operator=(const ElementWithExternalElement &)
Broken assignment operator.
FiniteElement ** External_element_pt
Storage for pointers to elements that provide contributions to the residuals of the current element...
void fill_in_jacobian_from_external_interaction_by_fd(DenseMatrix< double > &jacobian)
Calculate the contributions to the jacobian from all enternal interaction degrees of freedom (geometr...
ElementWithExternalElement(const ElementWithExternalElement &)
Broken copy constructor.
virtual void fill_in_jacobian_from_nodal_by_fd(Vector< double > &residuals, DenseMatrix< double > &jacobian)
Calculate the contributions to the jacobian from the nodal degrees of freedom using finite difference...
Definition: elements.cc:3583
void fill_in_jacobian_from_external_interaction_geometric_by_fd(Vector< double > &residuals, DenseMatrix< double > &jacobian)
Calculate the contributions to the jacobian from the external interaction degrees of freedom associat...
void broken_assign(const std::string &class_name)
Issue error message and terminate execution.
virtual void update_before_external_interaction_field_fd()
Function that is called before the finite differencing of any external interaction data associated wi...
unsigned Nintpt
Number of intergation point in the element.
FiniteElement *& external_element_pt(const unsigned &interaction_index, const unsigned &ipt)
Access function to source element for specified interaction index at specified integration point...
std::string string(const unsigned &i)
Return the i-th string or "" if the relevant string hasn&#39;t been defined.
void ignore_external_geometric_data()
Do not include any external geometric data when computing the element&#39;s Jacobian. This function shoul...
void fill_in_jacobian_from_external_interaction_field_by_fd(Vector< double > &residuals, DenseMatrix< double > &jacobian)
Calculate the contributions to the jacobian from the external interaction degrees of freedom associat...
bool storage_has_been_allocated() const
Helper function to check if storage has actually been allocated.
virtual void update_before_external_interaction_geometric_fd()
Function that is called before the finite differencing of.
void range_check(const unsigned &interaction_index, const unsigned &ipt) const
Helper function for range checking in the access functions.
virtual void reset_after_external_interaction_field_fd()
Function that is call after the finite differencing of the external interaction data associated with ...
FiniteElement *const & external_element_pt(const unsigned &interaction_index, const unsigned &ipt) const
Access function to source element, const version.
void describe_local_dofs(std::ostream &out, const std::string &curr_string) const
Function to describe the local dofs of the element. The ostream specifies the output stream to which ...
bool external_geometric_data_is_included() const
Is the external geometric data taken into account when forming the Jacobian?
void assign_internal_and_external_local_eqn_numbers(const bool &store_local_dof_pt)
Overload the assign internal and external local equation number scheme so that the interaction data i...
virtual void update_in_external_interaction_field_fd(const unsigned &i)
Function called within the finite difference loop for external interaction data after a change in any...
void include_external_geometric_data()
Do include external geometric data when computing the element&#39;s Jacobian. This function should be cal...
virtual void assign_internal_and_external_local_eqn_numbers(const bool &store_local_dof_pt)
Assign the local equation numbers for the internal and external Data This must be called after the gl...
Definition: elements.cc:909
virtual ~ElementWithExternalElement()
The destructor, clean up any allocated memory.
void include_external_interaction_data()
Do include external geometric data when computing the element&#39;s Jacobian This function should be call...
virtual void update_in_external_interaction_geometric_fd(const unsigned &i)
Function called within the finite difference loop for external interaction data after a change in any...