All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
vector_float_double.cpp File Reference
`#include <iostream>`
`#include <iomanip>`
`#include <cmath>`
`#include "viennacl/vector.hpp"`
`#include "viennacl/vector_proxy.hpp"`
`#include "viennacl/linalg/inner_prod.hpp"`
`#include "viennacl/linalg/norm_1.hpp"`
`#include "viennacl/linalg/norm_2.hpp"`
`#include "viennacl/linalg/norm_inf.hpp"`
`#include "viennacl/linalg/maxmin.hpp"`
`#include "viennacl/linalg/sum.hpp"`
`#include "viennacl/tools/random.hpp"`

Go to the source code of this file.

## Classes

class | vector_proxy< NumericT >

## Macros

#define | GENERATE_UNARY_OP_TEST(FUNCNAME)

## Functions

template<typename NumericT >
void | proxy_copy (vector_proxy< NumericT > const &host_vec, viennacl::vector_base< NumericT > &vcl_vec)
template<typename NumericT >
void | proxy_copy (viennacl::vector_base< NumericT > const &vcl_vec, vector_proxy< NumericT > &host_vec)
template<typename ScalarType >
ScalarType | diff (ScalarType const &s1, ScalarType const &s2)
template<typename ScalarType >
ScalarType | diff (ScalarType const &s1, viennacl::scalar< ScalarType > const &s2)
template<typename ScalarType >
ScalarType | diff (ScalarType const &s1, viennacl::entry_proxy< ScalarType > const &s2)
template<typename ScalarType , typename ViennaCLVectorType >
ScalarType | diff (vector_proxy< ScalarType > const &v1, ViennaCLVectorType const &vcl_vec)
template<typename T1 , typename T2 >
int | check (T1 const &t1, T2 const &t2, double epsilon)
template<typename NumericT , typename Epsilon , typename HostVectorType , typename ViennaCLVectorType1 , typename ViennaCLVectorType2 >
int | test (Epsilon const &epsilon, HostVectorType &host_v1, HostVectorType &host_v2, ViennaCLVectorType1 &vcl_v1, ViennaCLVectorType2 &vcl_v2)
template<typename NumericT , typename Epsilon >
int | test (Epsilon const &epsilon)
int | main ()

## Detailed Description

Tests vector operations (BLAS level 1) for floating point arithmetic.

Test:
  Tests vector operations (BLAS level 1) for floating point arithmetic.

Definition in file vector_float_double.cpp.

## Macro Definition Documentation

#define GENERATE_UNARY_OP_TEST | ( |  | FUNCNAME | ) |

## Function Documentation

template<typename T1 , typename T2 >

int check | ( | T1 const & | t1,
|  | T2 const & | t2,
|  | double | epsilon
| ) |  |

Definition at line 148 of file vector_float_double.cpp.

template<typename ScalarType >

ScalarType diff | ( | ScalarType const & | s1,
|  | ScalarType const & | s2
| ) |  |

Definition at line 93 of file vector_float_double.cpp.

template<typename ScalarType >

ScalarType diff | ( | ScalarType const & | s1,
|  | viennacl::scalar< ScalarType > const & | s2
| ) |  |

Definition at line 104 of file vector_float_double.cpp.

template<typename ScalarType >

ScalarType diff | ( | ScalarType const & | s1,
|  | viennacl::entry_proxy< ScalarType > const & | s2
| ) |  |

Definition at line 115 of file vector_float_double.cpp.

template<typename ScalarType , typename ViennaCLVectorType >

ScalarType diff | ( | vector_proxy< ScalarType > const & | v1,
|  | ViennaCLVectorType const & | vcl_vec
| ) |  |

Definition at line 126 of file vector_float_double.cpp.

int main | ( |  | ) |

Definition at line 2239 of file vector_float_double.cpp.

template<typename NumericT >

void proxy_copy | ( | vector_proxy< NumericT > const & | host_vec,
|  | viennacl::vector_base< NumericT > & | vcl_vec
| ) |  |

Definition at line 67 of file vector_float_double.cpp.

template<typename NumericT >

void proxy_copy | ( | viennacl::vector_base< NumericT > const & | vcl_vec,
|  | vector_proxy< NumericT > & | host_vec
| ) |  |

Definition at line 78 of file vector_float_double.cpp.

template<typename NumericT , typename Epsilon , typename HostVectorType , typename ViennaCLVectorType1 , typename ViennaCLVectorType2 >

int test | ( | Epsilon const & | epsilon,
|  | HostVectorType & | host_v1,
|  | HostVectorType & | host_v2,
|  | ViennaCLVectorType1 & | vcl_v1,
|  | ViennaCLVectorType2 & | vcl_v2
| ) |  |

Definition at line 166 of file vector_float_double.cpp.

template<typename NumericT , typename Epsilon >

int test | ( | Epsilon const & | epsilon | ) |

Definition at line 2064 of file vector_float_double.cpp.