Belle II Software
release-05-01-25
GFGeant4Field.h
1
/**************************************************************************
2
* Belle II detector background library *
3
* Copyright(C) 2011 Belle II Collaboration *
4
* *
5
* Author: The Belle II Collaboration *
6
* Contributors: Andreas Moll, Martin Heck *
7
* *
8
* This software is provided "as is" without any warranty. *
9
**************************************************************************/
10
#pragma once
11
#include <framework/geometry/BFieldManager.h>
12
#include <framework/gearbox/Unit.h>
13
#include <genfit/AbsBField.h>
14
17
class
GFGeant4Field
:
public
genfit::AbsBField
{
18
public
:
25
GFGeant4Field
():
genfit::AbsBField
() {}
26
32
TVector3
get
(
const
TVector3& position)
const override
33
{
34
static
double
conversion{1. /
Belle2::Unit::kGauss
};
35
return
Belle2::BFieldManager::getField
(position) * conversion;
36
}
37
};
38
Belle2::BFieldManager::getField
static void getField(const double *pos, double *field)
return the magnetic field at a given position.
Definition:
BFieldManager.h:110
Belle2::Unit::kGauss
static const double kGauss
[kilogauss]
Definition:
Unit.h:133
genfit::AbsBField
Abstract Interface to magnetic fields in GENFIT.
Definition:
AbsBField.h:36
GFGeant4Field::get
TVector3 get(const TVector3 &position) const override
Getter for the magnetic field.
Definition:
GFGeant4Field.h:40
GFGeant4Field::GFGeant4Field
GFGeant4Field()
Constructor.
Definition:
GFGeant4Field.h:33
GFGeant4Field
Interface of the Belle II B-field with GenFit.
Definition:
GFGeant4Field.h:17
tracking
gfbfield
include
GFGeant4Field.h
Generated on Fri Nov 5 2021 04:00:31 for Belle II Software by
1.8.17