Skip to content
Snippets Groups Projects
Commit ddcf589c authored by Oliver Sander's avatar Oliver Sander Committed by sander
Browse files

Use FieldVector::dimension instead of FieldVector::size

[[Imported from SVN: r4356]]
parent 9ac71292
No related branches found
No related tags found
No related merge requests found
...@@ -212,7 +212,7 @@ void MonotoneMGStep<OperatorType, DiscFuncType>::iterate() ...@@ -212,7 +212,7 @@ void MonotoneMGStep<OperatorType, DiscFuncType>::iterate()
#ifndef NDEBUG #ifndef NDEBUG
// Debug: is the current iterate really admissible? // Debug: is the current iterate really admissible?
for (int i=0; i<obstacles[level].size(); i++) for (int i=0; i<obstacles[level].size(); i++)
for (int j=0; j<DiscFuncType::block_type::size; j++) for (int j=0; j<DiscFuncType::block_type::dimension; j++)
if (x[level][i][j] < obstacles[level][i].lower(j) if (x[level][i][j] < obstacles[level][i].lower(j)
|| x[level][i][j] > obstacles[level][i].upper(j)) { || x[level][i][j] > obstacles[level][i].upper(j)) {
......
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
template <class MatrixType, class VectorType> template <class MatrixType, class VectorType>
class CGSolver : public IterativeSolver<VectorType> class CGSolver : public IterativeSolver<VectorType>
{ {
static const int blocksize = VectorType::block_type::size; static const int blocksize = VectorType::block_type::dimension;
public: public:
......
...@@ -38,7 +38,7 @@ ...@@ -38,7 +38,7 @@
template <class MatrixType, class VectorType> template <class MatrixType, class VectorType>
class QuadraticIPOptProblem : public Ipopt::TNLP class QuadraticIPOptProblem : public Ipopt::TNLP
{ {
enum {blocksize = VectorType::block_type::size}; enum {blocksize = VectorType::block_type::dimension};
typedef typename VectorType::field_type field_type; typedef typename VectorType::field_type field_type;
...@@ -513,10 +513,10 @@ finalize_solution(Ipopt::SolverReturn status, ...@@ -513,10 +513,10 @@ finalize_solution(Ipopt::SolverReturn status,
*/ */
template <class MatrixType, class VectorType> template <class MatrixType, class VectorType>
class QuadraticIPOptSolver class QuadraticIPOptSolver
: public IterativeSolver<VectorType>, public CanIgnore<Dune::BitSetVector<VectorType::block_type::size> > : public IterativeSolver<VectorType>, public CanIgnore<Dune::BitSetVector<VectorType::block_type::dimension> >
{ {
enum {blocksize = VectorType::block_type::size}; enum {blocksize = VectorType::block_type::dimension};
typedef typename VectorType::field_type field_type; typedef typename VectorType::field_type field_type;
......
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
template <class MatrixType, class VectorType> template <class MatrixType, class VectorType>
class TruncatedCGSolver : public IterativeSolver<VectorType> class TruncatedCGSolver : public IterativeSolver<VectorType>
{ {
static const int blocksize = VectorType::block_type::size; static const int blocksize = VectorType::block_type::dimension;
typedef typename VectorType::field_type field_type; typedef typename VectorType::field_type field_type;
......
...@@ -23,12 +23,12 @@ template< ...@@ -23,12 +23,12 @@ template<
class VectorType, class VectorType,
class BitVectorType = Dune::BitSetVector<VectorType::block_type::dimension>, class BitVectorType = Dune::BitSetVector<VectorType::block_type::dimension>,
class MatrixType = Dune::BCRSMatrix< typename Dune::FieldMatrix< class MatrixType = Dune::BCRSMatrix< typename Dune::FieldMatrix<
typename VectorType::field_type, VectorType::block_type::size, VectorType::block_type::size> > > typename VectorType::field_type, VectorType::block_type::dimension, VectorType::block_type::dimension> > >
class CompressedMultigridTransfer : class CompressedMultigridTransfer :
public MultigridTransfer<VectorType,BitVectorType,MatrixType> public MultigridTransfer<VectorType,BitVectorType,MatrixType>
{ {
enum {blocksize = VectorType::block_type::size}; enum {blocksize = VectorType::block_type::dimension};
typedef typename VectorType::field_type field_type; typedef typename VectorType::field_type field_type;
......
...@@ -23,12 +23,12 @@ template< ...@@ -23,12 +23,12 @@ template<
class VectorType, class VectorType,
class BitVectorType = Dune::BitSetVector<VectorType::block_type::dimension>, class BitVectorType = Dune::BitSetVector<VectorType::block_type::dimension>,
class MatrixType = Dune::BCRSMatrix< typename Dune::FieldMatrix< class MatrixType = Dune::BCRSMatrix< typename Dune::FieldMatrix<
typename VectorType::field_type, VectorType::block_type::size, VectorType::block_type::size> > > typename VectorType::field_type, VectorType::block_type::dimension, VectorType::block_type::dimension> > >
class DenseMultigridTransfer : class DenseMultigridTransfer :
public MultigridTransfer<VectorType,BitVectorType,MatrixType> public MultigridTransfer<VectorType,BitVectorType,MatrixType>
{ {
enum {blocksize = VectorType::block_type::size}; enum {blocksize = VectorType::block_type::dimension};
typedef typename VectorType::field_type field_type; typedef typename VectorType::field_type field_type;
......
...@@ -18,7 +18,7 @@ template< ...@@ -18,7 +18,7 @@ template<
class VectorType, class VectorType,
class BitVectorType = Dune::BitSetVector<VectorType::block_type::dimension>, class BitVectorType = Dune::BitSetVector<VectorType::block_type::dimension>,
class MatrixType = Dune::BCRSMatrix< typename Dune::FieldMatrix< class MatrixType = Dune::BCRSMatrix< typename Dune::FieldMatrix<
typename VectorType::field_type, VectorType::block_type::size, VectorType::block_type::size> > > typename VectorType::field_type, VectorType::block_type::dimension, VectorType::block_type::dimension> > >
class MultigridTransfer { class MultigridTransfer {
public: public:
......
...@@ -25,13 +25,13 @@ template< ...@@ -25,13 +25,13 @@ template<
class VectorType, class VectorType,
class BitVectorType = Dune::BitSetVector<VectorType::block_type::dimension>, class BitVectorType = Dune::BitSetVector<VectorType::block_type::dimension>,
class MatrixType = Dune::BCRSMatrix< typename Dune::FieldMatrix< class MatrixType = Dune::BCRSMatrix< typename Dune::FieldMatrix<
typename VectorType::field_type, VectorType::block_type::size, VectorType::block_type::size> > > typename VectorType::field_type, VectorType::block_type::dimension, VectorType::block_type::dimension> > >
class TruncatedCompressedMGTransfer : class TruncatedCompressedMGTransfer :
public CompressedMultigridTransfer<VectorType, BitVectorType, MatrixType>, public CompressedMultigridTransfer<VectorType, BitVectorType, MatrixType>,
public TruncatedMGTransfer<VectorType, BitVectorType, MatrixType> public TruncatedMGTransfer<VectorType, BitVectorType, MatrixType>
{ {
enum {blocksize = VectorType::block_type::size}; enum {blocksize = VectorType::block_type::dimension};
typedef typename VectorType::field_type field_type; typedef typename VectorType::field_type field_type;
......
...@@ -24,13 +24,13 @@ template< ...@@ -24,13 +24,13 @@ template<
class VectorType, class VectorType,
class BitVectorType = Dune::BitSetVector<VectorType::block_type::dimension>, class BitVectorType = Dune::BitSetVector<VectorType::block_type::dimension>,
class MatrixType = Dune::BCRSMatrix< typename Dune::FieldMatrix< class MatrixType = Dune::BCRSMatrix< typename Dune::FieldMatrix<
typename VectorType::field_type, VectorType::block_type::size, VectorType::block_type::size> > > typename VectorType::field_type, VectorType::block_type::dimension, VectorType::block_type::dimension> > >
class TruncatedDenseMGTransfer : class TruncatedDenseMGTransfer :
public DenseMultigridTransfer<VectorType, BitVectorType, MatrixType>, public DenseMultigridTransfer<VectorType, BitVectorType, MatrixType>,
public TruncatedMGTransfer<VectorType, BitVectorType, MatrixType> public TruncatedMGTransfer<VectorType, BitVectorType, MatrixType>
{ {
enum {blocksize = VectorType::block_type::size}; enum {blocksize = VectorType::block_type::dimension};
typedef typename VectorType::field_type field_type; typedef typename VectorType::field_type field_type;
......
...@@ -21,11 +21,11 @@ template< ...@@ -21,11 +21,11 @@ template<
class VectorType, class VectorType,
class BitVectorType = Dune::BitSetVector<VectorType::block_type::dimension>, class BitVectorType = Dune::BitSetVector<VectorType::block_type::dimension>,
class MatrixType = Dune::BCRSMatrix< typename Dune::FieldMatrix< class MatrixType = Dune::BCRSMatrix< typename Dune::FieldMatrix<
typename VectorType::field_type, VectorType::block_type::size, VectorType::block_type::size> > > typename VectorType::field_type, VectorType::block_type::dimension, VectorType::block_type::dimension> > >
class TruncatedMGTransfer class TruncatedMGTransfer
{ {
enum {blocksize = VectorType::block_type::size}; enum {blocksize = VectorType::block_type::dimension};
typedef typename VectorType::field_type field_type; typedef typename VectorType::field_type field_type;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment