Nektar++
OptimiseObj.h
Go to the documentation of this file.
1 ////////////////////////////////////////////////////////////////////////////////
2 //
3 // File: Curvemesh.h
4 //
5 // For more information, please see: http://www.nektar.info/
6 //
7 // The MIT License
8 //
9 // Copyright (c) 2006 Division of Applied Mathematics, Brown University (USA),
10 // Department of Aeronautics, Imperial College London (UK), and Scientific
11 // Computing and Imaging Institute, University of Utah (USA).
12 //
13 // Permission is hereby granted, free of charge, to any person obtaining a
14 // copy of this software and associated documentation files (the "Software"),
15 // to deal in the Software without restriction, including without limitation
16 // the rights to use, copy, modify, merge, publish, distribute, sublicense,
17 // and/or sell copies of the Software, and to permit persons to whom the
18 // Software is furnished to do so, subject to the following conditions:
19 //
20 // The above copyright notice and this permission notice shall be included
21 // in all copies or substantial portions of the Software.
22 //
23 // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
24 // OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
25 // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
26 // THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
27 // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
28 // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
29 // DEALINGS IN THE SOFTWARE.
30 //
31 // Description: object for individual curve meshes.
32 //
33 ////////////////////////////////////////////////////////////////////////////////
34 
35 #ifndef NEKTAR_MESHUTILS_OPTIMISATION_OPTIMISEOBJ_H
36 #define NEKTAR_MESHUTILS_OPTIMISATION_OPTIMISEOBJ_H
37 
38 #include <boost/core/ignore_unused.hpp>
39 
41 
42 namespace Nektar
43 {
44 namespace NekMeshUtils
45 {
46 
47 class OptiObj
48 {
49  public:
50 
52  {
53  }
54 
55  virtual ~OptiObj()
56  {
57  }
58 
60  {
61  boost::ignore_unused(xitst);
63  "F() should be implemented in inheriting class");
64  return 0.0;
65  }
66 
68  {
69  boost::ignore_unused(xitst);
71  "dF() should be implemented in inheriting class");
72  return DNekMat(1,1,0.0);
73  }
74 
76  {
78  "Getxi() should be implemented in inheriting class");
79  return Array<OneD,NekDouble>();
80  }
81 
83  {
85  "Getli() should be implemented in inheriting class");
86  return Array<OneD,NekDouble>();
87  }
88 
90  {
92  "Getui() should be implemented in inheriting class");
93  return Array<OneD,NekDouble>();
94  }
95 
96  virtual void Update(Array<OneD, NekDouble> xinew)
97  {
98  boost::ignore_unused(xinew);
100  "Update() should be implemented in inheriting class");
101  }
102 
103 };
104 typedef std::shared_ptr<OptiObj> OptiObjSharedPtr;
105 
106 }
107 }
108 #endif
#define NEKERROR(type, msg)
Assert Level 0 – Fundamental assert which is used whether in FULLDEBUG, DEBUG or OPT compilation mod...
Definition: ErrorUtil.hpp:209
virtual Array< OneD, NekDouble > Getxi()
Definition: OptimiseObj.h:75
virtual DNekMat dF(Array< OneD, NekDouble > xitst)
Definition: OptimiseObj.h:67
virtual NekDouble F(Array< OneD, NekDouble > xitst)
Definition: OptimiseObj.h:59
virtual Array< OneD, NekDouble > Getli()
Definition: OptimiseObj.h:82
std::shared_ptr< OptiObj > OptiObjSharedPtr
Definition: OptimiseObj.h:104
NekMatrix< NekDouble, StandardMatrixTag > DNekMat
Definition: NekTypeDefs.hpp:51
double NekDouble
virtual void Update(Array< OneD, NekDouble > xinew)
Definition: OptimiseObj.h:96
virtual Array< OneD, NekDouble > Getui()
Definition: OptimiseObj.h:89