ViennaCL - The Vienna Computing Library  1.5.2
norm_frobenius.hpp
Go to the documentation of this file.
1 #ifndef VIENNACL_LINALG_NORM_FROBENIUS_HPP_
2 #define VIENNACL_LINALG_NORM_FROBENIUS_HPP_
3 
4 /* =========================================================================
5  Copyright (c) 2010-2014, Institute for Microelectronics,
6  Institute for Analysis and Scientific Computing,
7  TU Wien.
8  Portions of this software are copyright by UChicago Argonne, LLC.
9 
10  -----------------
11  ViennaCL - The Vienna Computing Library
12  -----------------
13 
14  Project Head: Karl Rupp rupp@iue.tuwien.ac.at
15 
16  (A list of authors and contributors can be found in the PDF manual)
17 
18  License: MIT (X11), see file LICENSE in the base directory
19 ============================================================================= */
20 
25 #include <cmath>
26 #include "viennacl/forwards.h"
27 #include "viennacl/tools/tools.hpp"
29 #include "viennacl/meta/tag_of.hpp"
30 
31 namespace viennacl
32 {
33  //
34  // generic norm_frobenius function
35  // uses tag dispatch to identify which algorithm
36  // should be called
37  //
38  namespace linalg
39  {
40 
41  #ifdef VIENNACL_WITH_UBLAS
42  // ----------------------------------------------------
43  // UBLAS
44  //
45  template< typename VectorT >
47  typename VectorT::value_type
48  >::type
49  norm_frobenius(VectorT const& v1)
50  {
52  }
53  #endif
54 
55 
56  // ----------------------------------------------------
57  // VIENNACL
58  //
59  template<typename NumericT, typename F>
60  scalar_expression< const matrix_base<NumericT, F>, const matrix_base<NumericT, F>, op_norm_frobenius>
62  {
64  }
65 
66  } // end namespace linalg
67 } // end namespace viennacl
68 #endif
69 
70 
71 
72 
73 
Simple enable-if variant that uses the SFINAE pattern.
Definition: enable_if.hpp:29
Dispatch facility for distinguishing between ublas, STL and ViennaCL types.
Various little tools used here and there in ViennaCL.
A dense matrix class.
Definition: forwards.h:290
This file provides the forward declarations for the main types used within ViennaCL.
A dense matrix class.
Definition: forwards.h:293
A proxy for scalar expressions (e.g. from inner vector products)
Definition: forwards.h:175
scalar_expression< const matrix_base< NumericT, F >, const matrix_base< NumericT, F >, op_norm_frobenius > norm_frobenius(const matrix< NumericT, F > &A)
Definition: norm_frobenius.hpp:61
A tag class representing the Frobenius-norm of a matrix.
Definition: forwards.h:162
Simple enable-if variant that uses the SFINAE pattern.