STIR  6.2.0
cross_product.h
Go to the documentation of this file.
1 #ifndef __stir_cross_product_H__
2 #define __stir_cross_product_H__
3 //
4 //
5 /*
6  Copyright (C) 2003- 2005, Hammersmith Imanet Ltd
7  This file is part of STIR.
8 
9  SPDX-License-Identifier: Apache-2.0
10 
11  See STIR/LICENSE.txt for details
12 */
23 
24 START_NAMESPACE_STIR
25 
37 template <class coordT>
38 CartesianCoordinate3D<coordT>
40 {
42  a.y() * b.x() - a.x() * b.y(), -a.z() * b.x() + a.x() * b.z(), a.z() * b.y() - a.y() * b.z());
43 };
44 
45 END_NAMESPACE_STIR
46 
47 #endif
a templated class for 3-dimensional coordinates.
Definition: CartesianCoordinate3D.h:52
defines the stir::CartesianCoordinate3D<coordT> class
CartesianCoordinate3D< coordT > cross_product(const CartesianCoordinate3D< coordT > &a, const CartesianCoordinate3D< coordT > &b)
the cross-product for 3-dimensional coordinates.
Definition: cross_product.h:39