Computes the cross product of vectors. More...
#include "viennagrid/forwards.h"
#include "viennagrid/traits/point.hpp"
#include "viennagrid/point.hpp"
Go to the source code of this file.
Data Structures | |
struct | cross_prod_impl< PointType, 1 > |
Implementation of the cross product calculation in 1d for compatibility. Returns the zero-vector. More... | |
struct | cross_prod_impl< PointType, 2 > |
Implementation of the cross product calculation in 2d for compatibility. Returns the zero-vector. More... | |
struct | cross_prod_impl< PointType, 3 > |
Implementation of the cross product calculation in 3d. More... | |
Namespaces | |
namespace | viennagrid |
The main ViennaGrid namespace. Most functionality resides in this namespace. | |
namespace | viennagrid::detail |
The namespace holding the implementations of domains, segments and ncells as well as some algorithm implementations. Not of interest for library users. | |
Functions | |
template<typename PointType1 , typename PointType2 , typename CSystem1 , typename CSystem2 > | |
PointType1 | cross_prod_impl (PointType1 const &p1, PointType2 const &p2, CSystem1 const &, CSystem2 const &) |
Dispatched cross product function having information about the coordinate systems. Transforms to Cartesian coordinates and forwards to calculation. | |
template<typename PointType1 , typename PointType2 , long d> | |
PointType1 | cross_prod_impl (PointType1 const &p1, PointType2 const &p2, cartesian_cs< d >, cartesian_cs< d >) |
Dispatched cross product function having information about the coordinate systems. Points are already in Cartesian coordinates, thus forwarding to the worker function directly. | |
template<typename PointType1 , typename PointType2 > | |
PointType1 | cross_prod (PointType1 const &v1, PointType2 const &v2) |
Returns the cross product of two vectors. If the vectors have one or two components only, the zero vector is returned. |
Computes the cross product of vectors.