Skip to content
Snippets Groups Projects
Commit 1f14bf72 authored by Tobias Malkmus's avatar Tobias Malkmus Committed by Christian Engwer
Browse files

[densematrix] implement cast of DenseVector into DynamicVector

parent 2443fac8
No related branches found
No related tags found
No related merge requests found
......@@ -71,6 +71,17 @@ namespace Dune {
_data(x._data)
{}
//! Constructor making vector with identical coordinates
template<class X>
DynamicVector (const DenseVector< X > & x) :
_data( )
{
const size_type n = x.size();
_data.reserve(n);
for( size_type i =0; i<n ;++i)
_data.push_back( x[ i ] );
}
using Base::operator=;
//==== forward some methods of std::vector
......
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