fwd.hpp 6.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217
  1. //
  2. // Copyright (c) 2000-2010
  3. // Joerg Walter, Mathias Koch, David Bellot
  4. //
  5. // Distributed under the Boost Software License, Version 1.0. (See
  6. // accompanying file LICENSE_1_0.txt or copy at
  7. // http://www.boost.org/LICENSE_1_0.txt)
  8. //
  9. // The authors gratefully acknowledge the support of
  10. // GeNeSys mbH & Co. KG in producing this work.
  11. //
  12. /// \file fwd.hpp is essentially used to forward declare the main types
  13. #ifndef BOOST_UBLAS_FWD_H
  14. #define BOOST_UBLAS_FWD_H
  15. #include <memory>
  16. namespace boost { namespace numeric { namespace ublas {
  17. // Storage types
  18. template<class T, class ALLOC = std::allocator<T> >
  19. class unbounded_array;
  20. template<class T, std::size_t N, class ALLOC = std::allocator<T> >
  21. class bounded_array;
  22. template <class Z = std::size_t, class D = std::ptrdiff_t>
  23. class basic_range;
  24. template <class Z = std::size_t, class D = std::ptrdiff_t>
  25. class basic_slice;
  26. typedef basic_range<> range;
  27. typedef basic_slice<> slice;
  28. template<class A = unbounded_array<std::size_t> >
  29. class indirect_array;
  30. template<class I, class T, class ALLOC = std::allocator<std::pair<const I, T> > >
  31. class map_std;
  32. template<class I, class T, class ALLOC = std::allocator<std::pair<I, T> > >
  33. class map_array;
  34. // Expression types
  35. struct scalar_tag {};
  36. struct vector_tag {};
  37. template<class E>
  38. class vector_expression;
  39. template<class C>
  40. class vector_container;
  41. template<class E>
  42. class vector_reference;
  43. struct matrix_tag {};
  44. template<class E>
  45. class matrix_expression;
  46. template<class C>
  47. class matrix_container;
  48. template<class E>
  49. class matrix_reference;
  50. template<class V>
  51. class vector_range;
  52. template<class V>
  53. class vector_slice;
  54. template<class V, class IA = indirect_array<> >
  55. class vector_indirect;
  56. template<class M>
  57. class matrix_row;
  58. template<class M>
  59. class matrix_column;
  60. template<class M>
  61. class matrix_vector_range;
  62. template<class M>
  63. class matrix_vector_slice;
  64. template<class M, class IA = indirect_array<> >
  65. class matrix_vector_indirect;
  66. template<class M>
  67. class matrix_range;
  68. template<class M>
  69. class matrix_slice;
  70. template<class M, class IA = indirect_array<> >
  71. class matrix_indirect;
  72. template<class T, class A = unbounded_array<T> >
  73. class vector;
  74. template<class T, std::size_t N>
  75. class bounded_vector;
  76. template<class T = int, class ALLOC = std::allocator<T> >
  77. class unit_vector;
  78. template<class T = int, class ALLOC = std::allocator<T> >
  79. class zero_vector;
  80. template<class T = int, class ALLOC = std::allocator<T> >
  81. class scalar_vector;
  82. template<class T, std::size_t N>
  83. class c_vector;
  84. // Sparse vectors
  85. template<class T, class A = map_std<std::size_t, T> >
  86. class mapped_vector;
  87. template<class T, std::size_t IB = 0, class IA = unbounded_array<std::size_t>, class TA = unbounded_array<T> >
  88. class compressed_vector;
  89. template<class T, std::size_t IB = 0, class IA = unbounded_array<std::size_t>, class TA = unbounded_array<T> >
  90. class coordinate_vector;
  91. // Matrix orientation type
  92. struct unknown_orientation_tag {};
  93. struct row_major_tag {};
  94. struct column_major_tag {};
  95. // Matrix storage layout parameterisation
  96. template <class Z = std::size_t, class D = std::ptrdiff_t>
  97. struct basic_row_major;
  98. typedef basic_row_major<> row_major;
  99. template <class Z = std::size_t, class D = std::ptrdiff_t>
  100. struct basic_column_major;
  101. typedef basic_column_major<> column_major;
  102. template<class T, class L = row_major, class A = unbounded_array<T> >
  103. class matrix;
  104. template<class T, std::size_t M, std::size_t N, class L = row_major>
  105. class bounded_matrix;
  106. template<class T = int, class ALLOC = std::allocator<T> >
  107. class identity_matrix;
  108. template<class T = int, class ALLOC = std::allocator<T> >
  109. class zero_matrix;
  110. template<class T = int, class ALLOC = std::allocator<T> >
  111. class scalar_matrix;
  112. template<class T, std::size_t M, std::size_t N>
  113. class c_matrix;
  114. template<class T, class L = row_major, class A = unbounded_array<unbounded_array<T> > >
  115. class vector_of_vector;
  116. template<class T, class L = row_major, class A = vector<compressed_vector<T> > >
  117. class generalized_vector_of_vector;
  118. // Triangular matrix type
  119. struct lower_tag {};
  120. struct upper_tag {};
  121. struct unit_lower_tag : public lower_tag {};
  122. struct unit_upper_tag : public upper_tag {};
  123. struct strict_lower_tag : public lower_tag {};
  124. struct strict_upper_tag : public upper_tag {};
  125. // Triangular matrix parameterisation
  126. template <class Z = std::size_t>
  127. struct basic_full;
  128. typedef basic_full<> full;
  129. template <class Z = std::size_t>
  130. struct basic_lower;
  131. typedef basic_lower<> lower;
  132. template <class Z = std::size_t>
  133. struct basic_upper;
  134. typedef basic_upper<> upper;
  135. template <class Z = std::size_t>
  136. struct basic_unit_lower;
  137. typedef basic_unit_lower<> unit_lower;
  138. template <class Z = std::size_t>
  139. struct basic_unit_upper;
  140. typedef basic_unit_upper<> unit_upper;
  141. template <class Z = std::size_t>
  142. struct basic_strict_lower;
  143. typedef basic_strict_lower<> strict_lower;
  144. template <class Z = std::size_t>
  145. struct basic_strict_upper;
  146. typedef basic_strict_upper<> strict_upper;
  147. // Special matrices
  148. template<class T, class L = row_major, class A = unbounded_array<T> >
  149. class banded_matrix;
  150. template<class T, class L = row_major, class A = unbounded_array<T> >
  151. class diagonal_matrix;
  152. template<class T, class TRI = lower, class L = row_major, class A = unbounded_array<T> >
  153. class triangular_matrix;
  154. template<class M, class TRI = lower>
  155. class triangular_adaptor;
  156. template<class T, class TRI = lower, class L = row_major, class A = unbounded_array<T> >
  157. class symmetric_matrix;
  158. template<class M, class TRI = lower>
  159. class symmetric_adaptor;
  160. template<class T, class TRI = lower, class L = row_major, class A = unbounded_array<T> >
  161. class hermitian_matrix;
  162. template<class M, class TRI = lower>
  163. class hermitian_adaptor;
  164. // Sparse matrices
  165. template<class T, class L = row_major, class A = map_std<std::size_t, T> >
  166. class mapped_matrix;
  167. template<class T, class L = row_major, class A = map_std<std::size_t, map_std<std::size_t, T> > >
  168. class mapped_vector_of_mapped_vector;
  169. template<class T, class L = row_major, std::size_t IB = 0, class IA = unbounded_array<std::size_t>, class TA = unbounded_array<T> >
  170. class compressed_matrix;
  171. template<class T, class L = row_major, std::size_t IB = 0, class IA = unbounded_array<std::size_t>, class TA = unbounded_array<T> >
  172. class coordinate_matrix;
  173. }}}
  174. #endif