MAST
Multidisciplinary-design Adaptation and Sensitivity Toolkit (MAST)
compliance_output.h
Go to the documentation of this file.
1 /*
2  * MAST: Multidisciplinary-design Adaptation and Sensitivity Toolkit
3  * Copyright (C) 2013-2020 Manav Bhatia and MAST authors
4  *
5  * This library is free software; you can redistribute it and/or
6  * modify it under the terms of the GNU Lesser General Public
7  * License as published by the Free Software Foundation; either
8  * version 2.1 of the License, or (at your option) any later version.
9  *
10  * This library is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13  * Lesser General Public License for more details.
14  *
15  * You should have received a copy of the GNU Lesser General Public
16  * License along with this library; if not, write to the Free Software
17  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
18  */
19 
20 #ifndef __mast__compliance_output__
21 #define __mast__compliance_output__
22 
23 // C++ includes
24 #include <map>
25 #include <vector>
26 
27 // MAST includes
28 #include "base/mast_data_types.h"
31 
32 
33 // libMesh includes
34 #include "libmesh/elem.h"
35 
36 namespace MAST {
37 
38 
39  // Forward declerations
40  class FunctionBase;
41 
42 
48 
49  public:
50 
55 
56  virtual ~ComplianceOutput();
57 
58 
62  virtual void
63  set_elem_data(unsigned int dim,
64  const libMesh::Elem& ref_elem,
65  MAST::GeomElem& elem) const;
66 
70  virtual void init(const MAST::GeomElem& elem);
71 
80  virtual void zero_for_analysis();
81 
82 
88  virtual void zero_for_sensitivity();
89 
96  virtual void evaluate();
97 
104  virtual void evaluate_sensitivity(const MAST::FunctionBase& f);
105 
113 
114  libmesh_assert(false); // to be implemented
115  }
116 
123  virtual void
125 
137  virtual void
140 
144  virtual Real output_for_elem() {
145  //
146  libmesh_error();
147  }
148 
152  virtual Real output_total();
153 
160  libmesh_error(); // not yet implemented
161  }
162 
171 
172 
179  virtual void output_derivative_for_elem(RealVectorX& dq_dX);
180 
181 
182  protected:
183 
186  };
187 }
188 
189 #endif // __mast__compliance_output__
virtual void zero_for_sensitivity()
zeroes the output quantity values stored inside this object so that assembly process can begin...
virtual void evaluate_shape_sensitivity(const MAST::FunctionBase &f)
this evaluates all relevant shape sensitivity components on the element.
Computes the compliance as .
virtual void init(const MAST::GeomElem &elem)
initialize for the element.
virtual void zero_for_analysis()
zeroes the output quantity values stored inside this object so that assembly process can begin...
This provides the base class for definitin of element level contribution of output quantity in an ana...
libMesh::Real Real
virtual Real output_sensitivity_total(const MAST::FunctionBase &p)
virtual void set_elem_data(unsigned int dim, const libMesh::Elem &ref_elem, MAST::GeomElem &elem) const
sets the structural element y-vector if 1D element is used.
virtual void evaluate_sensitivity(const MAST::FunctionBase &f)
this evaluates all relevant stress sensitivity components on the element to evaluate the p-averaged q...
virtual Real output_for_elem()
should not get called for this output.
ComplianceOutput()
default constructor
Matrix< Real, Dynamic, 1 > RealVectorX
This class acts as a wrapper around libMesh::Elem for the purpose of providing a uniform interface fo...
Definition: geom_elem.h:59
virtual void evaluate()
this evaluates all relevant stress components on the element to evaluate the p-averaged quantity...
virtual void output_derivative_for_elem(RealVectorX &dq_dX)
calculates the derivative of p-norm von Mises stress for the norm identified using set_p_val()...
virtual void evaluate_topology_sensitivity(const MAST::FunctionBase &f)
this evaluates all relevant topological sensitivity components on the element.
virtual Real output_sensitivity_for_elem(const MAST::FunctionBase &p)