Namespaces | Macros

Definitions of geometry vector data types. More...

#include "Math/GenVector/CoordinateSystemTags.h"
#include "Math/GenVector/Cartesian3D.h"
#include "Math/GenVector/PositionVector3D.h"
#include "Math/GenVector/DisplacementVector3D.h"
#include "Math/GenVector/Rotation3D.h"
#include "RVersion.h"

Go to the source code of this file.

Namespaces

 geo
 LArSoft geometry interface.
 

Macros

#define GENVECTOR_CONSTEXPR
 A declaration is made constexpr if GenVector supports it. More...
 

Functions

Vector types for the standard LArSoft geometry.

LArSoft geometry provides two main types of vectors in 3D space:

  1. geo::Point_t to describe an absolute position in global coordinates
  2. geo::Vector_t to describe a displacement or direction (or momentum!)

Both vectors are supposed to represent:

  • centimeters in double precision when used on the real geometry space
  • in the global coordinate system, which is represented by the tag geo::GlobalCoords.

These types constitute the basic objects the geometry works with.

All interfaces should support them.

Note
As this requires some transition, please report any interface missing support for these types by opening a "necessary maintenance" request in the LArSoft issue tracker at https://cdcvs.fnal.gov/redmine/projects/larsoft/issues . Even if there are plenty.

The same type of vectors, but in a different coordinate system representation, can be obtained by using geo::Point3DBase_t template:

(geo::Vector3DBase_t is also available). If a single precision vector is desired, the most general geo::GenPoint3DBase_t and geo::GenVector3DBase_t are also available:

template<typename Vector = Vector_t>
constexpr Vector geo::Xaxis ()
 Returns a x axis vector of the specified type. More...
 
template<typename Vector = Vector_t>
constexpr Vector geo::Yaxis ()
 Returns a y axis vector of the specified type. More...
 
template<typename Vector = Vector_t>
constexpr Vector geo::Zaxis ()
 Returns a z axis vector of the specified type. More...
 
template<typename Point = Point_t>
constexpr Point geo::origin ()
 Returns a origin position with a point of the specified type. More...
 

Detailed Description

Definitions of geometry vector data types.

Author
Gianluca Petrillo (petri.nosp@m.llo@.nosp@m.fnal..nosp@m.gov)
Date
March 23, 2017

This library depends on ROOT GenVector. In the CET link list in CMakeLists.txt, link to ROOT::GenVector.

Additional utilities are available from geo_vectors_utils.h.

Definition in file geo_vectors.h.

Macro Definition Documentation

#define GENVECTOR_CONSTEXPR

A declaration is made constexpr if GenVector supports it.

This macro defines as "constexpr", only if GenVector's vector types can be used as constexpr.

Currently the implementation is quite lame, since it does not autodetect whether GenVector library supports the feature or not, and it assumes it doesn't. So this becomes basically a placeholder to remind the maintainers to replace it with an actual constexpr when that will be supported. To make maintainers not forget this, it will explode on each new ROOT version.

A feature request to ROOT was opened as JIRA 9320.

See also Fermilab Redmine issue #19476 (https://cdcvs.fnal.gov/redmine/issues/19476).

Definition at line 46 of file geo_vectors.h.