ITK  4.13.0
Insight Segmentation and Registration Toolkit
itkFEMElement2DMembrane.h
Go to the documentation of this file.
1 /*=========================================================================
2  *
3  * Copyright Insight Software Consortium
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  * http://www.apache.org/licenses/LICENSE-2.0.txt
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  *
17  *=========================================================================*/
18 
19 #ifndef itkFEMElement2DMembrane_h
20 #define itkFEMElement2DMembrane_h
21 
22 #include "itkFEMElementBase.h"
24 
25 namespace itk
26 {
27 namespace fem
28 {
52 template <typename TBaseClass = Element>
53 class ITK_TEMPLATE_EXPORT Element2DMembrane : public TBaseClass
54 {
55 public:
56 
59  typedef TBaseClass Superclass;
62 
64  itkTypeMacro(Element2DMembrane, TBaseClass);
65 
66  // Repeat the required typedefs and enums from parent class
67  typedef typename Superclass::Float Float;
70 
75 
76  // ////////////////////////////////////////////////////////////////////////
84  virtual void GetStrainDisplacementMatrix(MatrixType & B, const MatrixType & shapeDgl) const ITK_OVERRIDE;
85 
89  virtual void GetMaterialMatrix(MatrixType & D) const ITK_OVERRIDE;
90 
94  void GetMassMatrix(MatrixType & Me) const ITK_OVERRIDE;
95 
99  virtual unsigned int GetNumberOfDegreesOfFreedomPerNode(void) const ITK_OVERRIDE
100  {
101  return 2;
102  }
103 
107  virtual Material::ConstPointer GetMaterial(void) const ITK_OVERRIDE
108  {
109  return m_mat;
110  }
111 
112  virtual void SetMaterial(Material::ConstPointer mat_) ITK_OVERRIDE
113  {
114  m_mat =
115  dynamic_cast<const MaterialLinearElasticity *>( mat_.GetPointer() );
116  }
117 
118 protected:
119 
120  virtual void PrintSelf(std::ostream& os, Indent indent) const ITK_OVERRIDE;
121 
126 
127 }; // class Element2DMembrane
128 
129 }
130 } // end namespace itk::fem
131 
132 #ifndef ITK_MANUAL_INSTANTIATION
133 #include "itkFEMElement2DMembrane.hxx"
134 #endif
135 
136 #endif // #ifndef itkFEMElement2DMembrane_h
Class that is used to define a membrane energy problem in 2D space.
Superclass::MatrixType MatrixType
vnl_matrix< Float > MatrixType
Linear elasticity material class.
SmartPointer< const Self > ConstPointer
Superclass::VectorType VectorType
Superclass::VectorType VectorType
virtual void SetMaterial(Material::ConstPointer mat_) override
virtual unsigned int GetNumberOfDegreesOfFreedomPerNode(void) const override
const MaterialLinearElasticity * m_mat
Control indentation during Print() invocation.
Definition: itkIndent.h:49
Superclass::MatrixType MatrixType
virtual Material::ConstPointer GetMaterial(void) const override