Skip to content

Commit e6d3e4e

Browse files
authored
Add files via upload
1 parent dc75ebf commit e6d3e4e

File tree

15 files changed

+2220
-0
lines changed

15 files changed

+2220
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
import numpy as np
2+
3+
#################################################### Defined relaxation rates ####################################################
4+
5+
RelaxationRates = ["R2", "R1", "Sigma", "R1H"]
6+
7+
#################################################### Variables ####################################################
8+
9+
PositionAuto = 0
10+
pA = 1.0
11+
Anisotropy1 = 'NO'
12+
13+
Names = {'OrderParam': ['Sf2','Ss2'], 'CorrTimes': ['tm','tf','ts'], 'others': ['CSApC']}
14+
15+
def ImportFunc():
16+
import _R2calculation
17+
import _R1calculation
18+
import _Sigmacalculation
19+
import _R1Hcalculation
20+
21+
rates_func = {}
22+
rates_func['R1'] = _R1calculation.R1calculation
23+
rates_func['R2'] = _R2calculation.R2calculation
24+
rates_func['Sigma'] = _Sigmacalculation.Sigmacalculation
25+
rates_func['R1H'] = _R1Hcalculation.R1Hcalculation
26+
27+
return rates_func
28+
29+
30+
31+
32+
33+
def Cons(X):
34+
Sf2, Ss2, tm, tf, ts, CSApC, lnf = X
35+
if 0.0 < Sf2 < 1.0 and 0.0 < Ss2 < 1.0 and 0.0 < tm < tf < ts < 30.0e-9 and 0.0 < CSApC < 35.0 and -10. < lnf < 1.:
36+
return 0.0
37+
else:
38+
return -np.inf

Models/CHD2_ExtendedModelFree/Rates.c

+114
Large diffs are not rendered by default.

Models/CHD2_ExtendedModelFree/Rates.h

+14
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
struct mat2d {
2+
3+
double m[3][3];
4+
5+
};
6+
7+
8+
9+
struct mat2d RelaxMatrix(double Bo, double *X, double *Tauc, double *OtherInputs );
10+
11+
double R2calculation(double Bo, double *X, double *Tauc, double *OtherInputs );
12+
double R1calculation(double Bo, double *X, double *Tauc, double *OtherInputs );
13+
double Sigmacalculation(double Bo, double *X, double *Tauc, double *OtherInputs );
14+
double R1Hcalculation(double Bo, double *X, double *Tauc, double *OtherInputs );

0 commit comments

Comments
 (0)