added flexibility
This commit is contained in:
78
README.md
78
README.md
@@ -3,24 +3,80 @@
|
||||
1. Clone repository with `git clone https://gitea.pkm.physik.tu-darmstadt.de/NMRRWSims/cpp.git`
|
||||
2. After download, change permissions of build.sh in terminal with `chmod a+x build.sh`
|
||||
|
||||
# Setup the simulation
|
||||
# Build
|
||||
|
||||
The workflows leaves yet much to be desired, it will become better (maybe)
|
||||
This
|
||||
|
||||
## Changes in `test.py`
|
||||
# Running
|
||||
|
||||
## Command line
|
||||
|
||||
To run a random walk simulation Execute `rwsim` in the command line with
|
||||
|
||||
```bash
|
||||
./rwsim /path/to/config.txt MotionModel DistributionModel --ste --spectrum -ARG1 1 -ARG2 2
|
||||
```
|
||||
|
||||
It needs three positional arguments: the path to your basic configuration file (see below) and the names of the motional model and of the distribution of correlation times.
|
||||
Set the optional arguments `--ste` and/or `--spectrum` to create Stimulated Echos or normal echo spectra, respectively.
|
||||
You can overwrite any parameter given in the configuration file by adding it as optional argument with a numerical value, e.g. `-TAU 1e-3` for a correlation time of 1 ms.
|
||||
|
||||
|
||||
## Configuration file `config.txt`
|
||||
|
||||
Change the values of delta, eta, mixing times, echo times,... in this file. If a paramter is defined multiple times, only the last one is used.
|
||||
|
||||
### General parameter
|
||||
|
||||
This list of general parameter are necessary for all simulations:
|
||||
|
||||
| Parameter | Description |
|
||||
|------------|----------------------------|
|
||||
| num_walker | Number of trajectories |
|
||||
| delta | Anisotropy parameter in Hz |
|
||||
| eta | Asymmetry parameter |
|
||||
|
||||
### Distribution of correlation times
|
||||
|
||||
Two distributions are available: A delta distribution `Delta`, i.e. the same correlation time for every walker, and a log-normal distribution `LogNormal`.
|
||||
|
||||
+ Parameters for delta distribution `Delta`
|
||||
|
||||
| Parameter | Description |
|
||||
|-----------|-----------------------|
|
||||
| tau | Jump time in s |
|
||||
|
||||
+ Parameters for log-normal distribution `LogNormal`
|
||||
|
||||
| Parameter | Description |
|
||||
|-----------|--------------------------------------------|
|
||||
| tau | Maximum jump time of the distribution in s |
|
||||
| sigma | Standard deviation of the distribution |
|
||||
|
||||
### Motion models
|
||||
|
||||
Four different jump models are implemented: Isotropic random jump `RandomJump`, isotropic jump with a certain angle, isotropic jump with a bimodal distribution of angles, and a tetrahedral jump `TetrahedralJump`.
|
||||
|
||||
+ Isotropic random jump `RandomJump` does not have additional parameters.
|
||||
+ Tetrahedral jump `TetrahedralJump` does not have additional parameters.
|
||||
+ Parameters for isotropic jump by an angle `IsotropicAngle`
|
||||
|
||||
| Parameter | Description |
|
||||
|-----------|----------------------|
|
||||
| angle | Jump angle in degree |
|
||||
|
||||
+ Parameters for isotropic jump with bimodal angle distribution `BimodalAngle`
|
||||
|
||||
| Parameter | Description |
|
||||
|--------------|--------------------------------------|
|
||||
| angle1 | First jump angle in degree |
|
||||
| angle2 | Second jump angle in degree |
|
||||
| probability1 | Probality that jump has angle1 (0-1) |
|
||||
|
||||
1. To run spectra, add `-spectrum` in line 14
|
||||
2. To run STE, add `-ste` in line 14
|
||||
3. Change values for tau, line broadening and pulse length in lines 88-90 (to simulate one tau value, set length of array to 1)
|
||||
4. Comment / Uncomment `post_process_ste` or `post_process_spectrum`.
|
||||
|
||||
## Change of models
|
||||
|
||||
1. In `main.cpp`, uncomment the motional model and distribution of correlation times you want to use, comment every other model
|
||||
|
||||
## Setting more parameters in `config.txt`
|
||||
|
||||
1. Change the values of delta, eta, mixing times, echo times,... in this file. If a paramter is defined multiple times, only the last one is used.
|
||||
|
||||
# Running
|
||||
|
||||
|
||||
Reference in New Issue
Block a user