Belle II Software development
TOPWavelengthFilter.h
1/**************************************************************************
2 * basf2 (Belle II Analysis Software Framework) *
3 * Author: The Belle II Collaboration *
4 * *
5 * See git log for contributors and copyright holders. *
6 * This file is licensed under LGPL-3.0, see LICENSE.md. *
7 **************************************************************************/
8
9#pragma once
10
11#include <top/dbobjects/TOPGeoBase.h>
12#include <vector>
13
14namespace Belle2 {
24 public:
25
30 {}
31
39 TOPWavelengthFilter(float lambdaFirst, float lambdaStep,
40 const std::vector<float>& trEffi,
41 const std::string& name = "TOPWavelengthFilter"): TOPGeoBase(name),
42 m_lambdaFirst(lambdaFirst), m_lambdaStep(lambdaStep), m_transmittances(trEffi)
43 {}
44
49 const std::vector<float>& getBulkTransmittances() const {return m_transmittances;}
50
56 float getBulkTransmittance(double lambda) const;
57
62 float getLambdaFirst() const {return m_lambdaFirst;}
63
68 float getLambdaStep() const {return m_lambdaStep;}
69
74 bool isConsistent() const override;
75
80 void print(const std::string& title = "Wavelength filter bulk transmittance") const override;
81
82
83 private:
84
85 float m_lambdaFirst = 0;
86 float m_lambdaStep = 0;
87 std::vector<float> m_transmittances;
91 };
92
94} // end namespace Belle2
95
96
Base class for geometry parameters.
Definition: TOPGeoBase.h:25
Bulk transmittance of wavelength filter.
ClassDefOverride(TOPWavelengthFilter, 1)
ClassDef.
TOPWavelengthFilter()
Default constructor.
float getLambdaStep() const
Returns wavelength step.
float getLambdaFirst() const
Returns wavelength of the first data point.
float m_lambdaStep
wavelength step [nm]
const std::vector< float > & getBulkTransmittances() const
Returns bulk transmittance data points.
std::vector< float > m_transmittances
bulk transmittance data points
float m_lambdaFirst
wavelength of the first data point [nm]
TOPWavelengthFilter(float lambdaFirst, float lambdaStep, const std::vector< float > &trEffi, const std::string &name="TOPWavelengthFilter")
Full constructor.
bool isConsistent() const override
Check for consistency of data members.
void print(const std::string &title="Wavelength filter bulk transmittance") const override
Print the content of the class.
float getBulkTransmittance(double lambda) const
Returns bulk transmittance at given wavelength using linear interpolation.
Abstract base class for different kinds of events.