ALPS MPS Codes
Reference documentation.
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
alps.hpp
Go to the documentation of this file.
1 /*****************************************************************************
2  *
3  * ALPS MPS DMRG Project
4  *
5  * Copyright (C) 2013 Institute for Theoretical Physics, ETH Zurich
6  * 2011-2012 by Michele Dolfi <dolfim@phys.ethz.ch>
7  *
8  * This software is part of the ALPS Applications, published under the ALPS
9  * Application License; you can use, redistribute it and/or modify it under
10  * the terms of the license, either version 1 or (at your option) any later
11  * version.
12  *
13  * You should have received a copy of the ALPS Application License along with
14  * the ALPS Applications; see the file LICENSE.txt. If not, the license is also
15  * available from http://alps.comp-phys.org/.
16  *
17  * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
18  * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
19  * FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. IN NO EVENT
20  * SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE
21  * FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE,
22  * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
23  * DEALINGS IN THE SOFTWARE.
24  *
25  *****************************************************************************/
26 
27 #ifndef MAQUIS_BLOCK_MATRIX_DEATAIL_ALPS_HPP
28 #define MAQUIS_BLOCK_MATRIX_DEATAIL_ALPS_HPP
29 
30 #include <alps/numeric/matrix.hpp>
31 #include <alps/numeric/matrix/algorithms.hpp>
32 #include <alps/numeric/diagonal_matrix.hpp>
35 #include "utils/traits.hpp"
36 
37 namespace maquis { namespace traits {
38 
39  template <typename T, typename MemoryBlock>
40  struct transpose_view< alps::numeric::matrix<T, MemoryBlock> > { typedef alps::numeric::transpose_view<alps::numeric::matrix<T, MemoryBlock> > type; };
41 
42  template <typename T>
43  struct transpose_view< alps::numeric::diagonal_matrix<T> > { typedef alps::numeric::diagonal_matrix<T> type; };
44 
45 } }
46 
47 namespace alps { namespace numeric {
48 
49  template<class Matrix> struct associated_one_matrix { };
50  template<class Matrix> struct associated_dense_matrix { };
51 
52  template<typename T, typename MemoryBlock>
53  struct associated_one_matrix<alps::numeric::matrix<T, MemoryBlock> > { typedef maquis::dmrg::one_matrix<T> type; };
54 
55  template<typename T, class MemoryBlock>
57 
58  template<typename T>
59  struct associated_dense_matrix<maquis::dmrg::one_matrix<T> > { typedef alps::numeric::matrix<T> type; };
60 
61 } }
62 
63 #endif
alps::numeric::transpose_view< alps::numeric::matrix< T, MemoryBlock > > type
Definition: alps.hpp:40
alps::numeric::matrix< double > matrix
Definition: matrices.h:40