Skip to content
Snippets Groups Projects
Commit a3cf6ff1 authored by Oliver Sander's avatar Oliver Sander Committed by sander@PCPOOL.MI.FU-BERLIN.DE
Browse files

remove method to assemble the Hesse matrix. That method already exists in the base class

[[Imported from SVN: r4153]]
parent ab369938
No related branches found
No related tags found
No related merge requests found
...@@ -45,54 +45,6 @@ getNeighborsPerVertex(Dune::MatrixIndexSet& nb) const ...@@ -45,54 +45,6 @@ getNeighborsPerVertex(Dune::MatrixIndexSet& nb) const
} }
template <class GridType>
void RodAssembler<GridType>::
assembleMatrix(const std::vector<RigidBodyMotion<3> >& sol,
Dune::BCRSMatrix<MatrixBlock>& matrix) const
{
const typename GridType::Traits::LevelIndexSet& indexSet = grid_->levelIndexSet(grid_->maxLevel());
Dune::MatrixIndexSet neighborsPerVertex;
getNeighborsPerVertex(neighborsPerVertex);
matrix = 0;
ElementIterator it = grid_->template lbegin<0>( grid_->maxLevel() );
ElementIterator endit = grid_->template lend<0> ( grid_->maxLevel() );
for( ; it != endit; ++it ) {
const Dune::LagrangeShapeFunctionSet<double, double, gridDim> & baseSet
= Dune::LagrangeShapeFunctions<double, double, gridDim>::general(it->type(), elementOrder);
const int numOfBaseFct = baseSet.size();
// Extract local solution
std::vector<RigidBodyMotion<3> > localSolution(numOfBaseFct);
for (int i=0; i<numOfBaseFct; i++)
localSolution[i] = sol[indexSet.subIndex(*it,i,gridDim)];
// setup matrix
this->localStiffness_->assemble(*it, localSolution);
// Add element matrix to global stiffness matrix
for(int i=0; i<numOfBaseFct; i++) {
int row = indexSet.subIndex(*it,i,gridDim);
for (int j=0; j<numOfBaseFct; j++ ) {
int col = indexSet.subIndex(*it,j,gridDim);
matrix[row][col] += this->localStiffness_->mat(i,j);
}
}
}
}
template <class GridType> template <class GridType>
void RodAssembler<GridType>:: void RodAssembler<GridType>::
assembleGradient(const std::vector<RigidBodyMotion<3> >& sol, assembleGradient(const std::vector<RigidBodyMotion<3> >& sol,
......
...@@ -65,11 +65,6 @@ class RodAssembler : public GeodesicFEAssembler<typename GridType::LeafGridView, ...@@ -65,11 +65,6 @@ class RodAssembler : public GeodesicFEAssembler<typename GridType::LeafGridView,
dynamic_cast<RodLocalStiffness<typename GridType::LeafGridView, double>* >(this->localStiffness_)->setReferenceConfiguration(referenceConfiguration); dynamic_cast<RodLocalStiffness<typename GridType::LeafGridView, double>* >(this->localStiffness_)->setReferenceConfiguration(referenceConfiguration);
} }
/** \brief Assemble the tangent stiffness matrix
*/
void assembleMatrix(const std::vector<RigidBodyMotion<3> >& sol,
Dune::BCRSMatrix<MatrixBlock>& matrix) const;
void assembleGradient(const std::vector<RigidBodyMotion<3> >& sol, void assembleGradient(const std::vector<RigidBodyMotion<3> >& sol,
Dune::BlockVector<Dune::FieldVector<double, blocksize> >& grad) const; Dune::BlockVector<Dune::FieldVector<double, blocksize> >& grad) const;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment