Browse Source

Add shortcut scripts to run the c_scan_k_fixed over set of nk

master
Jean-Sébastien 2 years ago
parent
commit
4fa46e0cac

+ 45
- 0
scripts/build_LiebLin_c_scan_k_fixed_set.sh View File

@@ -0,0 +1,45 @@
1
+#! /bin/zsh
2
+
3
+# Builds the set of c_scans for nk = 1 up to nkmax.
4
+
5
+if [[ $# -ne 5 ]]; then
6
+    echo "Arguments needed: whichDSF, kBT, target_sumrule, N, nkmax (max momentum in units of kF/4)."
7
+    exit 1
8
+fi
9
+
10
+if [[ $1 != 'd' && $1 != 'g' && $1 != 'o' ]]; then
11
+    echo "Only the d, g and o scanning options are implemented."
12
+    exit 1
13
+fi
14
+
15
+if [[ $2 -lt 0 ]]; then
16
+    echo "Temperature kBT must be > 0."
17
+    exit 1
18
+fi
19
+
20
+if [[ $3 -lt 0 || $3 -gt 1 ]]; then
21
+    echo "Requirement: 0 < target_sumrule < 1."
22
+    exit 1
23
+fi
24
+
25
+if [[ $4 -lt 0 ]]; then
26
+    echo "N must be > 0."
27
+    exit 1
28
+fi
29
+
30
+if [[ $5 -lt 0 ]]; then
31
+    echo "nkmax must be > 0."
32
+    exit 1
33
+fi
34
+
35
+
36
+whichDSF=$1
37
+kBT=$2
38
+target_sumrule=$3
39
+N=$4
40
+nkmax=$5
41
+
42
+for nk in {1..$nkmax}
43
+do
44
+    build_LiebLin_c_scan_k_fixed.sh $whichDSF $kBT $target_sumrule $N $nk
45
+done

+ 54
- 0
scripts/build_LiebLin_c_scan_k_fixed_set_plots.sh View File

@@ -0,0 +1,54 @@
1
+#! /bin/zsh
2
+
3
+# Builds the set of plots for a `build_LiebLin_c_scan_k_fixed_set` run.
4
+
5
+if [[ $# -ne 6 ]]; then
6
+    echo "Arguments needed: whichDSF, kBT, target_sumrule, N, nkmax (max momentum in units of kF/4), width."
7
+    exit 1
8
+fi
9
+
10
+if [[ $1 != 'd' && $1 != 'g' && $1 != 'o' ]]; then
11
+    echo "Only the d, g and o scanning options are implemented."
12
+    exit 1
13
+fi
14
+
15
+if [[ $2 -lt 0 ]]; then
16
+    echo "Temperature kBT must be > 0."
17
+    exit 1
18
+fi
19
+
20
+if [[ $3 -lt 0 || $3 -gt 1 ]]; then
21
+    echo "Requirement: 0 < target_sumrule < 1."
22
+    exit 1
23
+fi
24
+
25
+if [[ $4 -lt 0 ]]; then
26
+    echo "N must be > 0."
27
+    exit 1
28
+fi
29
+
30
+if [[ $5 -lt 0 ]]; then
31
+    echo "nkmax must be > 0."
32
+    exit 1
33
+fi
34
+
35
+if [[ $6 -lt 0 ]]; then
36
+    echo "width must be > 0."
37
+    exit 1
38
+fi
39
+
40
+
41
+whichDSF=$1
42
+kBT=$2
43
+target_sumrule=$3
44
+N=$4
45
+nkmax=$5
46
+width=$6
47
+
48
+for nk in {1..$nkmax}
49
+do
50
+    # produce dsfs files
51
+    build_LiebLin_c_scan_k_fixed_dsfs.sh $whichDSF $kBT $target_sumrule $N $nk $width
52
+    # produce plots
53
+    build_LiebLin_c_scan_k_fixed_dsfs_plot.sh $whichDSF $kBT $target_sumrule $N $width
54
+done

Loading…
Cancel
Save