|
2 | 2 |
|
3 | 3 | ## Overview
|
4 | 4 |
|
5 |
| -To run specific models, each folder contains a |
6 |
| -Makefile that can simply be run inside a specific model folder. |
7 |
| -The workflow includes running WolframScript to generate matrix elements, using Python to generate collision data, and finally processing the data with the main Python script. |
| 5 | +This folder contains individual model directories, each equipped with a Python script to calculate the wall velocity specific to that model. Additional files within each model directory support the computation of matrix elements and collision integrations. |
8 | 6 |
|
9 | 7 | ## Directory Structure
|
10 | 8 |
|
11 |
| -- `MatrixElements/` - Contains the script and data files for matrix element generation. |
12 |
| -- `CollisionOutput/` - Directory where collision data files are stored. |
| 9 | +Each model directory includes the following files and subdirectories: |
| 10 | +- `<nameOfModel>.py' - Contains the model definition and the commands for finding the wall velocity. |
| 11 | +- `<nameOfModel>Config.ini' - An optional configuration file containing model-specific configuration settings. (Note: This file is not included for the Yukawa model.) |
| 12 | +- `exampleCollisionDefs.py' - Defines collision generation settings specific to the model. |
| 13 | +- `MatrixElements/` - A subdirectory holding scripts (with .m extensions) used for generating matrix elements, as well as a .json file containing the computed matrix elements. |
| 14 | +- `CollisionOutput_N<spatialGridSize>/` - Subdirectories for storing collision data files for each pair of out-of-equilibrium particles, with each folder corresponding to a specific spatial grid size. |
13 | 15 |
|
| 16 | +Additionally, the Models folder contains a common utility file: |
14 | 17 |
|
15 |
| -## Makefile Targets |
| 18 | +- `wallGoExampleBase.py' - This script provides a shared template for wall velocity computations. It is used by all models except the Yukawa model. |
16 | 19 |
|
17 |
| -### `all` |
| 20 | +## Running a model |
18 | 21 |
|
19 |
| -This is the default target which runs the `model` target. |
| 22 | +The examples can be run directly with e.g. |
20 | 23 |
|
21 |
| -### `generateMatrixElements` |
22 |
| -Generates matrix Elements at `MatrixElements.txt` from |
23 |
| -`MatrixElements/<Model>.m` |
24 |
| -as sometimes only the matrix elements need to be generated. |
| 24 | + python3 Models/SingletStandardModel_Z2/singletStandardModelZ2.py |
| 25 | + |
| 26 | +For models that use the common `wallGoExampleBase.py', additional command line arguments are available to (re)calculate matrix elements and collisions, and adjust the momentum grid size e.g. |
25 | 27 |
|
26 |
| -### `model` |
27 |
| -Runs only the model file |
28 |
| -`<model-name>.py` |
29 |
| -as sometimes no new matrix elements or collision integrals need to be generated. |
| 28 | + python3 Models/SingletStandardModel_Z2/singletStandardModelZ2.py --recalculateMatrixElements -- recalculateCollisions --momentumGridSize 5 |
30 | 29 |
|
31 |
| -### `generate_collisions` |
| 30 | +## Requirements |
32 | 31 |
|
33 |
| -Generates collision data files using the matrix elements. This target depends on `MatrixElements.txt`, which is generated by running a WolframScript file. |
34 |
| - |
35 |
| -### `clean` |
36 |
| - |
37 |
| -Removes the `CollisionOutput` and `MatrixElements` directories and all their contents. |
38 |
| - |
39 |
| -## Dependencies |
40 |
| - |
41 |
| -- `python3` - Required for running Python scripts. |
42 |
| -- `wolframscript` - Required for running the WolframScript file to generate matrix elements. |
43 |
| - |
44 |
| - |
45 |
| -- `matrixElements.m` - |
46 |
| - MatrixElement script based on DRalgo. |
47 |
| - See [https://github.com/Wall-Go/MatrixElements](https://github.com/Wall-Go/MatrixElements). |
48 |
| -- `DRalgo` - See [https://github.com/DR-algo/DRalgo](https://github.com/DR-algo/DRalgo). |
49 |
| - |
50 |
| -Both `matrixElements.m` and the `DRalgo` folder should be placed in a directory visible to Mathematica. The best options are to place it in the Applications subfolder of |
51 |
| -`$BaseDirectory` or `$UserBaseDirectory`. |
52 |
| -Often, the paths are the following: |
53 |
| - |
54 |
| -### For Linux |
55 |
| - |
56 |
| - /usr/share/Mathematica/Applications |
57 |
| - /home/<computer-name>/.Mathematica/Applications |
58 |
| - |
59 |
| -### For Windows |
60 |
| - |
61 |
| - C:\ProgramData\Mathematica\Applications |
62 |
| - C:\Users\<computer-name>\AppData\Roaming\Mathematica\Applications |
63 |
| - |
64 |
| -## Usage |
65 |
| - |
66 |
| -### Full pipeline |
67 |
| -1. **Generate Collisions**: |
68 |
| - Ensure that the matrix elements data file `MatrixElements.txt` exists, then generate collision data by running: |
69 |
| - ```sh |
70 |
| - make generate_collisions |
71 |
| - ``` |
72 |
| - |
73 |
| -2. **Run Main (Model) Script**: |
74 |
| - Once collision data files are generated, run the main Python script: |
75 |
| - ```sh |
76 |
| - make model |
77 |
| - ``` |
78 |
| - |
79 |
| -4. **Clean Up**: |
80 |
| - To clean up the generated collision data files and matrix elements: |
81 |
| - ```sh |
82 |
| - make clean |
83 |
| - ``` |
84 |
| - |
85 |
| -### Matrix Elements |
86 |
| -1. **Generate Matrix Elements**: |
87 |
| - In that case it suffices to run: |
88 |
| - ```sh |
89 |
| - make generateMatrixElements |
90 |
| - ``` |
91 |
| - |
92 |
| -## File Descriptions |
93 |
| - |
94 |
| -- `MatrixElements/matrixElements.qcd.m` - WolframScript file for generating matrix elements. |
95 |
| -- `MatrixElements.txt` - Output data file containing matrix elements. |
96 |
| -- `collisionGenerator.py` - Python script for generating collision data. |
97 |
| -- `<model-name>.py` - Main Python Model script that uses the collision data e.g. `SingletStandardModel_Z2.py` |
98 |
| - |
99 |
| -## Notes |
100 |
| - |
101 |
| -- Ensure that the necessary Python and WolframScript dependencies are installed and properly configured in your environment. |
102 |
| -- The `CollisionOutput` directory is automatically created if it does not exist when running the `generate_collisions` target. |
| 32 | +Running the model files requires a valid installation of [**WallGo**](https://github.com/Wall-Go/WallGo) . Generation of new matrix elements and collisions furthermore requires installations of [**WallGoMatrix**](https://github.com/Wall-Go/WallGoMatrix) and [**WallGoCollision**](https://github.com/Wall-Go/WallGoCollision) respectively. |
0 commit comments