Belle II Software development
ShaperDSP_t::shaperdspshift_t Struct Reference

struct for a shift of the shaper dsp More...

#include <shaperdsp.h>

Inheritance diagram for ShaperDSP_t::shaperdspshift_t:
ShaperDSP_t::sv123shift_t

Public Member Functions

 shaperdspshift_t ()
 default constructor
 
 shaperdspshift_t (double _t, const ShaperDSP_t &_p)
 constructor from a ShaperDSP class
 
void init (double, const ShaperDSP_t &)
 initialise
 
shaperdspshift_toperator+= (const shaperdspshift_t &)
 increment operator
 
shaperdspshift_t operator+ (const shaperdspshift_t &) const
 addition operator
 
sv123shift_toperator+= (const sv123shift_t &)
 increment operator
 
sv123shift_t operator+ (const sv123shift_t &) const
 addition operator
 
bool validshift (const sv123shift_t &x) const
 check for a valid shift
 

Public Attributes

double et0
 shift parameter 0
 
double et1
 shift parameter 1
 
double t
 time

 
double s0
 sin of the first Bessel stage

 
double c0
 cos of the first Bessel stage

 
double s1
 sin of the second Bessel stage

 
double c1
 cos of the second Bessel stage

 
double e0
 exponent factor for first Bessel stage

 
double e1
 exponent factor for second Bessel stage

 
double es
 first exponent factor for tail part of the signal.
 
double ed
 second exponent factor for tail part of the signal.
 

Detailed Description

struct for a shift of the shaper dsp

Definition at line 59 of file shaperdsp.h.

Constructor & Destructor Documentation

◆ shaperdspshift_t() [1/2]

shaperdspshift_t ( )
inline

default constructor

Definition at line 63 of file shaperdsp.h.

◆ shaperdspshift_t() [2/2]

shaperdspshift_t ( double  _t,
const ShaperDSP_t _p 
)
inline

constructor from a ShaperDSP class

Definition at line 64 of file shaperdsp.h.

Member Function Documentation

◆ init()

void init ( double  _t,
const ShaperDSP_t _p 
)

initialise

Definition at line 79 of file shaperdsp.cc.

80{
81 sv123shift_t::init(_t, _p);
82 et0 = exp(-t * _p._dt0);
83 et1 = exp(-t * _p._dt1);
84}
double _dt0
coefficient for first exponent factor
Definition: shaperdsp.h:102
double _dt1
coefficient for second exponent factor
Definition: shaperdsp.h:104
void init(double, const ShaperDSP_t &)
initialise
Definition: shaperdsp.cc:30

◆ operator+() [1/2]

ShaperDSP_t::shaperdspshift_t operator+ ( const shaperdspshift_t r) const

addition operator

Definition at line 96 of file shaperdsp.cc.

97{
98 const sv123shift_t& r0 = static_cast<const ShaperDSP_t::sv123shift_t&>(r);
100 sv123shift_t& a0 = static_cast<ShaperDSP_t::sv123shift_t&>(a);
101
103 a.et0 = et0 * r.et0;
104 a.et1 = et1 * r.et1;
105 return a;
106}
struct to encapsulate the electronic response from energy deposit
Definition: shaperdsp.h:30
sv123shift_t operator+(const sv123shift_t &) const
addition operator
Definition: shaperdsp.cc:62
sv123shift_t()
default constructor
Definition: shaperdsp.h:50

◆ operator+() [2/2]

ShaperDSP_t::sv123shift_t operator+ ( const sv123shift_t r) const
inherited

addition operator

Definition at line 62 of file shaperdsp.cc.

63{
65 a.t = t + r.t;
66
67 a.c0 = r.c0 * c0 - r.s0 * s0;
68 a.s0 = r.c0 * s0 + r.s0 * c0;
69 a.c1 = r.c1 * c1 - r.s1 * s1;
70 a.s1 = r.c1 * s1 + r.s1 * c1;
71
72 a.e0 = e0 * r.e0;
73 a.e1 = e1 * r.e1;
74 a.es = es * r.es;
75 a.ed = ed * r.ed;
76 return a;
77}
double e0
exponent factor for first Bessel stage
Definition: shaperdsp.h:42
double es
first exponent factor for tail part of the signal.
Definition: shaperdsp.h:46
double c0
cos of the first Bessel stage
Definition: shaperdsp.h:36
double s1
sin of the second Bessel stage
Definition: shaperdsp.h:38
double ed
second exponent factor for tail part of the signal.
Definition: shaperdsp.h:48
double c1
cos of the second Bessel stage
Definition: shaperdsp.h:40
double s0
sin of the first Bessel stage
Definition: shaperdsp.h:34
double e1
exponent factor for second Bessel stage
Definition: shaperdsp.h:44

◆ operator+=() [1/2]

ShaperDSP_t::shaperdspshift_t & operator+= ( const shaperdspshift_t r)

increment operator

Definition at line 86 of file shaperdsp.cc.

87{
88 const sv123shift_t& r0 = static_cast<const ShaperDSP_t::sv123shift_t&>(r);
89
91 et0 *= r.et0;
92 et1 *= r.et1;
93 return *this;
94}
sv123shift_t & operator+=(const sv123shift_t &)
increment operator
Definition: shaperdsp.cc:41

◆ operator+=() [2/2]

ShaperDSP_t::sv123shift_t & operator+= ( const sv123shift_t r)
inherited

increment operator

Definition at line 41 of file shaperdsp.cc.

42{
43 t += r.t;
44
45 double c0r = r.c0 * c0 - r.s0 * s0;
46 double s0r = r.c0 * s0 + r.s0 * c0;
47 c0 = c0r;
48 s0 = s0r;
49
50 double c1r = r.c1 * c1 - r.s1 * s1;
51 double s1r = r.c1 * s1 + r.s1 * c1;
52 c1 = c1r;
53 s1 = s1r;
54
55 e0 *= r.e0;
56 e1 *= r.e1;
57 es *= r.es;
58 ed *= r.ed;
59 return *this;
60}

◆ validshift()

bool validshift ( const sv123shift_t x) const
inlineinherited

check for a valid shift

Definition at line 55 of file shaperdsp.h.

Member Data Documentation

◆ c0

double c0
inherited

cos of the first Bessel stage

Definition at line 36 of file shaperdsp.h.

◆ c1

double c1
inherited

cos of the second Bessel stage

Definition at line 40 of file shaperdsp.h.

◆ e0

double e0
inherited

exponent factor for first Bessel stage

Definition at line 42 of file shaperdsp.h.

◆ e1

double e1
inherited

exponent factor for second Bessel stage

Definition at line 44 of file shaperdsp.h.

◆ ed

double ed
inherited

second exponent factor for tail part of the signal.

Time of the differential stage

Definition at line 48 of file shaperdsp.h.

◆ es

double es
inherited

first exponent factor for tail part of the signal.

Scintillation decay time

Definition at line 46 of file shaperdsp.h.

◆ et0

double et0

shift parameter 0

Definition at line 60 of file shaperdsp.h.

◆ et1

double et1

shift parameter 1

Definition at line 61 of file shaperdsp.h.

◆ s0

double s0
inherited

sin of the first Bessel stage

Definition at line 34 of file shaperdsp.h.

◆ s1

double s1
inherited

sin of the second Bessel stage

Definition at line 38 of file shaperdsp.h.

◆ t

double t
inherited

time

Definition at line 32 of file shaperdsp.h.


The documentation for this struct was generated from the following files: