Commit 836978e9 authored by Praetorius, Simon's avatar Praetorius, Simon
Browse files

removed all trailing whitespaces in all git files

parent 5f0ca3b5
// Software License for MTL
//
//
// Copyright (c) 2007 The Trustees of Indiana University.
// 2008 Dresden University of Technology and the Trustees of Indiana University.
// 2010 SimuNova UG (haftungsbeschränkt), www.simunova.com.
// All rights reserved.
// Authors: Peter Gottschling and Andrew Lumsdaine
//
//
// This file is part of the Matrix Template Library
//
//
// See also license.mtl.txt in the distribution.
#ifndef META_MATH_LOG_2_INCLUDE
......
// Software License for MTL
//
//
// Copyright (c) 2007 The Trustees of Indiana University.
// 2008 Dresden University of Technology and the Trustees of Indiana University.
// 2010 SimuNova UG (haftungsbeschränkt), www.simunova.com.
// All rights reserved.
// Authors: Peter Gottschling and Andrew Lumsdaine
//
//
// This file is part of the Matrix Template Library
//
//
// See also license.mtl.txt in the distribution.
#ifndef META_MATH_LOOP_INCLUDE
......
// Software License for MTL
//
//
// Copyright (c) 2007 The Trustees of Indiana University.
// 2008 Dresden University of Technology and the Trustees of Indiana University.
// 2010 SimuNova UG (haftungsbeschränkt), www.simunova.com.
// All rights reserved.
// Authors: Peter Gottschling and Andrew Lumsdaine
//
//
// This file is part of the Matrix Template Library
//
//
// See also license.mtl.txt in the distribution.
#ifndef META_MATH_LOOP1_INCLUDE
......
// Software License for MTL
//
//
// Copyright (c) 2007 The Trustees of Indiana University.
// 2008 Dresden University of Technology and the Trustees of Indiana University.
// 2010 SimuNova UG (haftungsbeschränkt), www.simunova.com.
// All rights reserved.
// Authors: Peter Gottschling and Andrew Lumsdaine
//
//
// This file is part of the Matrix Template Library
//
//
// See also license.mtl.txt in the distribution.
#ifndef META_MATH_LOOP2_INCLUDE
......
// Software License for MTL
//
//
// Copyright (c) 2007 The Trustees of Indiana University.
// 2008 Dresden University of Technology and the Trustees of Indiana University.
// 2010 SimuNova UG (haftungsbeschränkt), www.simunova.com.
// All rights reserved.
// Authors: Peter Gottschling and Andrew Lumsdaine
//
//
// This file is part of the Matrix Template Library
//
//
// See also license.mtl.txt in the distribution.
#ifndef META_MATH_LOOP3_INCLUDE
......@@ -27,7 +27,7 @@ struct loop3
};
template <std::size_t Index0, std::size_t Max0, std::size_t Index1, std::size_t Max1,
template <std::size_t Index0, std::size_t Max0, std::size_t Index1, std::size_t Max1,
std::size_t Max2>
struct loop3<Index0, Max0, Index1, Max1, Max2, Max2>
{
......@@ -75,7 +75,7 @@ struct loop3_trace : public loop3<Index0, Max0, Index1, Max1, Index2, Max2>
{
std::cout << this->index0 << " : " << this->index1 << " : " << this->index2 << "\n";
next_t() ();
}
}
};
......@@ -86,7 +86,7 @@ struct loop3_trace<Max0, Max0, Max1, Max1, Max2, Max2>
void operator() ()
{
std::cout << this->index0 << " : " << this->index1 << " : " << this->index2 << "\n";
}
}
};
#endif
......
// Software License for MTL
//
//
// Copyright (c) 2007 The Trustees of Indiana University.
// 2008 Dresden University of Technology and the Trustees of Indiana University.
// 2010 SimuNova UG (haftungsbeschränkt), www.simunova.com.
// All rights reserved.
// Authors: Peter Gottschling and Andrew Lumsdaine
//
//
// This file is part of the Matrix Template Library
//
//
// See also license.mtl.txt in the distribution.
#ifndef META_MATH_MAX_INCLUDE
......
// Software License for MTL
//
//
// Copyright (c) 2007 The Trustees of Indiana University.
// 2008 Dresden University of Technology and the Trustees of Indiana University.
// 2010 SimuNova UG (haftungsbeschränkt), www.simunova.com.
// All rights reserved.
// Authors: Peter Gottschling and Andrew Lumsdaine
//
//
// This file is part of the Matrix Template Library
//
//
// See also license.mtl.txt in the distribution.
#ifndef META_MATH_MIN_INCLUDE
......
// Software License for MTL
//
//
// Copyright (c) 2007 The Trustees of Indiana University.
// 2008 Dresden University of Technology and the Trustees of Indiana University.
// 2010 SimuNova UG (haftungsbeschränkt), www.simunova.com.
// All rights reserved.
// Authors: Peter Gottschling and Andrew Lumsdaine
//
//
// This file is part of the Matrix Template Library
//
//
// See also license.mtl.txt in the distribution.
#ifndef META_MATH_POWER_OF_2_INCLUDE
......
// Software License for MTL
//
//
// Copyright (c) 2007 The Trustees of Indiana University.
// 2008 Dresden University of Technology and the Trustees of Indiana University.
// 2010 SimuNova UG (haftungsbeschränkt), www.simunova.com.
// All rights reserved.
// Authors: Peter Gottschling and Andrew Lumsdaine
//
//
// This file is part of the Matrix Template Library
//
//
// See also license.mtl.txt in the distribution.
#ifndef META_MATH_SQRT_INCLUDE
......@@ -39,7 +39,7 @@ namespace impl {
// If the condition becomes true the guessed root will be the returned value
template <long int guess, long int x>
struct sqrt_impl<guess, x, true>
struct sqrt_impl<guess, x, true>
{
static long int const value = guess;
};
......@@ -47,11 +47,11 @@ namespace impl {
}
template <long int x>
struct sqrt
struct sqrt
{
typedef long int type;
static long int const value = impl::sqrt_impl<1, x, false>::value;
};
};
} // namespace meta_math
......
// Software License for MTL
//
//
// Copyright (c) 2007 The Trustees of Indiana University.
// 2008 Dresden University of Technology and the Trustees of Indiana University.
// 2010 SimuNova UG (haftungsbeschränkt), www.simunova.com.
// All rights reserved.
// Authors: Peter Gottschling and Andrew Lumsdaine
//
//
// This file is part of the Matrix Template Library
//
//
// See also license.mtl.txt in the distribution.
#ifndef MTL_COLLECTION_INCLUDE
......@@ -19,7 +19,7 @@
#ifdef __GXX_CONCEPTS__
# include <concepts>
#else
#else
# include <boost/numeric/linear_algebra/pseudo_concept.hpp>
# include <boost/numeric/mtl/concept/std_concept.hpp>
#endif
......@@ -101,7 +101,7 @@ namespace mtl {
};
#else
/// Concept AlgebraicCollection: common requirements of matrices, vectors, and scalars in computations
/** For more design clarity we consider them all as matrices (as Matlab does) and we regard
/** For more design clarity we consider them all as matrices (as Matlab does) and we regard
Scalar and Vector as special cases (see there). However, the implementation of vectors
is supposed to differ from the ones of matrices in order to provide efficient computations and storage.
\par Refinement of:
......@@ -132,11 +132,11 @@ namespace mtl {
static Collection<T>::size_type T::static_num_rows;
static Collection<T>::size_type T::static_num_cols;
static Collection<T>::size_type T::static_size;
#endif
#endif
};
#else
/// Concept ConstantSizeAlgebraicCollection: extension of AlgebraicCollection with meta-functions
/** This concept is used for algebraic collections with sizes known at compile time.
/** This concept is used for algebraic collections with sizes known at compile time.
The motivation is that if the size of the collection is
is small, arithmetic operations can be unrolled at compile time.
......@@ -151,7 +151,7 @@ namespace mtl {
- Number of elements: \n static_size<X>::value
\n Sematics: static_num_rows<X>::value * static_size<X>::value
\note
-# For more design clarity we consider them all as matrices (as Matlab does) and we regard
-# For more design clarity we consider them all as matrices (as Matlab does) and we regard
Scalar and Vector as special cases (see there). However, the implementation of vectors
is supposed to differ from the ones of matrices in order to provide efficient computations and storage.
......@@ -199,11 +199,11 @@ namespace mtl {
/// Associated type: return type of tagged begin and end function
typedef associated_type cursor_type;
/// Tagged free function that returns a cursor or iterator at the begin of an interval
/// Tagged free function that returns a cursor or iterator at the begin of an interval
/** The interval is specified by the Tag, i.e. the function is called begin<Tag>(c); */
cursor_type begin(const C& c);
/// Tagged free function that returns a cursor or iterator at the end of an interval
/// Tagged free function that returns a cursor or iterator at the end of an interval
/** The interval is specified by the Tag, i.e. the function is called end<Tag>(c); */
cursor_type end(const C& c);
};
......@@ -236,11 +236,11 @@ namespace mtl {
/// Associated type: return type of tagged begin function
typedef associated_type cursor_type;
/// Tagged free function that returns a cursor or iterator at the begin of an interval
/// Tagged free function that returns a cursor or iterator at the begin of an interval
/** The interval is specified by the Tag, i.e. the function is called begin<Tag>(c); */
cursor_type begin(const C& c);
/// Tagged free function that returns a cursor or iterator at the end of an interval
/// Tagged free function that returns a cursor or iterator at the end of an interval
/** The interval is specified by the Tag, i.e. the function is called end<Tag>(c); */
cursor_type end(const C& c);
};
......@@ -471,7 +471,7 @@ namespace mtl {
typedef typename matrix::rscaled_view<Coll,RScaling>::size_type size_type;
};
#endif
#ifdef __GXX_CONCEPTS__
......@@ -489,14 +489,14 @@ namespace mtl {
// typedef typename Functor::result_type value_type;
// typedef typename Functor::result_type const_reference;
// typedef typename Collection<Coll>::size_type size_type;
typedef typename vector::map_view<Functor, Coll>::value_type value_type;
typedef typename vector::map_view<Functor, Coll>::const_reference const_reference;
typedef typename vector::map_view<Functor, Coll>::size_type size_type;
};
#endif
#ifdef __GXX_CONCEPTS__
#else
......@@ -598,7 +598,7 @@ namespace mtl {
{
typedef typename Collection<E1>::value_type value_type;
typedef value_type const_reference;
typedef typename Collection<E1>::size_type size_type;
typedef typename Collection<E1>::size_type size_type;
};
#endif
......@@ -908,7 +908,7 @@ namespace mtl {
#else
template< typename Matrix, typename Vector>
struct Collection<mtl::mat_cvec_times_expr<Matrix, Vector> >
struct Collection<mtl::mat_cvec_times_expr<Matrix, Vector> >
{
typedef typename Collection< Matrix >::value_type value_type;
typedef const value_type& const_reference;
......@@ -955,7 +955,7 @@ namespace mtl {
#ifdef __GXX_CONCEPTS__
#else
template <class E1, class E2, typename SFunctor>
template <class E1, class E2, typename SFunctor>
struct Collection<mtl::vector::vec_vec_ele_prod_expr<E1, E2, SFunctor> >
{
typedef typename Multiplicable<typename Collection<E1>::value_type,
......@@ -967,7 +967,7 @@ namespace mtl {
#ifdef __GXX_CONCEPTS__
#else
template <class E1, class E2, typename SFunctor>
template <class E1, class E2, typename SFunctor>
struct Collection<mtl::vector::vec_vec_pmop_expr<E1, E2, SFunctor> >
{
typedef typename Addable<typename Collection<E1>::value_type,
......@@ -979,7 +979,7 @@ namespace mtl {
#ifdef __GXX_CONCEPTS__
#else
template <class E1, class E2, typename SFunctor>
template <class E1, class E2, typename SFunctor>
struct Collection<mtl::vector::vec_vec_op_expr<E1, E2, SFunctor> >
{
typedef typename SFunctor::result_type value_type;
......@@ -990,7 +990,7 @@ namespace mtl {
#ifdef __GXX_CONCEPTS__
#else
template <class E1, class E2, typename SFunctor>
template <class E1, class E2, typename SFunctor>
struct Collection<mtl::vector::vec_vec_aop_expr<E1, E2, SFunctor> >
{
typedef typename Collection<E1>::value_type value_type;
......@@ -1309,7 +1309,7 @@ namespace mtl {
};
#endif
#ifdef __GXX_CONCEPTS__
template <typename Scaling, typename Coll>
concept_map OrientedCollection< mtl::vector::scaled_view<Scaling, Coll> >
......@@ -1349,7 +1349,7 @@ namespace mtl {
};
#endif
#ifdef __GXX_CONCEPTS__
template <typename Coll>
concept_map OrientedCollection<matrix::conj_view<Coll> >
......
// Software License for MTL
//
//
// Copyright (c) 2007 The Trustees of Indiana University.
// 2008 Dresden University of Technology and the Trustees of Indiana University.
// 2010 SimuNova UG (haftungsbeschränkt), www.simunova.com.
// All rights reserved.
// Authors: Peter Gottschling and Andrew Lumsdaine
//
//
// This file is part of the Matrix Template Library
//
//
// See also license.mtl.txt in the distribution.
#ifndef MTL_MAGNITUDE_INCLUDE
......@@ -60,7 +60,7 @@ auto concept RealMagnitude<typename T>
/// Concept/Type-trait for magnitudes of scalar values
/** This name is overloaded: when MTL4 is compiled with a concept-compiler
Magnitude is a concept otherwise a type-trait.
It is used for instance in norms.
It is used for instance in norms.
**/
template <typename T>
struct Magnitude
......
// Software License for MTL
//
//
// Copyright (c) 2007 The Trustees of Indiana University.
// 2008 Dresden University of Technology and the Trustees of Indiana University.
// 2010 SimuNova UG (haftungsbeschränkt), www.simunova.com.
// All rights reserved.
// Authors: Peter Gottschling and Andrew Lumsdaine
//
//
// This file is part of the Matrix Template Library
//
//
// See also license.mtl.txt in the distribution.
#ifndef MTL_MATRIX_CONCEPT_INCLUDE
......@@ -18,7 +18,7 @@
#ifdef __GXX_CONCEPTS__
# include <concepts>
#else
#else
# include <boost/numeric/linear_algebra/pseudo_concept.hpp>
#endif
......@@ -48,7 +48,7 @@ namespace mtl {
- A is an object of type X
- r, c are objects of size_type
\par Valid expressions:
- Element access: \n A(r, c) \n Return Type: const_reference
- Element access: \n A(r, c) \n Return Type: const_reference
\n Semantics: Element in row \p r and column \p c
- Element access: \n A[r][c] \n Equivalent to A(r, c)
\par Models:
......@@ -61,7 +61,7 @@ namespace mtl {
of element access by A(r, c).
-# The name const_reference does not imply that the return type is necessarily referrable. For instance compressed2D
returns value_type.
*/
*/
template <typename T>
struct Matrix
: public AlgebraicCollection<T>
......@@ -71,7 +71,7 @@ namespace mtl {
};
#endif
#ifdef __GXX_CONCEPTS__
concept MatrixInserter<typename T>
......@@ -80,15 +80,15 @@ namespace mtl {
// typename T::matrix_type;
requires Matrix<matrix_type>;
typename proxy_type;
proxy_type operator() (Matrix<matrix_type>::size_type row, Matrix<matrix_type>::size_type col);
T operator<< (proxy_type, Matrix<matrix_type>::value_type>);
};
#else
/// Concept MatrixInserter: classes that enable efficient insertion into matrices, esp. compressed sparse.
/**
/**
Used to fill non-mutable matrices like compressed2D. Matrix inserters might be parametrizable with
update functor. This allow to perform different operations when entry already exist, e.g. overwriting,
incrementing, minimum, ... The most important updates are certainly overwrite and increment (add).
......@@ -98,7 +98,7 @@ namespace mtl {
\par Requires:
- Matrix<matrix_type>
\par Notation:
- X is a type that models MatrixInserter
- A is an object of type X
......@@ -135,7 +135,7 @@ namespace mtl {
};
#else
/// Concept InsertableMatrix: %matrix that can be filled by means of inserter
/**
/**
\par Requires:
- MatrixInserter < mtl::matrix::inserter< T > >
\par Models:
......@@ -172,7 +172,7 @@ namespace mtl {
- A is an object of type X
- r, c are objects of size_type
\par Valid expressions:
- Element access: \n A(r, c) \n Return Type: reference
- Element access: \n A(r, c) \n Return Type: reference
\n Semantics: Element in row \p r and column \p c
- Element access: \n A[r][c] \n Equivalent to A(r, c)
\par Models:
......@@ -182,7 +182,7 @@ namespace mtl {
-# The access via A[r][c] is supposed to be implemented by means of A(r, c) (typically via CRTP and proxies).
If it would become (extremely) important to support 2D C arrays, it might be necessary to drop the requirement
of element access by A(r, c).
*/
*/
template <typename T>
struct MutableMatrix
: public Matrix<T>,
......@@ -193,7 +193,7 @@ namespace mtl {
};
#endif
#ifdef __GXX_CONCEPTS__
concept ConstantSizeMatrix<typename T>
: Matrix<T>,
......@@ -205,7 +205,7 @@ namespace mtl {
\par Refinement of:
- Matrix < T >
- ConstantSizeAlgebraicCollection < T >
*/
*/
template <typename T>
struct ConstantSizeMatrix
: public Matrix<T>,
......@@ -225,7 +225,7 @@ namespace mtl {
/**
\par Refinement of:
- Matrix < T >
*/
*/
template <typename T>
struct ResizeableMatrix
: public Matrix<T>
......@@ -240,15 +240,15 @@ namespace mtl {
#ifdef __GXX_CONCEPTS__
concept RowTraversableMatrix<typename M>
: Matrix<M>,
TraversableCollection<mtl::tag::row, M>
TraversableCollection<mtl::tag::row, M>
{};
#else
/// Concept RowTraversableMatrix: provides begin and end cursor to traverse rows
/**
\par Refinement of:
- Matrix < M >
- TraversableCollection <mtl::tag::row, M>
*/
- TraversableCollection <mtl::tag::row, M>
*/
template <typename M>
struct RowTraversableMatrix
: public Matrix<M>,
......@@ -256,19 +256,19 @@ namespace mtl {
{};
#endif
#ifdef __GXX_CONCEPTS__
concept ColumnTraversableMatrix<typename M>
: Matrix<M>,
TraversableCollection<mtl::tag::col, M>
TraversableCollection<mtl::tag::col, M>
{};
#else
/// Concept ColumnTraversableMatrix: provides begin and end cursor to traverse columns
/**
\par Refinement of:
- Matrix < M >
- TraversableCollection <mtl::tag::col, M>
*/
- TraversableCollection <mtl::tag::col, M>
*/
template <typename M>
struct ColumnTraversableMatrix
: public Matrix<M>,
......@@ -280,7 +280,7 @@ namespace mtl {
#ifdef __GXX_CONCEPTS__
concept MajorTraversableMatrix<typename M>
: Matrix<M>,
TraversableCollection<mtl::tag::major, M>
TraversableCollection<mtl::tag::major, M>
{};
#else
/// Concept MajorTraversableMatrix: traversable on major dimension
......@@ -290,22 +290,22 @@ namespace mtl {
The cursors begin and end are provided.
\par Refinement of:
- Matrix < M >
- TraversableCollection <mtl::tag::major, M>
- TraversableCollection <mtl::tag::major, M>
\note
-# This traversal corresponds to the iterator design in MTL 2.
*/
*/
template <typename M>
struct MajorTraversableMatrix
: public Matrix<M>,
public TraversableCollection<mtl::tag::major, M>
{};
#endif
#ifdef __GXX_CONCEPTS__
concept MinorTraversableMatrix<typename M>
: Matrix<M>,
TraversableCollection<mtl::tag::minor, M>
TraversableCollection<mtl::tag::minor, M>
{};
#else
/// Concept MinorTraversableMatrix: traversable on minor dimension
......@@ -315,22 +315,22 @@ namespace mtl {
The cursors begin and end are provided.
\par Refinement of:
- Matrix < M >
- TraversableCollection <mtl::tag::minor, M>
- TraversableCollection <mtl::tag::minor, M>
\note
-# This traversal corresponds to the iterator design in MTL 2.
*/
*/
template <typename M>
struct MinorTraversableMatrix