EquationIdVector

From KratosWiki
Revision as of 15:58, 28 November 2007 by 147.83.143.248 (Talk)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search
	void LinearElement::EquationIdVector(EquationIdVectorType& rResult, ProcessInfo& CurrentProcessInfo)

{ int number_of_nodes = GetGeometry().size(); int dim = GetGeometry().WorkingSpaceDimension(); unsigned int dim2 = number_of_nodes*dim; if(rResult.size() != dim2) rResult.resize(dim2); for (int i=0;i<number_of_nodes;i++) { int index = i*dim; rResult[index] = GetGeometry()[i].GetDof(DISPLACEMENT_X).EquationId(); rResult[index + 1] = GetGeometry()[i].GetDof(DISPLACEMENT_Y).EquationId(); if(dim == 3) rResult[index + 2] = GetGeometry()[i].GetDof(DISPLACEMENT_Z).EquationId(); } }

Personal tools
Categories