Commit 4ba0cf7a authored by Alexandra Heuschling's avatar Alexandra Heuschling
Browse files

fix bug for computation of reference_position

function now is static
parent 668f7760
Pipeline #14418 failed with stages
in 7 minutes and 35 seconds
...@@ -536,13 +536,13 @@ void SymmetricDirichletOneRingProblem::add_triangle(const InputPositionVector2D& ...@@ -536,13 +536,13 @@ void SymmetricDirichletOneRingProblem::add_triangle(const InputPositionVector2D&
element_set.instances().add_element(indices, constants); element_set.instances().add_element(indices, constants);
} }
SymmetricDirichletOneRingProblem::ReferencePositionVector2D SymmetricDirichletOneRingProblem::get_equilateral_refernce_positions(double _area) SymmetricDirichletOneRingProblem::ReferencePositionVector2D SymmetricDirichletOneRingProblem::get_equilateral_refernce_positions(double _area)
{ {
ReferencePositionVector2D equilateral_reference; ReferencePositionVector2D equilateral_reference;
equilateral_reference << 0.0, 0.0, equilateral_reference << 0.0, 0.0,
1.0, 0.0, 1.0, 0.0,
0.5, 0.5*std::sqrt(3.0); 0.5, 0.5*std::sqrt(3.0);
equilateral_reference *= _area / 0.5*0.5*std::sqrt(3.0); equilateral_reference *= _area/(0.5*0.5*std::sqrt(3.0));
return equilateral_reference; return equilateral_reference;
} }
......
...@@ -213,7 +213,7 @@ public: ...@@ -213,7 +213,7 @@ public:
void add_triangle(const InputPositionVector2D& _current_positions, const ReferencePositionVector2D& _reference_positions); void add_triangle(const InputPositionVector2D& _current_positions, const ReferencePositionVector2D& _reference_positions);
ReferencePositionVector2D get_equilateral_refernce_positions(double _area = 1.0); static ReferencePositionVector2D get_equilateral_refernce_positions(double _area = 1.0);
private: private:
SymmetricDirichletOneVertexElementSet element_set; SymmetricDirichletOneVertexElementSet element_set;
......
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