Commit 9a32dc04 authored by Michael Turner's avatar Michael Turner
Browse files

Merge branch 'fix/varopti-2d' into 'master'

Fix 2D varopti code

See merge request !806
parents b149b3a1 7209ec33
...@@ -59,7 +59,7 @@ public: ...@@ -59,7 +59,7 @@ public:
NodeOpti(NodeSharedPtr n, std::vector<ElUtilSharedPtr> e, NodeOpti(NodeSharedPtr n, std::vector<ElUtilSharedPtr> e,
ResidualSharedPtr r, ResidualSharedPtr r,
std::map<LibUtilities::ShapeType, DerivUtilSharedPtr> d, std::map<LibUtilities::ShapeType, DerivUtilSharedPtr> d,
optiType o) optiType o, int dim)
: m_node(n), m_res(r), m_derivUtils(d), m_opti(o) : m_node(n), m_res(r), m_derivUtils(d), m_opti(o)
{ {
// filter element types within d vector // filter element types within d vector
...@@ -79,12 +79,12 @@ public: ...@@ -79,12 +79,12 @@ public:
const int nElmt = typeIt->second.size(); const int nElmt = typeIt->second.size();
storageCount = std::max(storageCount, storageCount = std::max(storageCount,
3 * m_derivUtils[typeIt->first]->ptsStd * dim * m_derivUtils[typeIt->first]->ptsStd *
typeIt->second.size()); typeIt->second.size());
m_derivs.insert(std::make_pair( m_derivs.insert(std::make_pair(
typeIt->first, typeIt->first,
DerivArray(boost::extents[3][nElmt][3][pts]))); DerivArray(boost::extents[dim][nElmt][dim][pts])));
} }
m_tmpStore.resize(storageCount); m_tmpStore.resize(storageCount);
...@@ -148,7 +148,7 @@ public: ...@@ -148,7 +148,7 @@ public:
ResidualSharedPtr r, ResidualSharedPtr r,
std::map<LibUtilities::ShapeType, DerivUtilSharedPtr> d, std::map<LibUtilities::ShapeType, DerivUtilSharedPtr> d,
optiType o) optiType o)
: NodeOpti(n, e, r, d, o) : NodeOpti(n, e, r, d, o, 3)
{ {
} }
...@@ -174,7 +174,7 @@ public: ...@@ -174,7 +174,7 @@ public:
ResidualSharedPtr r, ResidualSharedPtr r,
std::map<LibUtilities::ShapeType, DerivUtilSharedPtr> d, std::map<LibUtilities::ShapeType, DerivUtilSharedPtr> d,
optiType o) optiType o)
: NodeOpti(n, e, r, d, o) : NodeOpti(n, e, r, d, o, 2)
{ {
} }
......
...@@ -52,7 +52,7 @@ public: ...@@ -52,7 +52,7 @@ public:
ResidualSharedPtr r, ResidualSharedPtr r,
std::map<LibUtilities::ShapeType, DerivUtilSharedPtr> d, std::map<LibUtilities::ShapeType, DerivUtilSharedPtr> d,
optiType o, CADCurveSharedPtr c) optiType o, CADCurveSharedPtr c)
: NodeOpti(n, e, r, d, o), curve(c) : NodeOpti(n, e, r, d, o, 3), curve(c)
{ {
} }
...@@ -81,7 +81,7 @@ public: ...@@ -81,7 +81,7 @@ public:
ResidualSharedPtr r, ResidualSharedPtr r,
std::map<LibUtilities::ShapeType, DerivUtilSharedPtr> d, std::map<LibUtilities::ShapeType, DerivUtilSharedPtr> d,
optiType o, CADSurfSharedPtr s) optiType o, CADSurfSharedPtr s)
: NodeOpti(n, e, r, d, o), surf(s) : NodeOpti(n, e, r, d, o, 3), surf(s)
{ {
} }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment