HPS-MC
Loading...
Searching...
No Matches
test_func.py
Go to the documentation of this file.
1
import
unittest
2
import
hpsmc.func
3
4
5
class
TestLint
(unittest.TestCase):
6
7
def
test_lint_1pt1
(self):
8
res = 6.306e-14 * 0.0004062 * 625
9
self.assertEqual(
hpsmc.func.lint
(0.0004062, 625), res)
10
11
def
test_lint_1pt92
(self):
12
res = 6.306e-14 * 0.0008 * 875
13
self.assertEqual(
hpsmc.func.lint
(0.0008, 875), res)
14
15
def
test_lint_1pt05
(self):
16
res = 6.306e-14 * 0.0004062 * 625
17
self.assertEqual(
hpsmc.func.lint
(0.0004062, 625), res)
18
19
def
test_lint_2pt2
(self):
20
res = 6.306e-14 * 0.0004062 * 2500
21
self.assertEqual(
hpsmc.func.lint
(0.0004062, 2500), res)
22
23
def
test_lint_2pt3
(self):
24
res = 6.306e-14 * 0.0004062 * 2500
25
self.assertEqual(
hpsmc.func.lint
(0.0004062, 2500), res)
26
27
def
test_lint_3pt7
(self):
28
res = 6.306e-14 * 0.002 * 1500
29
self.assertEqual(
hpsmc.func.lint
(0.002, 1500), res)
30
31
def
test_lint_3pt74
(self):
32
res = 6.306e-14 * 0.000875 * 625
33
self.assertEqual(
hpsmc.func.lint
(0.000875, 625), res)
34
35
def
test_lint_3pt742
(self):
36
res = 6.306e-14 * 0.002 * 1500
37
self.assertEqual(
hpsmc.func.lint
(0.002, 1500), res)
38
39
def
test_lint_4pt4
(self):
40
res = 6.306e-14 * 0.0004062 * 5000
41
self.assertEqual(
hpsmc.func.lint
(0.0004062, 5000), res)
42
43
def
test_lint_4pt55
(self):
44
res = 6.306e-14 * 0.002 * 1500
45
self.assertEqual(
hpsmc.func.lint
(0.002, 1500), res)
46
47
def
test_lint_6pt6
(self):
48
res = 6.306e-14 * 0.000875 * 5625
49
self.assertEqual(
hpsmc.func.lint
(0.000875, 5625), res)
50
51
52
if
__name__ ==
'__main__'
:
53
unittest.main()
test.test_func.TestLint
Definition
test_func.py:5
test.test_func.TestLint.test_lint_1pt92
test_lint_1pt92(self)
Definition
test_func.py:11
test.test_func.TestLint.test_lint_3pt7
test_lint_3pt7(self)
Definition
test_func.py:27
test.test_func.TestLint.test_lint_6pt6
test_lint_6pt6(self)
Definition
test_func.py:47
test.test_func.TestLint.test_lint_3pt742
test_lint_3pt742(self)
Definition
test_func.py:35
test.test_func.TestLint.test_lint_2pt3
test_lint_2pt3(self)
Definition
test_func.py:23
test.test_func.TestLint.test_lint_3pt74
test_lint_3pt74(self)
Definition
test_func.py:31
test.test_func.TestLint.test_lint_4pt55
test_lint_4pt55(self)
Definition
test_func.py:43
test.test_func.TestLint.test_lint_4pt4
test_lint_4pt4(self)
Definition
test_func.py:39
test.test_func.TestLint.test_lint_1pt1
test_lint_1pt1(self)
Definition
test_func.py:7
test.test_func.TestLint.test_lint_1pt05
test_lint_1pt05(self)
Definition
test_func.py:15
test.test_func.TestLint.test_lint_2pt2
test_lint_2pt2(self)
Definition
test_func.py:19
hpsmc.func
Miscellaneous math functions.
Definition
func.py:1
hpsmc.func.lint
lint(target_dz, num_electrons, density=6.306e-14)
Calculate integrated luminosity.
Definition
func.py:9
python
test
test_func.py
Generated by
1.9.8