libMesh::Side< SideType, ParentType > Class Template Reference

#include <side.h>

List of all members.

Public Member Functions

 Side (const Elem *parent_in, const unsigned int side_in)
virtual const Pointpoint (const unsigned int i) const
virtual Pointpoint (const unsigned int i)
virtual dof_id_type node (const unsigned int i) const
virtual Nodeget_node (const unsigned int i) const
virtual Node *& set_node (const unsigned int i)
virtual unsigned int n_sides () const
virtual bool is_child_on_side (const unsigned int, const unsigned int) const

Private Attributes

const unsigned int _side_number

Detailed Description

template<class SideType, class ParentType>
class libMesh::Side< SideType, ParentType >

This defines the Side class. A Side is basically a proxy (or stand-in replacement) class for an element's side. It acts like a standard Elem, but allocates no additional memory for storing connectivity. Instead, its nodes are mapped directly from the parent element (the element for which the side is created). Similarly, you cannot access the neighbors of a side since it does not store any.

Author:
Benjamin S. Kirk

Definition at line 53 of file side.h.


Constructor & Destructor Documentation

template<class SideType , class ParentType >
libMesh::Side< SideType, ParentType >::Side ( const Elem parent_in,
const unsigned int  side_in 
) [inline]

Constructor. Creates a side from an element.

Definition at line 60 of file side.h.

00061                                     :
00062     SideType(const_cast<Elem*>(parent_in)),
00063     _side_number(side_in)
00064   {
00065     libmesh_assert(parent_in);
00066     // may not be true when building infinite element sides
00067     // libmesh_assert_less (_side_number, this->parent()->n_sides());
00068     libmesh_assert_equal_to ((this->dim()+1), this->parent()->dim());
00069   }


Member Function Documentation

template<class SideType , class ParentType >
virtual Node* libMesh::Side< SideType, ParentType >::get_node ( const unsigned int  i  )  const [inline, virtual]
Returns:
the pointer to local Node i.

Definition at line 102 of file side.h.

References libMesh::Side< SideType, ParentType >::_side_number, and n_nodes.

00103   {
00104     libmesh_assert_less (i, this->n_nodes());
00105     return this->parent()->get_node (ParentType::side_nodes_map[_side_number][i]);
00106   }

template<class SideType , class ParentType >
virtual bool libMesh::Side< SideType, ParentType >::is_child_on_side ( const unsigned  int,
const unsigned  int 
) const [inline, virtual]

Definition at line 123 of file side.h.

00125   { libmesh_error(); return false; }

template<class SideType , class ParentType >
virtual unsigned int libMesh::Side< SideType, ParentType >::n_sides (  )  const [inline, virtual]

Sides effectively do not have sides

Definition at line 120 of file side.h.

00121   { return 0; }

template<class SideType , class ParentType >
virtual dof_id_type libMesh::Side< SideType, ParentType >::node ( const unsigned int  i  )  const [inline, virtual]
Returns:
the global id number of local Node i.

Definition at line 93 of file side.h.

References libMesh::Side< SideType, ParentType >::_side_number, and n_nodes.

00094   {
00095     libmesh_assert_less (i, this->n_nodes());
00096     return this->parent()->node (ParentType::side_nodes_map[_side_number][i]);
00097   }

template<class SideType , class ParentType >
virtual Point& libMesh::Side< SideType, ParentType >::point ( const unsigned int  i  )  [inline, virtual]
Returns:
the Point associated with local Node i as a writeable reference.

Definition at line 84 of file side.h.

References libMesh::Side< SideType, ParentType >::_side_number, and n_nodes.

00085   {
00086     libmesh_assert_less (i, this->n_nodes());
00087     return this->parent()->point (ParentType::side_nodes_map[_side_number][i]);
00088   }

template<class SideType , class ParentType >
virtual const Point& libMesh::Side< SideType, ParentType >::point ( const unsigned int  i  )  const [inline, virtual]
Returns:
the Point associated with local Node i.

Definition at line 74 of file side.h.

References libMesh::Side< SideType, ParentType >::_side_number, and n_nodes.

00075   {
00076     libmesh_assert_less (i, this->n_nodes());
00077     return this->parent()->point (ParentType::side_nodes_map[_side_number][i]);
00078   }

template<class SideType , class ParentType >
virtual Node* & libMesh::Side< SideType, ParentType >::set_node ( const unsigned int  i  )  [inline, virtual]
Returns:
the pointer to local Node i as a writeable reference.

Definition at line 111 of file side.h.

References libMesh::Side< SideType, ParentType >::_side_number, and n_nodes.

00112   {
00113     libmesh_assert_less (i, this->n_nodes());
00114     return this->parent()->set_node (ParentType::side_nodes_map[_side_number][i]);
00115   }


Member Data Documentation

template<class SideType , class ParentType >
const unsigned int libMesh::Side< SideType, ParentType >::_side_number [private]

The documentation for this class was generated from the following file:

Site Created By: libMesh Developers
Last modified: February 05 2013 19:55:38 UTC

Hosted By:
SourceForge.net Logo