From 4086e30f6f553544b68016a6da569ac60091d937 Mon Sep 17 00:00:00 2001 From: Cory Date: Tue, 21 Nov 2023 11:27:34 +0100 Subject: [PATCH] Add docs --- docs/2x2__analysis_8py_source.html | 144 + docs/IsingModel_8cpp.html | 131 + docs/IsingModel_8cpp_source.html | 265 ++ docs/IsingModel_8hpp.html | 253 ++ docs/IsingModel_8hpp.js | 4 + docs/IsingModel_8hpp_source.html | 200 ++ docs/annotated.html | 120 + docs/annotated_dup.js | 6 + docs/bc_s.png | Bin 0 -> 676 bytes docs/bc_sd.png | Bin 0 -> 635 bytes docs/bdwn.png | Bin 0 -> 147 bytes docs/bug.html | 146 + docs/burn__in__time_8py_source.html | 159 ++ docs/classIsingModel-members.html | 135 + docs/classIsingModel.html | 738 +++++ docs/classIsingModel.js | 21 + docs/classIsingModelTest-members.html | 118 + docs/classIsingModelTest.html | 215 ++ docs/classIsingModelTest.js | 5 + docs/classdata__t-members.html | 130 + docs/classdata__t.html | 534 ++++ docs/classes.html | 122 + docs/closed.png | Bin 0 -> 132 bytes docs/constants_8hpp.html | 156 + docs/constants_8hpp.js | 4 + docs/constants_8hpp_source.html | 121 + docs/data__type_8cpp.html | 129 + docs/data__type_8cpp.js | 7 + docs/data__type_8cpp_source.html | 117 + docs/data__type_8hpp.html | 138 + docs/data__type_8hpp.js | 4 + docs/data__type_8hpp_source.html | 224 ++ .../dir_634e799a3947388232110823971192a8.html | 124 + docs/dir_634e799a3947388232110823971192a8.js | 6 + .../dir_68267d1309a1af8e8297ef4c3efbcdba.html | 147 + docs/dir_68267d1309a1af8e8297ef4c3efbcdba.js | 12 + .../dir_d44c64559bbebec7f509842c48db8b23.html | 139 + docs/dir_d44c64559bbebec7f509842c48db8b23.js | 10 + docs/doc.png | Bin 0 -> 746 bytes docs/docd.png | Bin 0 -> 756 bytes docs/doxygen-awesome.css | 2530 +++++++++++++++++ docs/doxygen.css | 1665 +++++++++++ docs/doxygen.svg | 26 + docs/dynsections.js | 130 + docs/files.html | 138 + docs/files_dup.js | 5 + docs/folderclosed.png | Bin 0 -> 616 bytes docs/folderopen.png | Bin 0 -> 597 bytes docs/functions.html | 130 + docs/functions_func.html | 123 + docs/functions_vars.html | 119 + docs/globals.html | 123 + docs/globals_defs.html | 116 + docs/globals_func.html | 119 + docs/index.html | 216 ++ docs/index.js | 22 + docs/jquery.js | 34 + docs/main_8cpp.html | 261 ++ docs/main_8cpp.js | 4 + docs/main_8cpp_source.html | 226 ++ docs/menu.js | 136 + docs/menudata.js | 40 + docs/monte__carlo_8cpp.html | 483 ++++ docs/monte__carlo_8cpp.js | 9 + docs/monte__carlo_8cpp_source.html | 299 ++ docs/monte__carlo_8hpp.html | 550 ++++ docs/monte__carlo_8hpp.js | 10 + docs/monte__carlo_8hpp_source.html | 161 ++ docs/nav_f.png | Bin 0 -> 153 bytes docs/nav_fd.png | Bin 0 -> 169 bytes docs/nav_g.png | Bin 0 -> 95 bytes docs/nav_h.png | Bin 0 -> 98 bytes docs/nav_hd.png | Bin 0 -> 114 bytes docs/navtree.css | 150 + docs/navtree.js | 549 ++++ docs/navtreedata.js | 56 + docs/navtreeindex0.js | 121 + docs/open.png | Bin 0 -> 123 bytes docs/pages.html | 118 + docs/pd__estimate_8py_source.html | 141 + docs/phase__transition_8py_source.html | 226 ++ docs/phase__transition__mpi_8cpp.html | 179 ++ docs/phase__transition__mpi_8cpp.js | 4 + docs/phase__transition__mpi_8cpp_source.html | 237 ++ docs/resize.js | 155 + docs/search/all_0.js | 4 + docs/search/all_1.js | 4 + docs/search/all_10.js | 5 + docs/search/all_2.js | 4 + docs/search/all_3.js | 4 + docs/search/all_4.js | 8 + docs/search/all_5.js | 5 + docs/search/all_6.js | 5 + docs/search/all_7.js | 13 + docs/search/all_8.js | 4 + docs/search/all_9.js | 5 + docs/search/all_a.js | 15 + docs/search/all_b.js | 4 + docs/search/all_c.js | 6 + docs/search/all_d.js | 4 + docs/search/all_e.js | 10 + docs/search/all_f.js | 5 + docs/search/classes_0.js | 4 + docs/search/classes_1.js | 5 + docs/search/close.svg | 31 + docs/search/defines_0.js | 4 + docs/search/defines_1.js | 4 + docs/search/defines_2.js | 4 + docs/search/defines_3.js | 4 + docs/search/files_0.js | 4 + docs/search/files_1.js | 5 + docs/search/files_2.js | 5 + docs/search/files_3.js | 6 + docs/search/files_4.js | 4 + docs/search/files_5.js | 7 + docs/search/files_6.js | 5 + docs/search/functions_0.js | 4 + docs/search/functions_1.js | 5 + docs/search/functions_2.js | 9 + docs/search/functions_3.js | 11 + docs/search/functions_4.js | 5 + docs/search/functions_5.js | 4 + docs/search/functions_6.js | 5 + docs/search/functions_7.js | 5 + docs/search/mag.svg | 37 + docs/search/mag_d.svg | 37 + docs/search/mag_sel.svg | 74 + docs/search/mag_seld.svg | 74 + docs/search/pages_0.js | 4 + docs/search/pages_1.js | 4 + docs/search/search.css | 291 ++ docs/search/search.js | 816 ++++++ docs/search/searchdata.js | 33 + docs/search/variables_0.js | 5 + docs/search/variables_1.js | 5 + docs/search/variables_2.js | 4 + docs/search/variables_3.js | 4 + docs/search/variables_4.js | 4 + docs/splitbar.png | Bin 0 -> 314 bytes docs/splitbard.png | Bin 0 -> 282 bytes docs/structdata__t-members.html | 121 + docs/structdata__t.html | 239 ++ docs/structdata__t.js | 8 + docs/sync_off.png | Bin 0 -> 853 bytes docs/sync_on.png | Bin 0 -> 845 bytes docs/tab_a.png | Bin 0 -> 142 bytes docs/tab_ad.png | Bin 0 -> 135 bytes docs/tab_b.png | Bin 0 -> 169 bytes docs/tab_bd.png | Bin 0 -> 173 bytes docs/tab_h.png | Bin 0 -> 177 bytes docs/tab_hd.png | Bin 0 -> 180 bytes docs/tab_s.png | Bin 0 -> 184 bytes docs/tab_sd.png | Bin 0 -> 188 bytes docs/tabs.css | 1 + docs/test__suite_8cpp.html | 248 ++ docs/test__suite_8cpp.js | 5 + docs/test__suite_8cpp_source.html | 279 ++ docs/testlib_8cpp.html | 207 ++ docs/testlib_8cpp.js | 4 + docs/testlib_8cpp_source.html | 148 + docs/testlib_8hpp.html | 252 ++ docs/testlib_8hpp.js | 5 + docs/testlib_8hpp_source.html | 182 ++ docs/typedefs_8hpp.html | 129 + docs/typedefs_8hpp_source.html | 119 + docs/utils_8cpp.html | 314 ++ docs/utils_8cpp.js | 7 + docs/utils_8cpp_source.html | 171 ++ docs/utils_8hpp.html | 413 +++ docs/utils_8hpp.js | 10 + docs/utils_8hpp_source.html | 164 ++ 171 files changed, 19058 insertions(+) create mode 100644 docs/2x2__analysis_8py_source.html create mode 100644 docs/IsingModel_8cpp.html create mode 100644 docs/IsingModel_8cpp_source.html create mode 100644 docs/IsingModel_8hpp.html create mode 100644 docs/IsingModel_8hpp.js create mode 100644 docs/IsingModel_8hpp_source.html create mode 100644 docs/annotated.html create mode 100644 docs/annotated_dup.js create mode 100644 docs/bc_s.png create mode 100644 docs/bc_sd.png create mode 100644 docs/bdwn.png create mode 100644 docs/bug.html create mode 100644 docs/burn__in__time_8py_source.html create mode 100644 docs/classIsingModel-members.html create mode 100644 docs/classIsingModel.html create mode 100644 docs/classIsingModel.js create mode 100644 docs/classIsingModelTest-members.html create mode 100644 docs/classIsingModelTest.html create mode 100644 docs/classIsingModelTest.js create mode 100644 docs/classdata__t-members.html create mode 100644 docs/classdata__t.html create mode 100644 docs/classes.html create mode 100644 docs/closed.png create mode 100644 docs/constants_8hpp.html create mode 100644 docs/constants_8hpp.js create mode 100644 docs/constants_8hpp_source.html create mode 100644 docs/data__type_8cpp.html create mode 100644 docs/data__type_8cpp.js create mode 100644 docs/data__type_8cpp_source.html create mode 100644 docs/data__type_8hpp.html create mode 100644 docs/data__type_8hpp.js create mode 100644 docs/data__type_8hpp_source.html create mode 100644 docs/dir_634e799a3947388232110823971192a8.html create mode 100644 docs/dir_634e799a3947388232110823971192a8.js create mode 100644 docs/dir_68267d1309a1af8e8297ef4c3efbcdba.html create mode 100644 docs/dir_68267d1309a1af8e8297ef4c3efbcdba.js create mode 100644 docs/dir_d44c64559bbebec7f509842c48db8b23.html create mode 100644 docs/dir_d44c64559bbebec7f509842c48db8b23.js create mode 100644 docs/doc.png create mode 100644 docs/docd.png create mode 100644 docs/doxygen-awesome.css create mode 100644 docs/doxygen.css create mode 100644 docs/doxygen.svg create mode 100644 docs/dynsections.js create mode 100644 docs/files.html create mode 100644 docs/files_dup.js create mode 100644 docs/folderclosed.png create mode 100644 docs/folderopen.png create mode 100644 docs/functions.html create mode 100644 docs/functions_func.html create mode 100644 docs/functions_vars.html create mode 100644 docs/globals.html create mode 100644 docs/globals_defs.html create mode 100644 docs/globals_func.html create mode 100644 docs/index.html create mode 100644 docs/index.js create mode 100644 docs/jquery.js create mode 100644 docs/main_8cpp.html create mode 100644 docs/main_8cpp.js create mode 100644 docs/main_8cpp_source.html create mode 100644 docs/menu.js create mode 100644 docs/menudata.js create mode 100644 docs/monte__carlo_8cpp.html create mode 100644 docs/monte__carlo_8cpp.js create mode 100644 docs/monte__carlo_8cpp_source.html create mode 100644 docs/monte__carlo_8hpp.html create mode 100644 docs/monte__carlo_8hpp.js create mode 100644 docs/monte__carlo_8hpp_source.html create mode 100644 docs/nav_f.png create mode 100644 docs/nav_fd.png create mode 100644 docs/nav_g.png create mode 100644 docs/nav_h.png create mode 100644 docs/nav_hd.png create mode 100644 docs/navtree.css create mode 100644 docs/navtree.js create mode 100644 docs/navtreedata.js create mode 100644 docs/navtreeindex0.js create mode 100644 docs/open.png create mode 100644 docs/pages.html create mode 100644 docs/pd__estimate_8py_source.html create mode 100644 docs/phase__transition_8py_source.html create mode 100644 docs/phase__transition__mpi_8cpp.html create mode 100644 docs/phase__transition__mpi_8cpp.js create mode 100644 docs/phase__transition__mpi_8cpp_source.html create mode 100644 docs/resize.js create mode 100644 docs/search/all_0.js create mode 100644 docs/search/all_1.js create mode 100644 docs/search/all_10.js create mode 100644 docs/search/all_2.js create mode 100644 docs/search/all_3.js create mode 100644 docs/search/all_4.js create mode 100644 docs/search/all_5.js create mode 100644 docs/search/all_6.js create mode 100644 docs/search/all_7.js create mode 100644 docs/search/all_8.js create mode 100644 docs/search/all_9.js create mode 100644 docs/search/all_a.js create mode 100644 docs/search/all_b.js create mode 100644 docs/search/all_c.js create mode 100644 docs/search/all_d.js create mode 100644 docs/search/all_e.js create mode 100644 docs/search/all_f.js create mode 100644 docs/search/classes_0.js create mode 100644 docs/search/classes_1.js create mode 100644 docs/search/close.svg create mode 100644 docs/search/defines_0.js create mode 100644 docs/search/defines_1.js create mode 100644 docs/search/defines_2.js create mode 100644 docs/search/defines_3.js create mode 100644 docs/search/files_0.js create mode 100644 docs/search/files_1.js create mode 100644 docs/search/files_2.js create mode 100644 docs/search/files_3.js create mode 100644 docs/search/files_4.js create mode 100644 docs/search/files_5.js create mode 100644 docs/search/files_6.js create mode 100644 docs/search/functions_0.js create mode 100644 docs/search/functions_1.js create mode 100644 docs/search/functions_2.js create mode 100644 docs/search/functions_3.js create mode 100644 docs/search/functions_4.js create mode 100644 docs/search/functions_5.js create mode 100644 docs/search/functions_6.js create mode 100644 docs/search/functions_7.js create mode 100644 docs/search/mag.svg create mode 100644 docs/search/mag_d.svg create mode 100644 docs/search/mag_sel.svg create mode 100644 docs/search/mag_seld.svg create mode 100644 docs/search/pages_0.js create mode 100644 docs/search/pages_1.js create mode 100644 docs/search/search.css create mode 100644 docs/search/search.js create mode 100644 docs/search/searchdata.js create mode 100644 docs/search/variables_0.js create mode 100644 docs/search/variables_1.js create mode 100644 docs/search/variables_2.js create mode 100644 docs/search/variables_3.js create mode 100644 docs/search/variables_4.js create mode 100644 docs/splitbar.png create mode 100644 docs/splitbard.png create mode 100644 docs/structdata__t-members.html create mode 100644 docs/structdata__t.html create mode 100644 docs/structdata__t.js create mode 100644 docs/sync_off.png create mode 100644 docs/sync_on.png create mode 100644 docs/tab_a.png create mode 100644 docs/tab_ad.png create mode 100644 docs/tab_b.png create mode 100644 docs/tab_bd.png create mode 100644 docs/tab_h.png create mode 100644 docs/tab_hd.png create mode 100644 docs/tab_s.png create mode 100644 docs/tab_sd.png create mode 100644 docs/tabs.css create mode 100644 docs/test__suite_8cpp.html create mode 100644 docs/test__suite_8cpp.js create mode 100644 docs/test__suite_8cpp_source.html create mode 100644 docs/testlib_8cpp.html create mode 100644 docs/testlib_8cpp.js create mode 100644 docs/testlib_8cpp_source.html create mode 100644 docs/testlib_8hpp.html create mode 100644 docs/testlib_8hpp.js create mode 100644 docs/testlib_8hpp_source.html create mode 100644 docs/typedefs_8hpp.html create mode 100644 docs/typedefs_8hpp_source.html create mode 100644 docs/utils_8cpp.html create mode 100644 docs/utils_8cpp.js create mode 100644 docs/utils_8cpp_source.html create mode 100644 docs/utils_8hpp.html create mode 100644 docs/utils_8hpp.js create mode 100644 docs/utils_8hpp_source.html diff --git a/docs/2x2__analysis_8py_source.html b/docs/2x2__analysis_8py_source.html new file mode 100644 index 0000000..3c390fe --- /dev/null +++ b/docs/2x2__analysis_8py_source.html @@ -0,0 +1,144 @@ + + + + + + + +2 Dimensional Ising Model: src/scripts/2x2_analysis.py Source File + + + + + + + + + + + + + + + + +
+
+ + + + + + +
+
2 Dimensional Ising Model +
+
Simulate the change in energy and magnetization in a ferro magnet
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+
+
+
+
+
Loading...
+
Searching...
+
No Matches
+
+
+
+
+ +
+
2x2_analysis.py
+
+
+
1import matplotlib.pyplot as plt
+
2
+
3
+
4def plot_from_file():
+
5 figure, ax = plt.subplots()
+
6
+
7 with open("output/2_lattice_test.txt") as f:
+
8 lines = f.readlines()
+
9
+
10 t = []
+
11 energy = []
+
12 magnetization = []
+
13 for line in lines:
+
14 items = line.strip().split(",")
+
15 t.append(int(items[0]))
+
16 energy.append(float(items[1]))
+
17 magnetization.append(float(items[5]))
+
18
+
19 ax.plot(t, energy, label=f"<epsilon> {label}")
+
20 ax.plot(t, magnetization, label=f"<|m|> {label}")
+
21
+
22 figure.legend()
+
23 figure.savefig("../latex/images/2x2_analysis.pdf")
+
24
+
25def main():
+
26 plot_from_file()
+
27
+
28if __name__ == "__main__":
+
29 main()
+
int main()
The main function.
Definition: main.cpp:20
+
+
+ + + + diff --git a/docs/IsingModel_8cpp.html b/docs/IsingModel_8cpp.html new file mode 100644 index 0000000..45e898a --- /dev/null +++ b/docs/IsingModel_8cpp.html @@ -0,0 +1,131 @@ + + + + + + + +2 Dimensional Ising Model: src/IsingModel.cpp File Reference + + + + + + + + + + + + + + + + +
+
+ + + + + + +
+
2 Dimensional Ising Model +
+
Simulate the change in energy and magnetization in a ferro magnet
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+
+
+
+
+
Loading...
+
Searching...
+
No Matches
+
+
+
+
+ +
+
IsingModel.cpp File Reference
+
+
+ +

The implementation of the Ising model. +More...

+
#include "IsingModel.hpp"
+#include <cmath>
+#include <random>
+
+

Go to the source code of this file.

+

Detailed Description

+

The implementation of the Ising model.

+
Author
Cory Alexander Balaton (coryab)
+
+Janita Ovidie Sandtrøen Willumsen (janitaws)
+
Version
0.1
+
Bug:
No known bugs
+ +

Definition in file IsingModel.cpp.

+
+
+ + + + diff --git a/docs/IsingModel_8cpp_source.html b/docs/IsingModel_8cpp_source.html new file mode 100644 index 0000000..84b95ce --- /dev/null +++ b/docs/IsingModel_8cpp_source.html @@ -0,0 +1,265 @@ + + + + + + + +2 Dimensional Ising Model: src/IsingModel.cpp Source File + + + + + + + + + + + + + + + + +
+
+ + + + + + +
+
2 Dimensional Ising Model +
+
Simulate the change in energy and magnetization in a ferro magnet
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+
+
+
+
+
Loading...
+
Searching...
+
No Matches
+
+
+
+
+ +
+
IsingModel.cpp
+
+
+Go to the documentation of this file.
1
+
12#include "IsingModel.hpp"
+
13
+
14#include <cmath>
+
15#include <random>
+
16
+ +
18{
+
19}
+
20
+
21IsingModel::IsingModel(int L, double T)
+
22{
+
23 this->L = L;
+
24 this->T = T;
+
25 this->initialize_lattice();
+ + + +
29 this->initialize_energy();
+
30}
+
31
+
32IsingModel::IsingModel(int L, double T, int val)
+
33{
+
34 this->L = L;
+
35 this->T = T;
+
36 this->lattice.set_size(this->L, this->L);
+
37 this->lattice.fill(val);
+ + + +
41 this->initialize_energy();
+
42}
+
43
+ +
45{
+
46 this->lattice.set_size(this->L, this->L);
+
47 std::random_device rd{};
+
48 std::mt19937 engine{rd()};
+
49
+
50 std::uniform_int_distribution<> coin_flip(0, 1);
+
51
+
52 for (size_t i = 0; i < this->lattice.n_elem; i++)
+
53 this->lattice(i) = 2 * coin_flip(engine) - 1;
+
54}
+
55
+ +
57{
+
58 this->neighbors.set_size(this->L, 2);
+
59
+
60 // Having i as a signed integer is necessary in this case.
+
61 for (int i = 0; i < (int)this->L; i++) {
+
62 this->neighbors(i, UP) = INDEX(i - 1, this->L);
+
63 this->neighbors(i, DOWN) = INDEX(i + 1, this->L);
+
64 }
+
65}
+
66
+ +
68{
+
69 for (int i = -8; i <= 8; i += 4) {
+
70 this->energy_diff.insert({i, std::exp(-(double)i / this->T)});
+
71 }
+
72}
+
73
+ +
75{
+
76 this->M = 0.;
+
77 for (size_t i = 0; i < this->lattice.n_elem; i++) {
+
78 this->M += this->lattice(i);
+
79 }
+
80}
+
81
+ +
83{
+
84 this->E = 0.;
+
85
+
86 // Loop through the matrix
+
87 for (size_t j = 0; j < this->L; j++) {
+
88 for (size_t i = 0; i < this->L; i++) {
+
89 this->E -= this->lattice(i, j)
+
90 * (this->lattice(i, this->neighbors(j, RIGHT))
+
91 + this->lattice(this->neighbors(i, DOWN), j));
+
92 }
+
93 }
+
94}
+
95
+ +
97{
+
98 std::random_device rd{};
+
99 std::mt19937_64 engine{rd()};
+
100
+
101 int ri, rj;
+
102 int dE;
+
103
+
104 // Create random distribution for indeces
+
105 std::uniform_int_distribution<> random_index(0, this->L - 1);
+
106 // Create random distribution for acceptance
+
107 std::uniform_real_distribution<> random_number(0., 1.);
+
108
+
109 // Loop over the number of spins
+
110 for (size_t i = 0; i < this->lattice.n_elem; i++) {
+
111 // Get random indeces
+
112 ri = random_index(engine);
+
113 rj = random_index(engine);
+
114
+
115 // Calculate the difference in energy
+
116 dE = 2 * this->lattice(ri, rj)
+
117 * (this->lattice(ri, this->neighbors(rj, LEFT))
+
118 + this->lattice(ri, this->neighbors(rj, RIGHT))
+
119 + this->lattice(this->neighbors(ri, UP), rj)
+
120 + this->lattice(this->neighbors(ri, DOWN), rj));
+
121
+
122 // Choose whether or not to accept the new configuration
+
123 if (random_number(engine) <= this->energy_diff[dE]) {
+
124 // Update if the configuration is accepted
+
125 this->lattice(ri, rj) *= -1;
+
126 this->M += 2 * this->lattice(ri, rj);
+
127 this->E += dE;
+
128 }
+
129 }
+
130
+
131 return data_t((double)this->E, (double)(this->E * this->E), (double)this->M,
+
132 (double)(this->M * this->M), std::fabs((double)this->M));
+
133}
+
134
+ +
136{
+
137 return this->E;
+
138}
+
139
+ +
141{
+
142 return this->M;
+
143}
+
The definition of the Ising model.
+
int M
The current magnetic strength. unit: Unitless.
Definition: IsingModel.hpp:72
+
std::unordered_map< int, double > energy_diff
A hash map containing all possible energy changes.
Definition: IsingModel.hpp:56
+
double T
The temperature of the model.
Definition: IsingModel.hpp:60
+
int L
Size of the lattice.
Definition: IsingModel.hpp:64
+
arma::Mat< int > lattice
matrix where element .
Definition: IsingModel.hpp:42
+
void initialize_lattice()
Initialize the lattice with a random distribution of 1s and -1s.
Definition: IsingModel.cpp:44
+
data_t Metropolis()
The Metropolis algorithm.
Definition: IsingModel.cpp:96
+
void initialize_energy()
Initialize the energy.
Definition: IsingModel.cpp:82
+
void initialize_neighbors()
initialize the neighbors matrix.
Definition: IsingModel.cpp:56
+
void initialize_magnetization()
Initialize the magnetization.
Definition: IsingModel.cpp:74
+
arma::Mat< int > neighbors
matrix with the neighbors of each element .
Definition: IsingModel.hpp:52
+
int get_M()
Get the current magnetization.
Definition: IsingModel.cpp:140
+
int get_E()
Get the current energy.
Definition: IsingModel.cpp:135
+
IsingModel()
Constructor used for testing.
Definition: IsingModel.cpp:17
+
int E
The current energy state. unit: .
Definition: IsingModel.hpp:68
+
void initialize_energy_diff()
Initialize the hashmap with the correct values.
Definition: IsingModel.cpp:67
+ +
+
+ + + + diff --git a/docs/IsingModel_8hpp.html b/docs/IsingModel_8hpp.html new file mode 100644 index 0000000..06ffc00 --- /dev/null +++ b/docs/IsingModel_8hpp.html @@ -0,0 +1,253 @@ + + + + + + + +2 Dimensional Ising Model: include/IsingModel.hpp File Reference + + + + + + + + + + + + + + + + +
+
+ + + + + + +
+
2 Dimensional Ising Model +
+
Simulate the change in energy and magnetization in a ferro magnet
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+
+
+
+
+
Loading...
+
Searching...
+
No Matches
+
+
+
+
+ +
+ +
IsingModel.hpp File Reference
+
+
+ +

The definition of the Ising model. +More...

+
#include "constants.hpp"
+#include "data_type.hpp"
+#include "typedefs.hpp"
+#include "utils.hpp"
+#include <armadillo>
+#include <random>
+#include <unordered_map>
+
+

Go to the source code of this file.

+ + + + + +

+Classes

class  IsingModel
 The Ising model in 2 dimensions. More...
 
+ + + + + + + + + + + +

+Macros

#define INDEX(I, N)   (I + N) % N
 
#define UP   0
 
#define LEFT   0
 
#define DOWN   1
 
#define RIGHT   1
 
+

Detailed Description

+

The definition of the Ising model.

+
Author
Cory Alexander Balaton (coryab)
+
+Janita Ovidie Sandtrøen Willumsen (janitaws)
+
Version
0.1
+
Bug:
No known bugs
+ +

Definition in file IsingModel.hpp.

+

Macro Definition Documentation

+ +

◆ DOWN

+ +
+
+ + + + +
#define DOWN   1
+
+ +

Definition at line 29 of file IsingModel.hpp.

+ +
+
+ +

◆ INDEX

+ +
+
+ + + + + + + + + + + + + + + + + + +
#define INDEX( I,
 
)   (I + N) % N
+
+ +

Definition at line 24 of file IsingModel.hpp.

+ +
+
+ +

◆ LEFT

+ +
+
+ + + + +
#define LEFT   0
+
+ +

Definition at line 28 of file IsingModel.hpp.

+ +
+
+ +

◆ RIGHT

+ +
+
+ + + + +
#define RIGHT   1
+
+ +

Definition at line 30 of file IsingModel.hpp.

+ +
+
+ +

◆ UP

+ +
+
+ + + + +
#define UP   0
+
+ +

Definition at line 27 of file IsingModel.hpp.

+ +
+
+
+
+ + + + diff --git a/docs/IsingModel_8hpp.js b/docs/IsingModel_8hpp.js new file mode 100644 index 0000000..616fe52 --- /dev/null +++ b/docs/IsingModel_8hpp.js @@ -0,0 +1,4 @@ +var IsingModel_8hpp = +[ + [ "IsingModel", "classIsingModel.html", "classIsingModel" ] +]; \ No newline at end of file diff --git a/docs/IsingModel_8hpp_source.html b/docs/IsingModel_8hpp_source.html new file mode 100644 index 0000000..6282c69 --- /dev/null +++ b/docs/IsingModel_8hpp_source.html @@ -0,0 +1,200 @@ + + + + + + + +2 Dimensional Ising Model: include/IsingModel.hpp Source File + + + + + + + + + + + + + + + + +
+
+ + + + + + +
+
2 Dimensional Ising Model +
+
Simulate the change in energy and magnetization in a ferro magnet
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+
+
+
+
+
Loading...
+
Searching...
+
No Matches
+
+
+
+
+ +
+
IsingModel.hpp
+
+
+Go to the documentation of this file.
1
+
12#ifndef __ISING_MODEL__
+
13#define __ISING_MODEL__
+
14
+
15#include "constants.hpp"
+
16#include "data_type.hpp"
+
17#include "typedefs.hpp"
+
18#include "utils.hpp"
+
19
+
20#include <armadillo>
+
21#include <random>
+
22#include <unordered_map>
+
23
+
24#define INDEX(I, N) (I + N) % N
+
25
+
26// Indeces for the neighbor matrix.
+
27#define UP 0
+
28#define LEFT 0
+
29#define DOWN 1
+
30#define RIGHT 1
+
31
+ +
38private:
+
39 friend class IsingModelTest;
+
42 arma::Mat<int> lattice;
+
43
+
52 arma::Mat<int> neighbors;
+
53
+
56 std::unordered_map<int, double> energy_diff;
+
57
+
60 double T;
+
61
+
64 int L;
+
65
+
68 int E;
+
69
+
72 int M;
+
73
+
77 void initialize_lattice();
+
78
+ +
82
+ +
86
+ +
90
+
93 void initialize_energy();
+
94
+
97 IsingModel();
+
98
+
99public:
+
105 IsingModel(int L, double T);
+
106
+
113 IsingModel(int L, double T, int val);
+
114
+ +
118
+
123 int get_E();
+
124
+
129 int get_M();
+
130};
+
131
+
132#endif
+
Test class for the Ising model.
Definition: test_suite.cpp:30
+
The Ising model in 2 dimensions.
Definition: IsingModel.hpp:37
+
int M
The current magnetic strength. unit: Unitless.
Definition: IsingModel.hpp:72
+
std::unordered_map< int, double > energy_diff
A hash map containing all possible energy changes.
Definition: IsingModel.hpp:56
+
double T
The temperature of the model.
Definition: IsingModel.hpp:60
+
int L
Size of the lattice.
Definition: IsingModel.hpp:64
+
arma::Mat< int > lattice
matrix where element .
Definition: IsingModel.hpp:42
+
void initialize_lattice()
Initialize the lattice with a random distribution of 1s and -1s.
Definition: IsingModel.cpp:44
+
data_t Metropolis()
The Metropolis algorithm.
Definition: IsingModel.cpp:96
+
void initialize_energy()
Initialize the energy.
Definition: IsingModel.cpp:82
+
void initialize_neighbors()
initialize the neighbors matrix.
Definition: IsingModel.cpp:56
+
void initialize_magnetization()
Initialize the magnetization.
Definition: IsingModel.cpp:74
+
arma::Mat< int > neighbors
matrix with the neighbors of each element .
Definition: IsingModel.hpp:52
+
int get_M()
Get the current magnetization.
Definition: IsingModel.cpp:140
+
int get_E()
Get the current energy.
Definition: IsingModel.cpp:135
+
IsingModel()
Constructor used for testing.
Definition: IsingModel.cpp:17
+
int E
The current energy state. unit: .
Definition: IsingModel.hpp:68
+
void initialize_energy_diff()
Initialize the hashmap with the correct values.
Definition: IsingModel.cpp:67
+ +
Library of constants.
+
Header for the data_t type.
+
Useful typedefs for cleaner code.
+
Function prototypes and macros that are useful.
+
+
+ + + + diff --git a/docs/annotated.html b/docs/annotated.html new file mode 100644 index 0000000..751b997 --- /dev/null +++ b/docs/annotated.html @@ -0,0 +1,120 @@ + + + + + + + +2 Dimensional Ising Model: Class List + + + + + + + + + + + + + + + + +
+
+ + + + + + +
+
2 Dimensional Ising Model +
+
Simulate the change in energy and magnetization in a ferro magnet
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+
+
+
+
+
Loading...
+
Searching...
+
No Matches
+
+
+
+
+ +
+
Class List
+
+
+
Here are the classes, structs, unions and interfaces with brief descriptions:
+ + + + +
 Cdata_t
 CIsingModelThe Ising model in 2 dimensions
 CIsingModelTestTest class for the Ising model
+
+
+
+ + + + diff --git a/docs/annotated_dup.js b/docs/annotated_dup.js new file mode 100644 index 0000000..74285eb --- /dev/null +++ b/docs/annotated_dup.js @@ -0,0 +1,6 @@ +var annotated_dup = +[ + [ "data_t", "classdata__t.html", null ], + [ "IsingModel", "classIsingModel.html", "classIsingModel" ], + [ "IsingModelTest", "classIsingModelTest.html", "classIsingModelTest" ] +]; \ No newline at end of file diff --git a/docs/bc_s.png b/docs/bc_s.png new file mode 100644 index 0000000000000000000000000000000000000000..224b29aa9847d5a4b3902efd602b7ddf7d33e6c2 GIT binary patch literal 676 zcmV;V0$crwP)y__>=_9%My z{n931IS})GlGUF8K#6VIbs%684A^L3@%PlP2>_sk`UWPq@f;rU*V%rPy_ekbhXT&s z(GN{DxFv}*vZp`F>S!r||M`I*nOwwKX+BC~3P5N3-)Y{65c;ywYiAh-1*hZcToLHK ztpl1xomJ+Yb}K(cfbJr2=GNOnT!UFA7Vy~fBz8?J>XHsbZoDad^8PxfSa0GDgENZS zuLCEqzb*xWX2CG*b&5IiO#NzrW*;`VC9455M`o1NBh+(k8~`XCEEoC1Ybwf;vr4K3 zg|EB<07?SOqHp9DhLpS&bzgo70I+ghB_#)K7H%AMU3v}xuyQq9&Bm~++VYhF09a+U zl7>n7Jjm$K#b*FONz~fj;I->Bf;ule1prFN9FovcDGBkpg>)O*-}eLnC{6oZHZ$o% zXKW$;0_{8hxHQ>l;_*HATI(`7t#^{$(zLe}h*mqwOc*nRY9=?Sx4OOeVIfI|0V(V2 zBrW#G7Ss9wvzr@>H*`r>zE z+e8bOBgqIgldUJlG(YUDviMB`9+DH8n-s9SXRLyJHO1!=wY^79WYZMTa(wiZ!zP66 zA~!21vmF3H2{ngD;+`6j#~6j;$*f*G_2ZD1E;9(yaw7d-QnSCpK(cR1zU3qU0000< KMNUMnLSTYoA~SLT literal 0 HcmV?d00001 diff --git a/docs/bc_sd.png b/docs/bc_sd.png new file mode 100644 index 0000000000000000000000000000000000000000..31ca888dc71049713b35c351933a8d0f36180bf1 GIT binary patch literal 635 zcmV->0)+jEP)Jwi0r1~gdSq#w{Bu1q z`craw(p2!hu$4C_$Oc3X(sI6e=9QSTwPt{G) z=htT&^~&c~L2~e{r5_5SYe7#Is-$ln>~Kd%$F#tC65?{LvQ}8O`A~RBB0N~`2M+waajO;5>3B&-viHGJeEK2TQOiPRa zfDKyqwMc4wfaEh4jt>H`nW_Zidwk@Bowp`}(VUaj-pSI(-1L>FJVsX}Yl9~JsqgsZ zUD9(rMwf23Gez6KPa|wwInZodP-2}9@fK0Ga_9{8SOjU&4l`pH4@qlQp83>>HT$xW zER^U>)MyV%t(Lu=`d=Y?{k1@}&r7ZGkFQ%z%N+sE9BtYjovzxyxCPxN6&@wLK{soQ zSmkj$aLI}miuE^p@~4}mg9OjDfGEkgY4~^XzLRUBB*O{+&vq<3v(E%+k_i%=`~j%{ Vj14gnt9}3g002ovPDHLkV1n!oC4m3{ literal 0 HcmV?d00001 diff --git a/docs/bdwn.png b/docs/bdwn.png new file mode 100644 index 0000000000000000000000000000000000000000..940a0b950443a0bb1b216ac03c45b8a16c955452 GIT binary patch literal 147 zcmeAS@N?(olHy`uVBq!ia0vp^>_E)H!3HEvS)PKZC{Gv1kP61Pb5HX&C2wk~_T + + + + + + +2 Dimensional Ising Model: Bug List + + + + + + + + + + + + + + + + +
+
+ + + + + + +
+
2 Dimensional Ising Model +
+
Simulate the change in energy and magnetization in a ferro magnet
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+
+
+
+
+
Loading...
+
Searching...
+
No Matches
+
+
+
+
+ +
+
Bug List
+
+
+
+
File constants.hpp
+
No known bugs
+
File data_type.cpp
+
No known bugs
+
File data_type.hpp
+
No known bugs
+
File IsingModel.cpp
+
No known bugs
+
File IsingModel.hpp
+
No known bugs
+
File main.cpp
+
No known bugs
+
File monte_carlo.cpp
+
No known bugs
+
File monte_carlo.hpp
+
No known bugs
+
File phase_transition_mpi.cpp
+
No known bugs
+
File test_suite.cpp
+
No known bugs
+
File testlib.cpp
+
No known bugs
+
File testlib.hpp
+
No known bugs
+
File typedefs.hpp
+
No known bugs
+
File utils.cpp
+
No known bugs
+
File utils.hpp
+
No known bugs
+
+
+
+
+ + + + diff --git a/docs/burn__in__time_8py_source.html b/docs/burn__in__time_8py_source.html new file mode 100644 index 0000000..36c2a72 --- /dev/null +++ b/docs/burn__in__time_8py_source.html @@ -0,0 +1,159 @@ + + + + + + + +2 Dimensional Ising Model: src/scripts/burn_in_time.py Source File + + + + + + + + + + + + + + + + +
+
+ + + + + + +
+
2 Dimensional Ising Model +
+
Simulate the change in energy and magnetization in a ferro magnet
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+
+
+
+
+
Loading...
+
Searching...
+
No Matches
+
+
+
+
+ +
+
burn_in_time.py
+
+
+
1import matplotlib.pyplot as plt
+
2
+
3def plot_from_file():
+
4 files = [
+
5 "output/burn_in_time/unordered_1_0.txt",
+
6 "output/burn_in_time/ordered_1_0.txt",
+
7 "output/burn_in_time/unordered_2_4.txt",
+
8 "output/burn_in_time/ordered_2_4.txt",
+
9 ]
+
10 labels = [
+
11 "1.0, unordered",
+
12 "1.0, ordered",
+
13 "2.4, unordered",
+
14 "2.4, ordered"
+
15 ]
+
16 figure1, ax1 = plt.subplots()
+
17 figure2, ax2 = plt.subplots()
+
18
+
19 for infile, label in zip(files, labels):
+
20 with open(infile) as f:
+
21 lines = f.readlines()
+
22
+
23 t = []
+
24 energy = []
+
25 magnetization = []
+
26 for line in lines:
+
27 items = line.strip().split(",")
+
28 t.append(int(items[0]))
+
29 energy.append(float(items[1]))
+
30 magnetization.append(float(items[5]))
+
31
+
32 ax1.plot(t, energy, label=fr"$\langle \epsilon \rangle$ {label}")
+
33 ax2.plot(t, magnetization, label=fr"$\langle | m | \rangle$ {label}")
+
34
+
35 figure1.legend()
+
36 figure1.savefig("../latex/images/burn_in_time_energy.pdf")
+
37 figure2.legend()
+
38 figure2.savefig("../latex/images/burn_in_time_magnetization.pdf")
+
39
+
40def main():
+
41 plot_from_file()
+
42
+
43if __name__ == "__main__":
+
44 main()
+
int main()
The main function.
Definition: test_suite.cpp:148
+
+
+ + + + diff --git a/docs/classIsingModel-members.html b/docs/classIsingModel-members.html new file mode 100644 index 0000000..46d1990 --- /dev/null +++ b/docs/classIsingModel-members.html @@ -0,0 +1,135 @@ + + + + + + + +2 Dimensional Ising Model: Member List + + + + + + + + + + + + + + + + +
+
+ + + + + + +
+
2 Dimensional Ising Model +
+
Simulate the change in energy and magnetization in a ferro magnet
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+
+
+
+
+
Loading...
+
Searching...
+
No Matches
+
+
+
+
+ +
+
IsingModel Member List
+
+
+ +

This is the complete list of members for IsingModel, including all inherited members.

+ + + + + + + + + + + + + + + + + + + + +
EIsingModelprivate
energy_diffIsingModelprivate
get_E()IsingModel
get_M()IsingModel
initialize_energy()IsingModelprivate
initialize_energy_diff()IsingModelprivate
initialize_lattice()IsingModelprivate
initialize_magnetization()IsingModelprivate
initialize_neighbors()IsingModelprivate
IsingModel()IsingModelprivate
IsingModel(int L, double T)IsingModel
IsingModel(int L, double T, int val)IsingModel
IsingModelTest (defined in IsingModel)IsingModelfriend
LIsingModelprivate
latticeIsingModelprivate
MIsingModelprivate
Metropolis()IsingModel
neighborsIsingModelprivate
TIsingModelprivate
+
+ + + + diff --git a/docs/classIsingModel.html b/docs/classIsingModel.html new file mode 100644 index 0000000..e2a27b6 --- /dev/null +++ b/docs/classIsingModel.html @@ -0,0 +1,738 @@ + + + + + + + +2 Dimensional Ising Model: IsingModel Class Reference + + + + + + + + + + + + + + + + +
+
+ + + + + + +
+
2 Dimensional Ising Model +
+
Simulate the change in energy and magnetization in a ferro magnet
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+
+
+
+
+
Loading...
+
Searching...
+
No Matches
+
+
+
+
+ + +
+ +

The Ising model in 2 dimensions. + More...

+ +

#include <IsingModel.hpp>

+ + + + + + + + + + + + + + + + + +

+Public Member Functions

 IsingModel (int L, double T)
 Constructor for the Ising model.
 
 IsingModel (int L, double T, int val)
 Constructor for the Ising model.
 
data_t Metropolis ()
 The Metropolis algorithm.
 
int get_E ()
 Get the current energy.
 
int get_M ()
 Get the current magnetization.
 
+ + + + + + + + + + + + + + + + + + + +

+Private Member Functions

void initialize_lattice ()
 Initialize the lattice with a random distribution of 1s and -1s.
 
void initialize_neighbors ()
 initialize the neighbors matrix.
 
void initialize_energy_diff ()
 Initialize the hashmap with the correct values.
 
void initialize_magnetization ()
 Initialize the magnetization.
 
void initialize_energy ()
 Initialize the energy.
 
 IsingModel ()
 Constructor used for testing.
 
+ + + + + + + + + + + + + + + + + + + + + + +

+Private Attributes

arma::Mat< int > lattice
 \( L \times L \) matrix where element \( x \in {-1, 1}\).
 
arma::Mat< int > neighbors
 \( L \times 2 \) matrix with the neighbors of each element \( x_i \).
 
std::unordered_map< int, double > energy_diff
 A hash map containing all possible energy changes.
 
double T
 The temperature of the model.
 
int L
 Size of the lattice.
 
int E
 The current energy state. unit: \( J \).
 
int M
 The current magnetic strength. unit: Unitless.
 
+ + + +

+Friends

class IsingModelTest
 
+

Detailed Description

+

The Ising model in 2 dimensions.

+

None of the methods are parallelized, as there is very little benefit in doing so.

+ +

Definition at line 37 of file IsingModel.hpp.

+

Constructor & Destructor Documentation

+ +

◆ IsingModel() [1/3]

+ +
+
+ + + + + +
+ + + + + + + +
IsingModel::IsingModel ()
+
+private
+
+ +

Constructor used for testing.

+ +

Definition at line 17 of file IsingModel.cpp.

+ +
+
+ +

◆ IsingModel() [2/3]

+ +
+
+ + + + + + + + + + + + + + + + + + +
IsingModel::IsingModel (int L,
double T 
)
+
+ +

Constructor for the Ising model.

+
Parameters
+ + + +
LThe size of the lattice.
TThe temperature for the system.
+
+
+ +

Definition at line 21 of file IsingModel.cpp.

+ +
+
+ +

◆ IsingModel() [3/3]

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
IsingModel::IsingModel (int L,
double T,
int val 
)
+
+ +

Constructor for the Ising model.

+
Parameters
+ + + + +
LThe size of the lattice.
TThe temperature for the system.
valThe value to set for all spins.
+
+
+ +

Definition at line 32 of file IsingModel.cpp.

+ +
+
+

Member Function Documentation

+ +

◆ get_E()

+ +
+
+ + + + + + + +
int IsingModel::get_E ()
+
+ +

Get the current energy.

+
Returns
double
+ +

Definition at line 135 of file IsingModel.cpp.

+ +
+
+ +

◆ get_M()

+ +
+
+ + + + + + + +
int IsingModel::get_M ()
+
+ +

Get the current magnetization.

+
Returns
double
+ +

Definition at line 140 of file IsingModel.cpp.

+ +
+
+ +

◆ initialize_energy()

+ +
+
+ + + + + +
+ + + + + + + +
void IsingModel::initialize_energy ()
+
+private
+
+ +

Initialize the energy.

+ +

Definition at line 82 of file IsingModel.cpp.

+ +
+
+ +

◆ initialize_energy_diff()

+ +
+
+ + + + + +
+ + + + + + + +
void IsingModel::initialize_energy_diff ()
+
+private
+
+ +

Initialize the hashmap with the correct values.

+ +

Definition at line 67 of file IsingModel.cpp.

+ +
+
+ +

◆ initialize_lattice()

+ +
+
+ + + + + +
+ + + + + + + +
void IsingModel::initialize_lattice ()
+
+private
+
+ +

Initialize the lattice with a random distribution of 1s and -1s.

+ +

Definition at line 44 of file IsingModel.cpp.

+ +
+
+ +

◆ initialize_magnetization()

+ +
+
+ + + + + +
+ + + + + + + +
void IsingModel::initialize_magnetization ()
+
+private
+
+ +

Initialize the magnetization.

+ +

Definition at line 74 of file IsingModel.cpp.

+ +
+
+ +

◆ initialize_neighbors()

+ +
+
+ + + + + +
+ + + + + + + +
void IsingModel::initialize_neighbors ()
+
+private
+
+ +

initialize the neighbors matrix.

+ +

Definition at line 56 of file IsingModel.cpp.

+ +
+
+ +

◆ Metropolis()

+ +
+
+ + + + + + + +
data_t IsingModel::Metropolis ()
+
+ +

The Metropolis algorithm.

+ +

Definition at line 96 of file IsingModel.cpp.

+ +
+
+

Friends And Related Function Documentation

+ +

◆ IsingModelTest

+ +
+
+ + + + + +
+ + + + +
friend class IsingModelTest
+
+friend
+
+ +

Definition at line 39 of file IsingModel.hpp.

+ +
+
+

Member Data Documentation

+ +

◆ E

+ +
+
+ + + + + +
+ + + + +
int IsingModel::E
+
+private
+
+ +

The current energy state. unit: \( J \).

+ +

Definition at line 68 of file IsingModel.hpp.

+ +
+
+ +

◆ energy_diff

+ +
+
+ + + + + +
+ + + + +
std::unordered_map<int, double> IsingModel::energy_diff
+
+private
+
+ +

A hash map containing all possible energy changes.

+ +

Definition at line 56 of file IsingModel.hpp.

+ +
+
+ +

◆ L

+ +
+
+ + + + + +
+ + + + +
int IsingModel::L
+
+private
+
+ +

Size of the lattice.

+ +

Definition at line 64 of file IsingModel.hpp.

+ +
+
+ +

◆ lattice

+ +
+
+ + + + + +
+ + + + +
arma::Mat<int> IsingModel::lattice
+
+private
+
+ +

\( L \times L \) matrix where element \( x \in {-1, 1}\).

+ +

Definition at line 42 of file IsingModel.hpp.

+ +
+
+ +

◆ M

+ +
+
+ + + + + +
+ + + + +
int IsingModel::M
+
+private
+
+ +

The current magnetic strength. unit: Unitless.

+ +

Definition at line 72 of file IsingModel.hpp.

+ +
+
+ +

◆ neighbors

+ +
+
+ + + + + +
+ + + + +
arma::Mat<int> IsingModel::neighbors
+
+private
+
+ +

\( L \times 2 \) matrix with the neighbors of each element \( x_i \).

+

The reason why it's \( L \times 2 \) instead of \( L \times 2 \), is that we can see that we can use the same column for the left and upper neighbor, and we can use the same column for the right and lower neighbor.

+ +

Definition at line 52 of file IsingModel.hpp.

+ +
+
+ +

◆ T

+ +
+
+ + + + + +
+ + + + +
double IsingModel::T
+
+private
+
+ +

The temperature of the model.

+ +

Definition at line 60 of file IsingModel.hpp.

+ +
+
+
The documentation for this class was generated from the following files: +
+
+ + + + diff --git a/docs/classIsingModel.js b/docs/classIsingModel.js new file mode 100644 index 0000000..8a0ca5c --- /dev/null +++ b/docs/classIsingModel.js @@ -0,0 +1,21 @@ +var classIsingModel = +[ + [ "IsingModel", "classIsingModel.html#acf281f6f5ed02911ca6ab07004449864", null ], + [ "IsingModel", "classIsingModel.html#a4a39ee7fbfbbf566f75bc28900ca9ea5", null ], + [ "IsingModel", "classIsingModel.html#a46c9446e94854452f715d307c77c1c15", null ], + [ "get_E", "classIsingModel.html#aaa0787d964b004a17869811a5e947ff5", null ], + [ "get_M", "classIsingModel.html#aa5701496e6483bc4668c486d6d3af625", null ], + [ "initialize_energy", "classIsingModel.html#a59fced38c695e2fa647f53be81b9d2a1", null ], + [ "initialize_energy_diff", "classIsingModel.html#aff9a1201933fd5408845a1447e4895b4", null ], + [ "initialize_lattice", "classIsingModel.html#a34a4710949b4a70f3e37ca223aefcf8a", null ], + [ "initialize_magnetization", "classIsingModel.html#a926cf4964d190d2ce23e5a17201787a4", null ], + [ "initialize_neighbors", "classIsingModel.html#a6776109105051597c275670dabd0054a", null ], + [ "Metropolis", "classIsingModel.html#a56559d68dc9aaff1976d84b157f43488", null ], + [ "E", "classIsingModel.html#ae9f872ca2054992161d53306119979dd", null ], + [ "energy_diff", "classIsingModel.html#a1a4ceb1bb2593dbd20c51ed04100cbcd", null ], + [ "L", "classIsingModel.html#a2b8ac43baefeb386186266d5aa4de348", null ], + [ "lattice", "classIsingModel.html#a2c3c76c79717c968d7c227c58b46df41", null ], + [ "M", "classIsingModel.html#a0d373a61baca6b0faa607bb12d82cc47", null ], + [ "neighbors", "classIsingModel.html#a94093aaf30facca62737f2ac381fdbcd", null ], + [ "T", "classIsingModel.html#a20fc4c0c99d8a119f70a1614784d4e5c", null ] +]; \ No newline at end of file diff --git a/docs/classIsingModelTest-members.html b/docs/classIsingModelTest-members.html new file mode 100644 index 0000000..7c1e2cb --- /dev/null +++ b/docs/classIsingModelTest-members.html @@ -0,0 +1,118 @@ + + + + + + + +2 Dimensional Ising Model: Member List + + + + + + + + + + + + + + + + +
+
+ + + + + + +
+
2 Dimensional Ising Model +
+
Simulate the change in energy and magnetization in a ferro magnet
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+
+
+
+
+
Loading...
+
Searching...
+
No Matches
+
+
+
+
+ +
+
IsingModelTest Member List
+
+
+ +

This is the complete list of members for IsingModelTest, including all inherited members.

+ + + +
test_2x2_lattice(double tol, int max_cycles)IsingModelTestinline
test_init_functions()IsingModelTestinline
+
+ + + + diff --git a/docs/classIsingModelTest.html b/docs/classIsingModelTest.html new file mode 100644 index 0000000..055b598 --- /dev/null +++ b/docs/classIsingModelTest.html @@ -0,0 +1,215 @@ + + + + + + + +2 Dimensional Ising Model: IsingModelTest Class Reference + + + + + + + + + + + + + + + + +
+
+ + + + + + +
+
2 Dimensional Ising Model +
+
Simulate the change in energy and magnetization in a ferro magnet
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+
+
+
+
+
Loading...
+
Searching...
+
No Matches
+
+
+
+
+ +
+ +
IsingModelTest Class Reference
+
+
+ +

Test class for the Ising model. + More...

+ + + + + + + + +

+Public Member Functions

void test_init_functions ()
 Test That initializing works as intended.
 
int test_2x2_lattice (double tol, int max_cycles)
 Test numerical data with analytical data.
 
+

Detailed Description

+

Test class for the Ising model.

+ +

Definition at line 30 of file test_suite.cpp.

+

Member Function Documentation

+ +

◆ test_2x2_lattice()

+ +
+
+ + + + + +
+ + + + + + + + + + + + + + + + + + +
int IsingModelTest::test_2x2_lattice (double tol,
int max_cycles 
)
+
+inline
+
+ +

Test numerical data with analytical data.

+
Parameters
+ + + +
tolThe tolerance between the analytical and numerical solution.
max_cyclesThe max number of Monte Carlo cycles.
+
+
+

return int

+ +

Definition at line 70 of file test_suite.cpp.

+ +
+
+ +

◆ test_init_functions()

+ +
+
+ + + + + +
+ + + + + + + +
void IsingModelTest::test_init_functions ()
+
+inline
+
+ +

Test That initializing works as intended.

+ +

Definition at line 34 of file test_suite.cpp.

+ +
+
+
The documentation for this class was generated from the following file: +
+
+ + + + diff --git a/docs/classIsingModelTest.js b/docs/classIsingModelTest.js new file mode 100644 index 0000000..bb3fd76 --- /dev/null +++ b/docs/classIsingModelTest.js @@ -0,0 +1,5 @@ +var classIsingModelTest = +[ + [ "test_2x2_lattice", "classIsingModelTest.html#a4ace7013fa2d257ad1747961da6bc4de", null ], + [ "test_init_functions", "classIsingModelTest.html#a717e5852ca51432a61fb6ed38da37931", null ] +]; \ No newline at end of file diff --git a/docs/classdata__t-members.html b/docs/classdata__t-members.html new file mode 100644 index 0000000..83e7c4a --- /dev/null +++ b/docs/classdata__t-members.html @@ -0,0 +1,130 @@ + + + + + + + +2 Dimensional Ising Model: Member List + + + + + + + + + + + + + + + + +
+
+ + + + + + +
+
2 Dimensional Ising Model +
+
Simulate the change in energy and magnetization in a ferro magnet
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+
+
+
+
+
Loading...
+
Searching...
+
No Matches
+
+
+
+
+ +
+
data_t Member List
+
+
+ +

This is the complete list of members for data_t, including all inherited members.

+ + + + + + + + + + + + + + + +
data_t() (defined in data_t)data_tinline
data_t(double E, double E2, double M, double M2, double M_abs) (defined in data_t)data_tinline
E (defined in data_t)data_t
E2 (defined in data_t)data_t
M (defined in data_t)data_t
M2 (defined in data_t)data_t
M_abs (defined in data_t)data_t
operator*(T num) (defined in data_t)data_tinline
operator*=(T num) (defined in data_t)data_tinline
operator+(const data_t &b) (defined in data_t)data_tinline
operator+=(const data_t &b) (defined in data_t)data_tinline
operator/(T num) (defined in data_t)data_tinline
operator/=(T num) (defined in data_t)data_tinline
operator=(T num) (defined in data_t)data_tinline
+
+ + + + diff --git a/docs/classdata__t.html b/docs/classdata__t.html new file mode 100644 index 0000000..4c8e8cb --- /dev/null +++ b/docs/classdata__t.html @@ -0,0 +1,534 @@ + + + + + + + +2 Dimensional Ising Model: data_t Class Reference + + + + + + + + + + + + + + + + +
+
+ + + + + + +
+
2 Dimensional Ising Model +
+
Simulate the change in energy and magnetization in a ferro magnet
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+
+
+
+
+
Loading...
+
Searching...
+
No Matches
+
+
+
+
+ + +
+ + + + + + + + + + + + + + + + + + + + + + + +

+Public Member Functions

 data_t (double E, double E2, double M, double M2, double M_abs)
 
template<class T >
data_t operator/ (T num)
 
template<class T >
data_toperator/= (T num)
 
template<class T >
data_t operator* (T num)
 
template<class T >
data_toperator*= (T num)
 
data_t operator+ (const data_t &b)
 
data_toperator+= (const data_t &b)
 
template<class T >
void operator= (T num)
 
+ + + + + + + + + + + +

+Public Attributes

double E
 
double M
 
double E2
 
double M2
 
double M_abs
 
+

Detailed Description

+
+

Definition at line 18 of file data_type.hpp.

+

Constructor & Destructor Documentation

+ +

◆ data_t() [1/2]

+ +
+
+ + + + + +
+ + + + + + + +
data_t::data_t ()
+
+inline
+
+ +

Definition at line 22 of file data_type.hpp.

+ +
+
+ +

◆ data_t() [2/2]

+ +
+
+ + + + + +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
data_t::data_t (double E,
double E2,
double M,
double M2,
double M_abs 
)
+
+inline
+
+ +

Definition at line 31 of file data_type.hpp.

+ +
+
+

Member Function Documentation

+ +

◆ operator*()

+ +
+
+
+template<class T >
+ + + + + +
+ + + + + + + + +
data_t data_t::operator* (num)
+
+inline
+
+ +

Definition at line 63 of file data_type.hpp.

+ +
+
+ +

◆ operator*=()

+ +
+
+
+template<class T >
+ + + + + +
+ + + + + + + + +
data_t & data_t::operator*= (num)
+
+inline
+
+ +

Definition at line 75 of file data_type.hpp.

+ +
+
+ +

◆ operator+()

+ +
+
+ + + + + +
+ + + + + + + + +
data_t data_t::operator+ (const data_tb)
+
+inline
+
+ +

Definition at line 86 of file data_type.hpp.

+ +
+
+ +

◆ operator+=()

+ +
+
+ + + + + +
+ + + + + + + + +
data_t & data_t::operator+= (const data_tb)
+
+inline
+
+ +

Definition at line 98 of file data_type.hpp.

+ +
+
+ +

◆ operator/()

+ +
+
+
+template<class T >
+ + + + + +
+ + + + + + + + +
data_t data_t::operator/ (num)
+
+inline
+
+ +

Definition at line 40 of file data_type.hpp.

+ +
+
+ +

◆ operator/=()

+ +
+
+
+template<class T >
+ + + + + +
+ + + + + + + + +
data_t & data_t::operator/= (num)
+
+inline
+
+ +

Definition at line 52 of file data_type.hpp.

+ +
+
+ +

◆ operator=()

+ +
+
+
+template<class T >
+ + + + + +
+ + + + + + + + +
void data_t::operator= (num)
+
+inline
+
+ +

Definition at line 109 of file data_type.hpp.

+ +
+
+

Member Data Documentation

+ +

◆ E

+ +
+
+ + + + +
double data_t::E
+
+ +

Definition at line 20 of file data_type.hpp.

+ +
+
+ +

◆ E2

+ +
+
+ + + + +
double data_t::E2
+
+ +

Definition at line 20 of file data_type.hpp.

+ +
+
+ +

◆ M

+ +
+
+ + + + +
double data_t::M
+
+ +

Definition at line 20 of file data_type.hpp.

+ +
+
+ +

◆ M2

+ +
+
+ + + + +
double data_t::M2
+
+ +

Definition at line 20 of file data_type.hpp.

+ +
+
+ +

◆ M_abs

+ +
+
+ + + + +
double data_t::M_abs
+
+ +

Definition at line 20 of file data_type.hpp.

+ +
+
+
The documentation for this class was generated from the following file: +
+
+ + + + diff --git a/docs/classes.html b/docs/classes.html new file mode 100644 index 0000000..a5414c5 --- /dev/null +++ b/docs/classes.html @@ -0,0 +1,122 @@ + + + + + + + +2 Dimensional Ising Model: Class Index + + + + + + + + + + + + + + + + +
+
+ + + + + + +
+
2 Dimensional Ising Model +
+
Simulate the change in energy and magnetization in a ferro magnet
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+
+
+
+
+
Loading...
+
Searching...
+
No Matches
+
+
+
+
+ +
+
Class Index
+
+
+
D | I
+ +
+
+ + + + diff --git a/docs/closed.png b/docs/closed.png new file mode 100644 index 0000000000000000000000000000000000000000..98cc2c909da37a6df914fbf67780eebd99c597f5 GIT binary patch literal 132 zcmeAS@N?(olHy`uVBq!ia0vp^oFL4>1|%O$WD@{V-kvUwAr*{o@8{^CZMh(5KoB^r_<4^zF@3)Cp&&t3hdujKf f*?bjBoY!V+E))@{xMcbjXe@)LtDnm{r-UW|*e5JT literal 0 HcmV?d00001 diff --git a/docs/constants_8hpp.html b/docs/constants_8hpp.html new file mode 100644 index 0000000..1dad5c8 --- /dev/null +++ b/docs/constants_8hpp.html @@ -0,0 +1,156 @@ + + + + + + + +2 Dimensional Ising Model: include/constants.hpp File Reference + + + + + + + + + + + + + + + + +
+
+ + + + + + +
+
2 Dimensional Ising Model +
+
Simulate the change in energy and magnetization in a ferro magnet
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+
+
+
+
+
Loading...
+
Searching...
+
No Matches
+
+
+
+
+ +
+ +
constants.hpp File Reference
+
+
+ +

Library of constants. +More...

+ +

Go to the source code of this file.

+ + + + + +

+Macros

#define k_B   1.380649e-23
 Boltzmann constant. unit \( \frac{J}{K} \).
 
+

Detailed Description

+

Library of constants.

+
Author
Cory Alexander Balaton (coryab)
+
+Janita Ovidie Sandtrøen Willumsen (janitaws)
+
Version
1.0
+
Bug:
No known bugs
+ +

Definition in file constants.hpp.

+

Macro Definition Documentation

+ +

◆ k_B

+ +
+
+ + + + +
#define k_B   1.380649e-23
+
+ +

Boltzmann constant. unit \( \frac{J}{K} \).

+ +

Definition at line 17 of file constants.hpp.

+ +
+
+
+
+ + + + diff --git a/docs/constants_8hpp.js b/docs/constants_8hpp.js new file mode 100644 index 0000000..cd95986 --- /dev/null +++ b/docs/constants_8hpp.js @@ -0,0 +1,4 @@ +var constants_8hpp = +[ + [ "k_B", "constants_8hpp.html#abfa7d6668c777f9516606394bbc9c414", null ] +]; \ No newline at end of file diff --git a/docs/constants_8hpp_source.html b/docs/constants_8hpp_source.html new file mode 100644 index 0000000..b377bdd --- /dev/null +++ b/docs/constants_8hpp_source.html @@ -0,0 +1,121 @@ + + + + + + + +2 Dimensional Ising Model: include/constants.hpp Source File + + + + + + + + + + + + + + + + +
+
+ + + + + + +
+
2 Dimensional Ising Model +
+
Simulate the change in energy and magnetization in a ferro magnet
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+
+
+
+
+
Loading...
+
Searching...
+
No Matches
+
+
+
+
+ +
+
constants.hpp
+
+
+Go to the documentation of this file.
1
+
12#ifndef __CONST__
+
13#define __CONST__
+
14
+
17#define k_B 1.380649e-23
+
18
+
19#endif
+
+
+ + + + diff --git a/docs/data__type_8cpp.html b/docs/data__type_8cpp.html new file mode 100644 index 0000000..e40f949 --- /dev/null +++ b/docs/data__type_8cpp.html @@ -0,0 +1,129 @@ + + + + + + + +2 Dimensional Ising Model: src/data_type.cpp File Reference + + + + + + + + + + + + + + + + +
+
+ + + + + + +
+
2 Dimensional Ising Model +
+
Simulate the change in energy and magnetization in a ferro magnet
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+
+
+
+
+
Loading...
+
Searching...
+
No Matches
+
+
+
+
+ +
+
data_type.cpp File Reference
+
+
+ +

Implementation for the data_t type. +More...

+
#include "data_type.hpp"
+
+

Go to the source code of this file.

+

Detailed Description

+

Implementation for the data_t type.

+
Author
Cory Alexander Balaton (coryab)
+
+Janita Ovidie Sandtrøen Willumsen (janitaws)
+
Version
1.0
+
Bug:
No known bugs
+ +

Definition in file data_type.cpp.

+
+
+ + + + diff --git a/docs/data__type_8cpp.js b/docs/data__type_8cpp.js new file mode 100644 index 0000000..4e61f36 --- /dev/null +++ b/docs/data__type_8cpp.js @@ -0,0 +1,7 @@ +var data__type_8cpp = +[ + [ "operator+", "data__type_8cpp.html#aeac60601d10d473f1dbc49340cd92ec7", null ], + [ "operator+=", "data__type_8cpp.html#a16f12c0123a28da1b455068a19c2c946", null ], + [ "operator/", "data__type_8cpp.html#ae5a8fce91c4342a7a4b39fb30a05ebb7", null ], + [ "operator/=", "data__type_8cpp.html#a5495478f6af965861b3274b17ebe6ba2", null ] +]; \ No newline at end of file diff --git a/docs/data__type_8cpp_source.html b/docs/data__type_8cpp_source.html new file mode 100644 index 0000000..087ddc0 --- /dev/null +++ b/docs/data__type_8cpp_source.html @@ -0,0 +1,117 @@ + + + + + + + +2 Dimensional Ising Model: src/data_type.cpp Source File + + + + + + + + + + + + + + + + +
+
+ + + + + + +
+
2 Dimensional Ising Model +
+
Simulate the change in energy and magnetization in a ferro magnet
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+
+
+
+
+
Loading...
+
Searching...
+
No Matches
+
+
+
+
+ +
+
data_type.cpp
+
+
+Go to the documentation of this file.
1
+
12#include "data_type.hpp"
+
Header for the data_t type.
+
+
+ + + + diff --git a/docs/data__type_8hpp.html b/docs/data__type_8hpp.html new file mode 100644 index 0000000..02f1bd4 --- /dev/null +++ b/docs/data__type_8hpp.html @@ -0,0 +1,138 @@ + + + + + + + +2 Dimensional Ising Model: include/data_type.hpp File Reference + + + + + + + + + + + + + + + + +
+
+ + + + + + +
+
2 Dimensional Ising Model +
+
Simulate the change in energy and magnetization in a ferro magnet
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+
+
+
+
+
Loading...
+
Searching...
+
No Matches
+
+
+
+
+ +
+ +
data_type.hpp File Reference
+
+
+ +

Header for the data_t type. +More...

+
#include <sys/types.h>
+#include <type_traits>
+
+

Go to the source code of this file.

+ + + + +

+Classes

class  data_t
 
+

Detailed Description

+

Header for the data_t type.

+
Author
Cory Alexander Balaton (coryab)
+
+Janita Ovidie Sandtrøen Willumsen (janitaws)
+
Version
1.0
+
Bug:
No known bugs
+ +

Definition in file data_type.hpp.

+
+
+ + + + diff --git a/docs/data__type_8hpp.js b/docs/data__type_8hpp.js new file mode 100644 index 0000000..80d6066 --- /dev/null +++ b/docs/data__type_8hpp.js @@ -0,0 +1,4 @@ +var data__type_8hpp = +[ + [ "data_t", "classdata__t.html", null ] +]; \ No newline at end of file diff --git a/docs/data__type_8hpp_source.html b/docs/data__type_8hpp_source.html new file mode 100644 index 0000000..30b1e71 --- /dev/null +++ b/docs/data__type_8hpp_source.html @@ -0,0 +1,224 @@ + + + + + + + +2 Dimensional Ising Model: include/data_type.hpp Source File + + + + + + + + + + + + + + + + +
+
+ + + + + + +
+
2 Dimensional Ising Model +
+
Simulate the change in energy and magnetization in a ferro magnet
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+
+
+
+
+
Loading...
+
Searching...
+
No Matches
+
+
+
+
+ +
+
data_type.hpp
+
+
+Go to the documentation of this file.
1
+
12#ifndef __DATA_TYPE__
+
13#define __DATA_TYPE__
+
14
+
15#include <sys/types.h>
+
16#include <type_traits>
+
17
+
18class data_t {
+
19public:
+
20 double E, M, E2, M2, M_abs;
+
21
+
22 data_t()
+
23 {
+
24 this->E = 0.;
+
25 this->E2 = 0.;
+
26 this->M = 0.;
+
27 this->M2 = 0.;
+
28 this->M_abs = 0.;
+
29 }
+
30
+
31 data_t(double E, double E2, double M, double M2, double M_abs)
+
32 {
+
33 this->E = E;
+
34 this->E2 = E2;
+
35 this->M = M;
+
36 this->M2 = M2;
+
37 this->M_abs = M_abs;
+
38 }
+
39
+
40 template <class T> data_t operator/(T num)
+
41 {
+
42 data_t res;
+
43 res.E = this->E / (double)num;
+
44 res.E2 = this->E2 / (double)num;
+
45 res.M = this->M / (double)num;
+
46 res.M2 = this->M2 / (double)num;
+
47 res.M_abs = this->M_abs / (double)num;
+
48
+
49 return res;
+
50 }
+
51
+
52 template <class T> data_t& operator/=(T num)
+
53 {
+
54 this->E /= (double)num;
+
55 this->E2 /= (double)num;
+
56 this->M /= (double)num;
+
57 this->M2 /= (double)num;
+
58 this->M_abs /= (double)num;
+
59
+
60 return *this;
+
61 }
+
62
+
63 template <class T> data_t operator*(T num)
+
64 {
+
65 data_t res;
+
66 res.E = this->E * (double)num;
+
67 res.E2 = this->E2 * (double)num;
+
68 res.M = this->M * (double)num;
+
69 res.M2 = this->M2 * (double)num;
+
70 res.M_abs = this->M_abs * (double)num;
+
71
+
72 return res;
+
73 }
+
74
+
75 template <class T> data_t& operator*=(T num)
+
76 {
+
77 this->E *= (double)num;
+
78 this->E2 *= (double)num;
+
79 this->M *= (double)num;
+
80 this->M2 *= (double)num;
+
81 this->M_abs *= (double)num;
+
82
+
83 return *this;
+
84 }
+
85
+
86 data_t operator+(const data_t &b)
+
87 {
+
88 data_t res;
+
89 res.E = this->E + b.E;
+
90 res.E2 = this->E2 + b.E2;
+
91 res.M = this->M + b.M;
+
92 res.M2 = this->M2 + b.M2;
+
93 res.M_abs = this->M_abs + b.M_abs;
+
94
+
95 return res;
+
96 }
+
97
+
98 data_t& operator+=(const data_t &b)
+
99 {
+
100 this->E += b.E;
+
101 this->E2 += b.E2;
+
102 this->M += b.M;
+
103 this->M2 += b.M2;
+
104 this->M_abs += b.M_abs;
+
105
+
106 return *this;
+
107 }
+
108
+
109 template <class T> void operator=(T num)
+
110 {
+
111 this->E = (double)num;
+
112 this->E2 = (double)num;
+
113 this->M = (double)num;
+
114 this->M2 = (double)num;
+
115 this->M_abs = (double)num;
+
116 }
+
117};
+
118
+
119#endif
+ +
+
+ + + + diff --git a/docs/dir_634e799a3947388232110823971192a8.html b/docs/dir_634e799a3947388232110823971192a8.html new file mode 100644 index 0000000..0517a4e --- /dev/null +++ b/docs/dir_634e799a3947388232110823971192a8.html @@ -0,0 +1,124 @@ + + + + + + + +2 Dimensional Ising Model: src/scripts Directory Reference + + + + + + + + + + + + + + + + +
+
+ + + + + + +
+
2 Dimensional Ising Model +
+
Simulate the change in energy and magnetization in a ferro magnet
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+
+
+
+
+
Loading...
+
Searching...
+
No Matches
+
+
+
+
+ +
+
scripts Directory Reference
+
+
+ + + + + + + + +

+Files

file  burn_in_time.py [code]
 
file  pd_estimate.py [code]
 
file  phase_transition.py [code]
 
+
+
+ + + + diff --git a/docs/dir_634e799a3947388232110823971192a8.js b/docs/dir_634e799a3947388232110823971192a8.js new file mode 100644 index 0000000..5a4fc47 --- /dev/null +++ b/docs/dir_634e799a3947388232110823971192a8.js @@ -0,0 +1,6 @@ +var dir_634e799a3947388232110823971192a8 = +[ + [ "burn_in_time.py", "burn__in__time_8py_source.html", null ], + [ "pd_estimate.py", "pd__estimate_8py_source.html", null ], + [ "phase_transition.py", "phase__transition_8py_source.html", null ] +]; \ No newline at end of file diff --git a/docs/dir_68267d1309a1af8e8297ef4c3efbcdba.html b/docs/dir_68267d1309a1af8e8297ef4c3efbcdba.html new file mode 100644 index 0000000..75f9ece --- /dev/null +++ b/docs/dir_68267d1309a1af8e8297ef4c3efbcdba.html @@ -0,0 +1,147 @@ + + + + + + + +2 Dimensional Ising Model: src Directory Reference + + + + + + + + + + + + + + + + +
+
+ + + + + + +
+
2 Dimensional Ising Model +
+
Simulate the change in energy and magnetization in a ferro magnet
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+
+
+
+
+
Loading...
+
Searching...
+
No Matches
+
+
+
+
+ +
+
src Directory Reference
+
+
+ + + + +

+Directories

directory  scripts
 
+ + + + + + + + + + + + + + + + + + + + + + + + + +

+Files

file  data_type.cpp [code]
 Implementation for the data_t type.
 
file  IsingModel.cpp [code]
 The implementation of the Ising model.
 
file  main.cpp [code]
 The main program.
 
file  monte_carlo.cpp [code]
 Implementation of the monte carlo functions.
 
file  phase_transition_mpi.cpp [code]
 Sweep over different temperatures and generate data.
 
file  test_suite.cpp [code]
 Sweep over different temperatures and generate data.
 
file  testlib.cpp [code]
 Implementation of the testing library.
 
file  utils.cpp [code]
 Implementation of the utils.
 
+
+
+ + + + diff --git a/docs/dir_68267d1309a1af8e8297ef4c3efbcdba.js b/docs/dir_68267d1309a1af8e8297ef4c3efbcdba.js new file mode 100644 index 0000000..90dbe2d --- /dev/null +++ b/docs/dir_68267d1309a1af8e8297ef4c3efbcdba.js @@ -0,0 +1,12 @@ +var dir_68267d1309a1af8e8297ef4c3efbcdba = +[ + [ "scripts", "dir_634e799a3947388232110823971192a8.html", "dir_634e799a3947388232110823971192a8" ], + [ "data_type.cpp", "data__type_8cpp.html", null ], + [ "IsingModel.cpp", "IsingModel_8cpp.html", null ], + [ "main.cpp", "main_8cpp.html", "main_8cpp" ], + [ "monte_carlo.cpp", "monte__carlo_8cpp.html", "monte__carlo_8cpp" ], + [ "phase_transition_mpi.cpp", "phase__transition__mpi_8cpp.html", "phase__transition__mpi_8cpp" ], + [ "test_suite.cpp", "test__suite_8cpp.html", "test__suite_8cpp" ], + [ "testlib.cpp", "testlib_8cpp.html", "testlib_8cpp" ], + [ "utils.cpp", "utils_8cpp.html", "utils_8cpp" ] +]; \ No newline at end of file diff --git a/docs/dir_d44c64559bbebec7f509842c48db8b23.html b/docs/dir_d44c64559bbebec7f509842c48db8b23.html new file mode 100644 index 0000000..9348629 --- /dev/null +++ b/docs/dir_d44c64559bbebec7f509842c48db8b23.html @@ -0,0 +1,139 @@ + + + + + + + +2 Dimensional Ising Model: include Directory Reference + + + + + + + + + + + + + + + + +
+
+ + + + + + +
+
2 Dimensional Ising Model +
+
Simulate the change in energy and magnetization in a ferro magnet
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+
+
+
+
+
Loading...
+
Searching...
+
No Matches
+
+
+
+
+ +
+
include Directory Reference
+
+
+ + + + + + + + + + + + + + + + + + + + + + + +

+Files

file  constants.hpp [code]
 Library of constants.
 
file  data_type.hpp [code]
 Header for the data_t type.
 
file  IsingModel.hpp [code]
 The definition of the Ising model.
 
file  monte_carlo.hpp [code]
 Functions for monte carlo simulations.
 
file  testlib.hpp [code]
 A small test library.
 
file  typedefs.hpp [code]
 Useful typedefs for cleaner code.
 
file  utils.hpp [code]
 Function prototypes and macros that are useful.
 
+
+
+ + + + diff --git a/docs/dir_d44c64559bbebec7f509842c48db8b23.js b/docs/dir_d44c64559bbebec7f509842c48db8b23.js new file mode 100644 index 0000000..aeac9c5 --- /dev/null +++ b/docs/dir_d44c64559bbebec7f509842c48db8b23.js @@ -0,0 +1,10 @@ +var dir_d44c64559bbebec7f509842c48db8b23 = +[ + [ "constants.hpp", "constants_8hpp.html", "constants_8hpp" ], + [ "data_type.hpp", "data__type_8hpp.html", "data__type_8hpp" ], + [ "IsingModel.hpp", "IsingModel_8hpp.html", "IsingModel_8hpp" ], + [ "monte_carlo.hpp", "monte__carlo_8hpp.html", "monte__carlo_8hpp" ], + [ "testlib.hpp", "testlib_8hpp.html", "testlib_8hpp" ], + [ "typedefs.hpp", "typedefs_8hpp.html", null ], + [ "utils.hpp", "utils_8hpp.html", "utils_8hpp" ] +]; \ No newline at end of file diff --git a/docs/doc.png b/docs/doc.png new file mode 100644 index 0000000000000000000000000000000000000000..17edabff95f7b8da13c9516a04efe05493c29501 GIT binary patch literal 746 zcmV7=@pnbNXRFEm&G8P!&WHG=d)>K?YZ1bzou)2{$)) zumDct!>4SyxL;zgaG>wy`^Hv*+}0kUfCrz~BCOViSb$_*&;{TGGn2^x9K*!Sf0=lV zpP=7O;GA0*Jm*tTYj$IoXvimpnV4S1Z5f$p*f$Db2iq2zrVGQUz~yq`ahn7ck(|CE z7Gz;%OP~J6)tEZWDzjhL9h2hdfoU2)Nd%T<5Kt;Y0XLt&<@6pQx!nw*5`@bq#?l*?3z{Hlzoc=Pr>oB5(9i6~_&-}A(4{Q$>c>%rV&E|a(r&;?i5cQB=} zYSDU5nXG)NS4HEs0it2AHe2>shCyr7`6@4*6{r@8fXRbTA?=IFVWAQJL&H5H{)DpM#{W(GL+Idzf^)uRV@oB8u$ z8v{MfJbTiiRg4bza<41NAzrl{=3fl_D+$t+^!xlQ8S}{UtY`e z;;&9UhyZqQRN%2pot{*Ei0*4~hSF_3AH2@fKU!$NSflS>{@tZpDT4`M2WRTTVH+D? z)GFlEGGHe?koB}i|1w45!BF}N_q&^HJ&-tyR{(afC6H7|aml|tBBbv}55C5DNP8p3 z)~jLEO4Z&2hZmP^i-e%(@d!(E|KRafiU8Q5u(wU((j8un3OR*Hvj+t literal 0 HcmV?d00001 diff --git a/docs/docd.png b/docs/docd.png new file mode 100644 index 0000000000000000000000000000000000000000..d7c94fda9bf08ecc02c7190d968452b7a2dbf04b GIT binary patch literal 756 zcmV1wr-rhpn+wxm%q2)IkAYsr{iGq<}_z5JCD4J;FN?6Qh;@TCubdp(_XdD-^ zG_#)IP7_z6hKNdx5^+FGArwLWTWCG!j+oKji?U!hxA#d-ljgkN`+e^@-P+RWG{Bx= z2iQyYTtEf*o~ySWrIVW}HWHi0_hd4~$E6Jx1U`>Owo}EYJ1O>iZvS?!z8}B}QwLMA zC3Keqf1c}K@?C`X>68b(EUzYUYAS&OH^VPteZLPr{S&|nQvp@6W4GH-1U8!u&7l~A zx~RUSNH+>7@q38W6!BzirtjLFCzc|XGx)EF#G%^pWION*k@?vP<2O>|XkCD3ujl%1 z{55JSVkw{~HbX>iEZ2%yJ2eHj5Yh8OTpzs0A2;tZ^x!#5D+y-es{k1&0|Ns9-|+Xt ziGiTsZ8(^nUo#wdTpIDkb-Zp(3|A*FzW}GZ5SQD-r^R`&X@`26E3W|GyrwDIZjtQ& z$g5f8Sv=VgVtDien@J(!^BK+#l;s-LgP--p7C;7;E!ysXcXK6?+9D>_-B(?Wm(U zQbNm-5TyYxIU=rs0+)!ixqzhuxw(AqKc3?KKX32{D~Qibp*r0x&Wux5-9WCMMRi3U zTd6dOCQlj>a;gr;gLwRKulT&(m@^L{&HkSC(qH05HSSf$YEhynGvH zWNez``Z8FJXE+BSg=%ak{OR z+Nylcb{?evLYLuE1_HngYw0g%LC#=$a@?4~Tx>F9295Q>9UJ|_6v-KMw;!YZSgGj@ zR8fRov=hJ#QvsO@xw*{0%zH@OKVEUr= 768px. On smaller screen the menu is always visible. + * `GENERATE_TREEVIEW` MUST be enabled! + */ + --menu-display: block; + + --menu-focus-foreground: var(--page-background-color); + --menu-focus-background: var(--primary-color); + --menu-selected-background: rgba(0,0,0,.05); + + + --header-background: var(--page-background-color); + --header-foreground: var(--page-foreground-color); + + /* searchbar colors */ + --searchbar-background: var(--side-nav-background); + --searchbar-foreground: var(--page-foreground-color); + + /* searchbar size + * (`searchbar-width` is only applied on screens >= 768px. + * on smaller screens the searchbar will always fill the entire screen width) */ + --searchbar-height: 33px; + --searchbar-width: 210px; + --searchbar-border-radius: var(--searchbar-height); + + /* code block colors */ + --code-background: #f5f5f5; + --code-foreground: var(--page-foreground-color); + + /* fragment colors */ + --fragment-background: #F8F9FA; + --fragment-foreground: #37474F; + --fragment-keyword: #bb6bb2; + --fragment-keywordtype: #8258b3; + --fragment-keywordflow: #d67c3b; + --fragment-token: #438a59; + --fragment-comment: #969696; + --fragment-link: #5383d6; + --fragment-preprocessor: #46aaa5; + --fragment-linenumber-color: #797979; + --fragment-linenumber-background: #f4f4f5; + --fragment-linenumber-border: #e3e5e7; + --fragment-lineheight: 20px; + + /* sidebar navigation (treeview) colors */ + --side-nav-background: #fbfbfb; + --side-nav-foreground: var(--page-foreground-color); + --side-nav-arrow-opacity: 0; + --side-nav-arrow-hover-opacity: 0.9; + + --toc-background: var(--side-nav-background); + --toc-foreground: var(--side-nav-foreground); + + /* height of an item in any tree / collapsible table */ + --tree-item-height: 30px; + + --memname-font-size: var(--code-font-size); + --memtitle-font-size: 18px; + + --webkit-scrollbar-size: 7px; + --webkit-scrollbar-padding: 4px; + --webkit-scrollbar-color: var(--separator-color); +} + +@media screen and (max-width: 767px) { + html { + --page-font-size: 16px; + --navigation-font-size: 16px; + --toc-font-size: 15px; + --code-font-size: 15px; /* affects code, fragment */ + --title-font-size: 22px; + } +} + +@media (prefers-color-scheme: dark) { + html:not(.light-mode) { + color-scheme: dark; + + --primary-color: #1982d2; + --primary-dark-color: #86a9c4; + --primary-light-color: #4779ac; + + --box-shadow: 0 2px 8px 0 rgba(0,0,0,.35); + + --odd-color: rgba(100,100,100,.06); + + --menu-selected-background: rgba(0,0,0,.4); + + --page-background-color: #1C1D1F; + --page-foreground-color: #d2dbde; + --page-secondary-foreground-color: #859399; + --separator-color: #38393b; + --side-nav-background: #252628; + + --code-background: #2a2c2f; + + --tablehead-background: #2a2c2f; + + --blockquote-background: #222325; + --blockquote-foreground: #7e8c92; + + --warning-color: #2e1917; + --warning-color-dark: #ad2617; + --warning-color-darker: #f5b1aa; + --note-color: #3b2e04; + --note-color-dark: #f1b602; + --note-color-darker: #ceb670; + --todo-color: #163750; + --todo-color-dark: #1982D2; + --todo-color-darker: #dcf0fa; + --deprecated-color: #2e323b; + --deprecated-color-dark: #738396; + --deprecated-color-darker: #abb0bd; + --bug-color: #2a2536; + --bug-color-dark: #7661b3; + --bug-color-darker: #ae9ed6; + --invariant-color: #303a35; + --invariant-color-dark: #76ce96; + --invariant-color-darker: #cceed5; + + --fragment-background: #282c34; + --fragment-foreground: #dbe4eb; + --fragment-keyword: #cc99cd; + --fragment-keywordtype: #ab99cd; + --fragment-keywordflow: #e08000; + --fragment-token: #7ec699; + --fragment-comment: #999999; + --fragment-link: #98c0e3; + --fragment-preprocessor: #65cabe; + --fragment-linenumber-color: #cccccc; + --fragment-linenumber-background: #35393c; + --fragment-linenumber-border: #1f1f1f; + } +} + +/* dark mode variables are defined twice, to support both the dark-mode without and with doxygen-awesome-darkmode-toggle.js */ +html.dark-mode { + color-scheme: dark; + + --primary-color: #1982d2; + --primary-dark-color: #86a9c4; + --primary-light-color: #4779ac; + + --box-shadow: 0 2px 8px 0 rgba(0,0,0,.30); + + --odd-color: rgba(100,100,100,.06); + + --menu-selected-background: rgba(0,0,0,.4); + + --page-background-color: #1C1D1F; + --page-foreground-color: #d2dbde; + --page-secondary-foreground-color: #859399; + --separator-color: #38393b; + --side-nav-background: #252628; + + --code-background: #2a2c2f; + + --tablehead-background: #2a2c2f; + + --blockquote-background: #222325; + --blockquote-foreground: #7e8c92; + + --warning-color: #2e1917; + --warning-color-dark: #ad2617; + --warning-color-darker: #f5b1aa; + --note-color: #3b2e04; + --note-color-dark: #f1b602; + --note-color-darker: #ceb670; + --todo-color: #163750; + --todo-color-dark: #1982D2; + --todo-color-darker: #dcf0fa; + --deprecated-color: #2e323b; + --deprecated-color-dark: #738396; + --deprecated-color-darker: #abb0bd; + --bug-color: #2a2536; + --bug-color-dark: #7661b3; + --bug-color-darker: #ae9ed6; + --invariant-color: #303a35; + --invariant-color-dark: #76ce96; + --invariant-color-darker: #cceed5; + + --fragment-background: #282c34; + --fragment-foreground: #dbe4eb; + --fragment-keyword: #cc99cd; + --fragment-keywordtype: #ab99cd; + --fragment-keywordflow: #e08000; + --fragment-token: #7ec699; + --fragment-comment: #999999; + --fragment-link: #98c0e3; + --fragment-preprocessor: #65cabe; + --fragment-linenumber-color: #cccccc; + --fragment-linenumber-background: #35393c; + --fragment-linenumber-border: #1f1f1f; +} + +body { + color: var(--page-foreground-color); + background-color: var(--page-background-color); + font-size: var(--page-font-size); +} + +body, table, div, p, dl, #nav-tree .label, .title, +.sm-dox a, .sm-dox a:hover, .sm-dox a:focus, #projectname, +.SelectItem, #MSearchField, .navpath li.navelem a, +.navpath li.navelem a:hover, p.reference, p.definition { + font-family: var(--font-family); +} + +h1, h2, h3, h4, h5 { + margin-top: .9em; + font-weight: 600; + line-height: initial; +} + +p, div, table, dl, p.reference, p.definition { + font-size: var(--page-font-size); +} + +p.reference, p.definition { + color: var(--page-secondary-foreground-color); +} + +a:link, a:visited, a:hover, a:focus, a:active { + color: var(--primary-color) !important; + font-weight: 500; +} + +a.anchor { + scroll-margin-top: var(--spacing-large); + display: block; +} + +/* + Title and top navigation + */ + +#top { + background: var(--header-background); + border-bottom: 1px solid var(--separator-color); +} + +@media screen and (min-width: 768px) { + #top { + display: flex; + flex-wrap: wrap; + justify-content: space-between; + align-items: center; + } +} + +#main-nav { + flex-grow: 5; + padding: var(--spacing-small) var(--spacing-medium); +} + +#titlearea { + width: auto; + padding: var(--spacing-medium) var(--spacing-large); + background: none; + color: var(--header-foreground); + border-bottom: none; +} + +@media screen and (max-width: 767px) { + #titlearea { + padding-bottom: var(--spacing-small); + } +} + +#titlearea table tbody tr { + height: auto !important; +} + +#projectname { + font-size: var(--title-font-size); + font-weight: 600; +} + +#projectnumber { + font-family: inherit; + font-size: 60%; +} + +#projectbrief { + font-family: inherit; + font-size: 80%; +} + +#projectlogo { + vertical-align: middle; +} + +#projectlogo img { + max-height: calc(var(--title-font-size) * 2); + margin-right: var(--spacing-small); +} + +.sm-dox, .tabs, .tabs2, .tabs3 { + background: none; + padding: 0; +} + +.tabs, .tabs2, .tabs3 { + border-bottom: 1px solid var(--separator-color); + margin-bottom: -1px; +} + +.main-menu-btn-icon, .main-menu-btn-icon:before, .main-menu-btn-icon:after { + background: var(--page-secondary-foreground-color); +} + +@media screen and (max-width: 767px) { + .sm-dox a span.sub-arrow { + background: var(--code-background); + } + + #main-menu a.has-submenu span.sub-arrow { + color: var(--page-secondary-foreground-color); + border-radius: var(--border-radius-medium); + } + + #main-menu a.has-submenu:hover span.sub-arrow { + color: var(--page-foreground-color); + } +} + +@media screen and (min-width: 768px) { + .sm-dox li, .tablist li { + display: var(--menu-display); + } + + .sm-dox a span.sub-arrow { + border-color: var(--header-foreground) transparent transparent transparent; + } + + .sm-dox a:hover span.sub-arrow { + border-color: var(--menu-focus-foreground) transparent transparent transparent; + } + + .sm-dox ul a span.sub-arrow { + border-color: transparent transparent transparent var(--page-foreground-color); + } + + .sm-dox ul a:hover span.sub-arrow { + border-color: transparent transparent transparent var(--menu-focus-foreground); + } +} + +.sm-dox ul { + background: var(--page-background-color); + box-shadow: var(--box-shadow); + border: 1px solid var(--separator-color); + border-radius: var(--border-radius-medium) !important; + padding: var(--spacing-small); + animation: ease-out 150ms slideInMenu; +} + +@keyframes slideInMenu { + from { + opacity: 0; + transform: translate(0px, -2px); + } + + to { + opacity: 1; + transform: translate(0px, 0px); + } +} + +.sm-dox ul a { + color: var(--page-foreground-color) !important; + background: var(--page-background-color); + font-size: var(--navigation-font-size); +} + +.sm-dox>li>ul:after { + border-bottom-color: var(--page-background-color) !important; +} + +.sm-dox>li>ul:before { + border-bottom-color: var(--separator-color) !important; +} + +.sm-dox ul a:hover, .sm-dox ul a:active, .sm-dox ul a:focus { + font-size: var(--navigation-font-size) !important; + color: var(--menu-focus-foreground) !important; + text-shadow: none; + background-color: var(--menu-focus-background); + border-radius: var(--border-radius-small) !important; +} + +.sm-dox a, .sm-dox a:focus, .tablist li, .tablist li a, .tablist li.current a { + text-shadow: none; + background: transparent; + background-image: none !important; + color: var(--header-foreground) !important; + font-weight: normal; + font-size: var(--navigation-font-size); + border-radius: var(--border-radius-small) !important; +} + +.sm-dox a:focus { + outline: auto; +} + +.sm-dox a:hover, .sm-dox a:active, .tablist li a:hover { + text-shadow: none; + font-weight: normal; + background: var(--menu-focus-background); + color: var(--menu-focus-foreground) !important; + border-radius: var(--border-radius-small) !important; + font-size: var(--navigation-font-size); +} + +.tablist li.current { + border-radius: var(--border-radius-small); + background: var(--menu-selected-background); +} + +.tablist li { + margin: var(--spacing-small) 0 var(--spacing-small) var(--spacing-small); +} + +.tablist a { + padding: 0 var(--spacing-large); +} + + +/* + Search box + */ + +#MSearchBox { + height: var(--searchbar-height); + background: var(--searchbar-background); + border-radius: var(--searchbar-border-radius); + border: 1px solid var(--separator-color); + overflow: hidden; + width: var(--searchbar-width); + position: relative; + box-shadow: none; + display: block; + margin-top: 0; +} + +/* until Doxygen 1.9.4 */ +.left img#MSearchSelect { + left: 0; + user-select: none; + padding-left: 8px; +} + +/* Doxygen 1.9.5 */ +.left span#MSearchSelect { + left: 0; + user-select: none; + margin-left: 8px; + padding: 0; +} + +.left #MSearchSelect[src$=".png"] { + padding-left: 0 +} + +.SelectionMark { + user-select: none; +} + +.tabs .left #MSearchSelect { + padding-left: 0; +} + +.tabs #MSearchBox { + position: absolute; + right: var(--spacing-medium); +} + +@media screen and (max-width: 767px) { + .tabs #MSearchBox { + position: relative; + right: 0; + margin-left: var(--spacing-medium); + margin-top: 0; + } +} + +#MSearchSelectWindow, #MSearchResultsWindow { + z-index: 9999; +} + +#MSearchBox.MSearchBoxActive { + border-color: var(--primary-color); + box-shadow: inset 0 0 0 1px var(--primary-color); +} + +#main-menu > li:last-child { + margin-right: 0; +} + +@media screen and (max-width: 767px) { + #main-menu > li:last-child { + height: 50px; + } +} + +#MSearchField { + font-size: var(--navigation-font-size); + height: calc(var(--searchbar-height) - 2px); + background: transparent; + width: calc(var(--searchbar-width) - 64px); +} + +.MSearchBoxActive #MSearchField { + color: var(--searchbar-foreground); +} + +#MSearchSelect { + top: calc(calc(var(--searchbar-height) / 2) - 11px); +} + +#MSearchBox span.left, #MSearchBox span.right { + background: none; + background-image: none; +} + +#MSearchBox span.right { + padding-top: calc(calc(var(--searchbar-height) / 2) - 12px); + position: absolute; + right: var(--spacing-small); +} + +.tabs #MSearchBox span.right { + top: calc(calc(var(--searchbar-height) / 2) - 12px); +} + +@keyframes slideInSearchResults { + from { + opacity: 0; + transform: translate(0, 15px); + } + + to { + opacity: 1; + transform: translate(0, 20px); + } +} + +#MSearchResultsWindow { + left: auto !important; + right: var(--spacing-medium); + border-radius: var(--border-radius-large); + border: 1px solid var(--separator-color); + transform: translate(0, 20px); + box-shadow: var(--box-shadow); + animation: ease-out 280ms slideInSearchResults; + background: var(--page-background-color); +} + +iframe#MSearchResults { + margin: 4px; +} + +iframe { + color-scheme: normal; +} + +@media (prefers-color-scheme: dark) { + html:not(.light-mode) iframe#MSearchResults { + filter: invert() hue-rotate(180deg); + } +} + +html.dark-mode iframe#MSearchResults { + filter: invert() hue-rotate(180deg); +} + +#MSearchResults .SRPage { + background-color: transparent; +} + +#MSearchResults .SRPage .SREntry { + font-size: 10pt; + padding: var(--spacing-small) var(--spacing-medium); +} + +#MSearchSelectWindow { + border: 1px solid var(--separator-color); + border-radius: var(--border-radius-medium); + box-shadow: var(--box-shadow); + background: var(--page-background-color); + padding-top: var(--spacing-small); + padding-bottom: var(--spacing-small); +} + +#MSearchSelectWindow a.SelectItem { + font-size: var(--navigation-font-size); + line-height: var(--content-line-height); + margin: 0 var(--spacing-small); + border-radius: var(--border-radius-small); + color: var(--page-foreground-color) !important; + font-weight: normal; +} + +#MSearchSelectWindow a.SelectItem:hover { + background: var(--menu-focus-background); + color: var(--menu-focus-foreground) !important; +} + +@media screen and (max-width: 767px) { + #MSearchBox { + margin-top: var(--spacing-medium); + margin-bottom: var(--spacing-medium); + width: calc(100vw - 30px); + } + + #main-menu > li:last-child { + float: none !important; + } + + #MSearchField { + width: calc(100vw - 110px); + } + + @keyframes slideInSearchResultsMobile { + from { + opacity: 0; + transform: translate(0, 15px); + } + + to { + opacity: 1; + transform: translate(0, 20px); + } + } + + #MSearchResultsWindow { + left: var(--spacing-medium) !important; + right: var(--spacing-medium); + overflow: auto; + transform: translate(0, 20px); + animation: ease-out 280ms slideInSearchResultsMobile; + width: auto !important; + } + + /* + * Overwrites for fixing the searchbox on mobile in doxygen 1.9.2 + */ + label.main-menu-btn ~ #searchBoxPos1 { + top: 3px !important; + right: 6px !important; + left: 45px; + display: flex; + } + + label.main-menu-btn ~ #searchBoxPos1 > #MSearchBox { + margin-top: 0; + margin-bottom: 0; + flex-grow: 2; + float: left; + } +} + +/* + Tree view + */ + +#side-nav { + padding: 0 !important; + background: var(--side-nav-background); + min-width: 8px; + max-width: 50vw; +} + +@media screen and (max-width: 767px) { + #side-nav { + display: none; + } + + #doc-content { + margin-left: 0 !important; + } +} + +#nav-tree { + background: transparent; + margin-right: 1px; +} + +#nav-tree .label { + font-size: var(--navigation-font-size); +} + +#nav-tree .item { + height: var(--tree-item-height); + line-height: var(--tree-item-height); +} + +#nav-sync { + bottom: 12px; + right: 12px; + top: auto !important; + user-select: none; +} + +#nav-tree .selected { + text-shadow: none; + background-image: none; + background-color: transparent; + position: relative; +} + +#nav-tree .selected::after { + content: ""; + position: absolute; + top: 1px; + bottom: 1px; + left: 0; + width: 4px; + border-radius: 0 var(--border-radius-small) var(--border-radius-small) 0; + background: var(--primary-color); +} + + +#nav-tree a { + color: var(--side-nav-foreground) !important; + font-weight: normal; +} + +#nav-tree a:focus { + outline-style: auto; +} + +#nav-tree .arrow { + opacity: var(--side-nav-arrow-opacity); +} + +.arrow { + color: inherit; + cursor: pointer; + font-size: 45%; + vertical-align: middle; + margin-right: 2px; + font-family: serif; + height: auto; + text-align: right; +} + +#nav-tree div.item:hover .arrow, #nav-tree a:focus .arrow { + opacity: var(--side-nav-arrow-hover-opacity); +} + +#nav-tree .selected a { + color: var(--primary-color) !important; + font-weight: bolder; + font-weight: 600; +} + +.ui-resizable-e { + width: 4px; + background: transparent; + box-shadow: inset -1px 0 0 0 var(--separator-color); +} + +/* + Contents + */ + +div.header { + border-bottom: 1px solid var(--separator-color); + background-color: var(--page-background-color); + background-image: none; +} + +@media screen and (min-width: 1000px) { + #doc-content > div > div.contents, + .PageDoc > div.contents { + display: flex; + flex-direction: row-reverse; + flex-wrap: nowrap; + align-items: flex-start; + } + + div.contents .textblock { + min-width: 200px; + flex-grow: 1; + } +} + +div.contents, div.header .title, div.header .summary { + max-width: var(--content-maxwidth); +} + +div.contents, div.header .title { + line-height: initial; + margin: calc(var(--spacing-medium) + .2em) auto var(--spacing-medium) auto; +} + +div.header .summary { + margin: var(--spacing-medium) auto 0 auto; +} + +div.headertitle { + padding: 0; +} + +div.header .title { + font-weight: 600; + font-size: 225%; + padding: var(--spacing-medium) var(--spacing-large); + word-break: break-word; +} + +div.header .summary { + width: auto; + display: block; + float: none; + padding: 0 var(--spacing-large); +} + +td.memSeparator { + border-color: var(--separator-color); +} + +span.mlabel { + background: var(--primary-color); + border: none; + padding: 4px 9px; + border-radius: 12px; + margin-right: var(--spacing-medium); +} + +span.mlabel:last-of-type { + margin-right: 2px; +} + +div.contents { + padding: 0 var(--spacing-large); +} + +div.contents p, div.contents li { + line-height: var(--content-line-height); +} + +div.contents div.dyncontent { + margin: var(--spacing-medium) 0; +} + +@media (prefers-color-scheme: dark) { + html:not(.light-mode) div.contents div.dyncontent img, + html:not(.light-mode) div.contents center img, + html:not(.light-mode) div.contents > table img, + html:not(.light-mode) div.contents div.dyncontent iframe, + html:not(.light-mode) div.contents center iframe, + html:not(.light-mode) div.contents table iframe, + html:not(.light-mode) div.contents .dotgraph iframe { + filter: brightness(89%) hue-rotate(180deg) invert(); + } +} + +html.dark-mode div.contents div.dyncontent img, +html.dark-mode div.contents center img, +html.dark-mode div.contents > table img, +html.dark-mode div.contents div.dyncontent iframe, +html.dark-mode div.contents center iframe, +html.dark-mode div.contents table iframe, +html.dark-mode div.contents .dotgraph iframe + { + filter: brightness(89%) hue-rotate(180deg) invert(); +} + +h2.groupheader { + border-bottom: 0px; + color: var(--page-foreground-color); + box-shadow: + 100px 0 var(--page-background-color), + -100px 0 var(--page-background-color), + 100px 0.75px var(--separator-color), + -100px 0.75px var(--separator-color), + 500px 0 var(--page-background-color), + -500px 0 var(--page-background-color), + 500px 0.75px var(--separator-color), + -500px 0.75px var(--separator-color), + 900px 0 var(--page-background-color), + -900px 0 var(--page-background-color), + 900px 0.75px var(--separator-color), + -900px 0.75px var(--separator-color), + 1400px 0 var(--page-background-color), + -1400px 0 var(--page-background-color), + 1400px 0.75px var(--separator-color), + -1400px 0.75px var(--separator-color), + 1900px 0 var(--page-background-color), + -1900px 0 var(--page-background-color), + 1900px 0.75px var(--separator-color), + -1900px 0.75px var(--separator-color); +} + +blockquote { + margin: 0 var(--spacing-medium) 0 var(--spacing-medium); + padding: var(--spacing-small) var(--spacing-large); + background: var(--blockquote-background); + color: var(--blockquote-foreground); + border-left: 0; + overflow: visible; + border-radius: var(--border-radius-medium); + overflow: visible; + position: relative; +} + +blockquote::before, blockquote::after { + font-weight: bold; + font-family: serif; + font-size: 360%; + opacity: .15; + position: absolute; +} + +blockquote::before { + content: "“"; + left: -10px; + top: 4px; +} + +blockquote::after { + content: "”"; + right: -8px; + bottom: -25px; +} + +blockquote p { + margin: var(--spacing-small) 0 var(--spacing-medium) 0; +} +.paramname { + font-weight: 600; + color: var(--primary-dark-color); +} + +.paramname > code { + border: 0; +} + +table.params .paramname { + font-weight: 600; + font-family: var(--font-family-monospace); + font-size: var(--code-font-size); + padding-right: var(--spacing-small); + line-height: var(--table-line-height); +} + +h1.glow, h2.glow, h3.glow, h4.glow, h5.glow, h6.glow { + text-shadow: 0 0 15px var(--primary-light-color); +} + +.alphachar a { + color: var(--page-foreground-color); +} + +.dotgraph { + max-width: 100%; + overflow-x: scroll; +} + +.dotgraph .caption { + position: sticky; + left: 0; +} + +/* Wrap Graphviz graphs with the `interactive_dotgraph` class if `INTERACTIVE_SVG = YES` */ +.interactive_dotgraph .dotgraph iframe { + max-width: 100%; +} + +/* + Table of Contents + */ + +div.contents .toc { + max-height: var(--toc-max-height); + min-width: var(--toc-width); + border: 0; + border-left: 1px solid var(--separator-color); + border-radius: 0; + background-color: transparent; + box-shadow: none; + position: sticky; + top: var(--toc-sticky-top); + padding: 0 var(--spacing-large); + margin: var(--spacing-small) 0 var(--spacing-large) var(--spacing-large); +} + +div.toc h3 { + color: var(--toc-foreground); + font-size: var(--navigation-font-size); + margin: var(--spacing-large) 0 var(--spacing-medium) 0; +} + +div.toc li { + padding: 0; + background: none; + line-height: var(--toc-font-size); + margin: var(--toc-font-size) 0 0 0; +} + +div.toc li::before { + display: none; +} + +div.toc ul { + margin-top: 0 +} + +div.toc li a { + font-size: var(--toc-font-size); + color: var(--page-foreground-color) !important; + text-decoration: none; +} + +div.toc li a:hover, div.toc li a.active { + color: var(--primary-color) !important; +} + +div.toc li a.aboveActive { + color: var(--page-secondary-foreground-color) !important; +} + + +@media screen and (max-width: 999px) { + div.contents .toc { + max-height: 45vh; + float: none; + width: auto; + margin: 0 0 var(--spacing-medium) 0; + position: relative; + top: 0; + position: relative; + border: 1px solid var(--separator-color); + border-radius: var(--border-radius-medium); + background-color: var(--toc-background); + box-shadow: var(--box-shadow); + } + + div.contents .toc.interactive { + max-height: calc(var(--navigation-font-size) + 2 * var(--spacing-large)); + overflow: hidden; + } + + div.contents .toc > h3 { + -webkit-tap-highlight-color: transparent; + cursor: pointer; + position: sticky; + top: 0; + background-color: var(--toc-background); + margin: 0; + padding: var(--spacing-large) 0; + display: block; + } + + div.contents .toc.interactive > h3::before { + content: ""; + width: 0; + height: 0; + border-left: 4px solid transparent; + border-right: 4px solid transparent; + border-top: 5px solid var(--primary-color); + display: inline-block; + margin-right: var(--spacing-small); + margin-bottom: calc(var(--navigation-font-size) / 4); + transform: rotate(-90deg); + transition: transform 0.25s ease-out; + } + + div.contents .toc.interactive.open > h3::before { + transform: rotate(0deg); + } + + div.contents .toc.interactive.open { + max-height: 45vh; + overflow: auto; + transition: max-height 0.2s ease-in-out; + } + + div.contents .toc a, div.contents .toc a.active { + color: var(--primary-color) !important; + } + + div.contents .toc a:hover { + text-decoration: underline; + } +} + +/* + Code & Fragments + */ + +code, div.fragment, pre.fragment { + border-radius: var(--border-radius-small); + border: 1px solid var(--separator-color); + overflow: hidden; +} + +code { + display: inline; + background: var(--code-background); + color: var(--code-foreground); + padding: 2px 6px; +} + +div.fragment, pre.fragment { + margin: var(--spacing-medium) 0; + padding: calc(var(--spacing-large) - (var(--spacing-large) / 6)) var(--spacing-large); + background: var(--fragment-background); + color: var(--fragment-foreground); + overflow-x: auto; +} + +@media screen and (max-width: 767px) { + div.fragment, pre.fragment { + border-top-right-radius: 0; + border-bottom-right-radius: 0; + border-right: 0; + } + + .contents > div.fragment, + .textblock > div.fragment, + .textblock > pre.fragment, + .contents > .doxygen-awesome-fragment-wrapper > div.fragment, + .textblock > .doxygen-awesome-fragment-wrapper > div.fragment, + .textblock > .doxygen-awesome-fragment-wrapper > pre.fragment { + margin: var(--spacing-medium) calc(0px - var(--spacing-large)); + border-radius: 0; + border-left: 0; + } + + .textblock li > .fragment, + .textblock li > .doxygen-awesome-fragment-wrapper > .fragment { + margin: var(--spacing-medium) calc(0px - var(--spacing-large)); + } + + .memdoc li > .fragment, + .memdoc li > .doxygen-awesome-fragment-wrapper > .fragment { + margin: var(--spacing-medium) calc(0px - var(--spacing-medium)); + } + + .textblock ul, .memdoc ul { + overflow: initial; + } + + .memdoc > div.fragment, + .memdoc > pre.fragment, + dl dd > div.fragment, + dl dd pre.fragment, + .memdoc > .doxygen-awesome-fragment-wrapper > div.fragment, + .memdoc > .doxygen-awesome-fragment-wrapper > pre.fragment, + dl dd > .doxygen-awesome-fragment-wrapper > div.fragment, + dl dd .doxygen-awesome-fragment-wrapper > pre.fragment { + margin: var(--spacing-medium) calc(0px - var(--spacing-medium)); + border-radius: 0; + border-left: 0; + } +} + +code, code a, pre.fragment, div.fragment, div.fragment .line, div.fragment span, div.fragment .line a, div.fragment .line span { + font-family: var(--font-family-monospace); + font-size: var(--code-font-size) !important; +} + +div.line:after { + margin-right: var(--spacing-medium); +} + +div.fragment .line, pre.fragment { + white-space: pre; + word-wrap: initial; + line-height: var(--fragment-lineheight); +} + +div.fragment span.keyword { + color: var(--fragment-keyword); +} + +div.fragment span.keywordtype { + color: var(--fragment-keywordtype); +} + +div.fragment span.keywordflow { + color: var(--fragment-keywordflow); +} + +div.fragment span.stringliteral { + color: var(--fragment-token) +} + +div.fragment span.comment { + color: var(--fragment-comment); +} + +div.fragment a.code { + color: var(--fragment-link) !important; +} + +div.fragment span.preprocessor { + color: var(--fragment-preprocessor); +} + +div.fragment span.lineno { + display: inline-block; + width: 27px; + border-right: none; + background: var(--fragment-linenumber-background); + color: var(--fragment-linenumber-color); +} + +div.fragment span.lineno a { + background: none; + color: var(--fragment-link) !important; +} + +div.fragment .line:first-child .lineno { + box-shadow: -999999px 0px 0 999999px var(--fragment-linenumber-background), -999998px 0px 0 999999px var(--fragment-linenumber-border); +} + +div.line { + border-radius: var(--border-radius-small); +} + +div.line.glow { + background-color: var(--primary-light-color); + box-shadow: none; +} + +/* + dl warning, attention, note, deprecated, bug, ... + */ + +dl.bug dt a, dl.deprecated dt a, dl.todo dt a { + font-weight: bold !important; +} + +dl.warning, dl.attention, dl.note, dl.deprecated, dl.bug, dl.invariant, dl.pre, dl.post, dl.todo, dl.remark { + padding: var(--spacing-medium); + margin: var(--spacing-medium) 0; + color: var(--page-background-color); + overflow: hidden; + margin-left: 0; + border-radius: var(--border-radius-small); +} + +dl.section dd { + margin-bottom: 2px; +} + +dl.warning, dl.attention { + background: var(--warning-color); + border-left: 8px solid var(--warning-color-dark); + color: var(--warning-color-darker); +} + +dl.warning dt, dl.attention dt { + color: var(--warning-color-dark); +} + +dl.note, dl.remark { + background: var(--note-color); + border-left: 8px solid var(--note-color-dark); + color: var(--note-color-darker); +} + +dl.note dt, dl.remark dt { + color: var(--note-color-dark); +} + +dl.todo { + background: var(--todo-color); + border-left: 8px solid var(--todo-color-dark); + color: var(--todo-color-darker); +} + +dl.todo dt { + color: var(--todo-color-dark); +} + +dl.bug dt a { + color: var(--todo-color-dark) !important; +} + +dl.bug { + background: var(--bug-color); + border-left: 8px solid var(--bug-color-dark); + color: var(--bug-color-darker); +} + +dl.bug dt a { + color: var(--bug-color-dark) !important; +} + +dl.deprecated { + background: var(--deprecated-color); + border-left: 8px solid var(--deprecated-color-dark); + color: var(--deprecated-color-darker); +} + +dl.deprecated dt a { + color: var(--deprecated-color-dark) !important; +} + +dl.section dd, dl.bug dd, dl.deprecated dd, dl.todo dd { + margin-inline-start: 0px; +} + +dl.invariant, dl.pre, dl.post { + background: var(--invariant-color); + border-left: 8px solid var(--invariant-color-dark); + color: var(--invariant-color-darker); +} + +dl.invariant dt, dl.pre dt, dl.post dt { + color: var(--invariant-color-dark); +} + +/* + memitem + */ + +div.memdoc, div.memproto, h2.memtitle { + box-shadow: none; + background-image: none; + border: none; +} + +div.memdoc { + padding: 0 var(--spacing-medium); + background: var(--page-background-color); +} + +h2.memtitle, div.memitem { + border: 1px solid var(--separator-color); + box-shadow: var(--box-shadow); +} + +h2.memtitle { + box-shadow: 0px var(--spacing-medium) 0 -1px var(--fragment-background), var(--box-shadow); +} + +div.memitem { + transition: none; +} + +div.memproto, h2.memtitle { + background: var(--fragment-background); +} + +h2.memtitle { + font-weight: 500; + font-size: var(--memtitle-font-size); + font-family: var(--font-family-monospace); + border-bottom: none; + border-top-left-radius: var(--border-radius-medium); + border-top-right-radius: var(--border-radius-medium); + word-break: break-all; + position: relative; +} + +h2.memtitle:after { + content: ""; + display: block; + background: var(--fragment-background); + height: var(--spacing-medium); + bottom: calc(0px - var(--spacing-medium)); + left: 0; + right: -14px; + position: absolute; + border-top-right-radius: var(--border-radius-medium); +} + +h2.memtitle > span.permalink { + font-size: inherit; +} + +h2.memtitle > span.permalink > a { + text-decoration: none; + padding-left: 3px; + margin-right: -4px; + user-select: none; + display: inline-block; + margin-top: -6px; +} + +h2.memtitle > span.permalink > a:hover { + color: var(--primary-dark-color) !important; +} + +a:target + h2.memtitle, a:target + h2.memtitle + div.memitem { + border-color: var(--primary-light-color); +} + +div.memitem { + border-top-right-radius: var(--border-radius-medium); + border-bottom-right-radius: var(--border-radius-medium); + border-bottom-left-radius: var(--border-radius-medium); + overflow: hidden; + display: block !important; +} + +div.memdoc { + border-radius: 0; +} + +div.memproto { + border-radius: 0 var(--border-radius-small) 0 0; + overflow: auto; + border-bottom: 1px solid var(--separator-color); + padding: var(--spacing-medium); + margin-bottom: -1px; +} + +div.memtitle { + border-top-right-radius: var(--border-radius-medium); + border-top-left-radius: var(--border-radius-medium); +} + +div.memproto table.memname { + font-family: var(--font-family-monospace); + color: var(--page-foreground-color); + font-size: var(--memname-font-size); + text-shadow: none; +} + +div.memproto div.memtemplate { + font-family: var(--font-family-monospace); + color: var(--primary-dark-color); + font-size: var(--memname-font-size); + margin-left: 2px; + text-shadow: none; +} + +table.mlabels, table.mlabels > tbody { + display: block; +} + +td.mlabels-left { + width: auto; +} + +td.mlabels-right { + margin-top: 3px; + position: sticky; + left: 0; +} + +table.mlabels > tbody > tr:first-child { + display: flex; + justify-content: space-between; + flex-wrap: wrap; +} + +.memname, .memitem span.mlabels { + margin: 0 +} + +/* + reflist + */ + +dl.reflist { + box-shadow: var(--box-shadow); + border-radius: var(--border-radius-medium); + border: 1px solid var(--separator-color); + overflow: hidden; + padding: 0; +} + + +dl.reflist dt, dl.reflist dd { + box-shadow: none; + text-shadow: none; + background-image: none; + border: none; + padding: 12px; +} + + +dl.reflist dt { + font-weight: 500; + border-radius: 0; + background: var(--code-background); + border-bottom: 1px solid var(--separator-color); + color: var(--page-foreground-color) +} + + +dl.reflist dd { + background: none; +} + +/* + Table + */ + +.contents table:not(.memberdecls):not(.mlabels):not(.fieldtable):not(.memname), +.contents table:not(.memberdecls):not(.mlabels):not(.fieldtable):not(.memname) tbody { + display: inline-block; + max-width: 100%; +} + +.contents > table:not(.memberdecls):not(.mlabels):not(.fieldtable):not(.memname):not(.classindex) { + margin-left: calc(0px - var(--spacing-large)); + margin-right: calc(0px - var(--spacing-large)); + max-width: calc(100% + 2 * var(--spacing-large)); +} + +table.fieldtable, +table.markdownTable tbody, +table.doxtable tbody { + border: none; + margin: var(--spacing-medium) 0; + box-shadow: 0 0 0 1px var(--separator-color); + border-radius: var(--border-radius-small); +} + +table.markdownTable, table.doxtable, table.fieldtable { + padding: 1px; +} + +table.doxtable caption { + display: block; +} + +table.fieldtable { + border-collapse: collapse; + width: 100%; +} + +th.markdownTableHeadLeft, +th.markdownTableHeadRight, +th.markdownTableHeadCenter, +th.markdownTableHeadNone, +table.doxtable th { + background: var(--tablehead-background); + color: var(--tablehead-foreground); + font-weight: 600; + font-size: var(--page-font-size); +} + +th.markdownTableHeadLeft:first-child, +th.markdownTableHeadRight:first-child, +th.markdownTableHeadCenter:first-child, +th.markdownTableHeadNone:first-child, +table.doxtable tr th:first-child { + border-top-left-radius: var(--border-radius-small); +} + +th.markdownTableHeadLeft:last-child, +th.markdownTableHeadRight:last-child, +th.markdownTableHeadCenter:last-child, +th.markdownTableHeadNone:last-child, +table.doxtable tr th:last-child { + border-top-right-radius: var(--border-radius-small); +} + +table.markdownTable td, +table.markdownTable th, +table.fieldtable td, +table.fieldtable th, +table.doxtable td, +table.doxtable th { + border: 1px solid var(--separator-color); + padding: var(--spacing-small) var(--spacing-medium); +} + +table.markdownTable td:last-child, +table.markdownTable th:last-child, +table.fieldtable td:last-child, +table.fieldtable th:last-child, +table.doxtable td:last-child, +table.doxtable th:last-child { + border-right: none; +} + +table.markdownTable td:first-child, +table.markdownTable th:first-child, +table.fieldtable td:first-child, +table.fieldtable th:first-child, +table.doxtable td:first-child, +table.doxtable th:first-child { + border-left: none; +} + +table.markdownTable tr:first-child td, +table.markdownTable tr:first-child th, +table.fieldtable tr:first-child td, +table.fieldtable tr:first-child th, +table.doxtable tr:first-child td, +table.doxtable tr:first-child th { + border-top: none; +} + +table.markdownTable tr:last-child td, +table.markdownTable tr:last-child th, +table.fieldtable tr:last-child td, +table.fieldtable tr:last-child th, +table.doxtable tr:last-child td, +table.doxtable tr:last-child th { + border-bottom: none; +} + +table.markdownTable tr, table.doxtable tr { + border-bottom: 1px solid var(--separator-color); +} + +table.markdownTable tr:last-child, table.doxtable tr:last-child { + border-bottom: none; +} + +.full_width_table table:not(.memberdecls):not(.mlabels):not(.fieldtable):not(.memname) { + display: block; +} + +.full_width_table table:not(.memberdecls):not(.mlabels):not(.fieldtable):not(.memname) tbody { + display: table; + width: 100%; +} + +table.fieldtable th { + font-size: var(--page-font-size); + font-weight: 600; + background-image: none; + background-color: var(--tablehead-background); + color: var(--tablehead-foreground); +} + +table.fieldtable td.fieldtype, .fieldtable td.fieldname, .fieldtable td.fielddoc, .fieldtable th { + border-bottom: 1px solid var(--separator-color); + border-right: 1px solid var(--separator-color); +} + +table.fieldtable tr:last-child td:first-child { + border-bottom-left-radius: var(--border-radius-small); +} + +table.fieldtable tr:last-child td:last-child { + border-bottom-right-radius: var(--border-radius-small); +} + +.memberdecls td.glow, .fieldtable tr.glow { + background-color: var(--primary-light-color); + box-shadow: none; +} + +table.memberdecls { + display: block; + -webkit-tap-highlight-color: transparent; +} + +table.memberdecls tr[class^='memitem'] { + font-family: var(--font-family-monospace); + font-size: var(--code-font-size); +} + +table.memberdecls tr[class^='memitem'] .memTemplParams { + font-family: var(--font-family-monospace); + font-size: var(--code-font-size); + color: var(--primary-dark-color); + white-space: normal; +} + +table.memberdecls .memItemLeft, +table.memberdecls .memItemRight, +table.memberdecls .memTemplItemLeft, +table.memberdecls .memTemplItemRight, +table.memberdecls .memTemplParams { + transition: none; + padding-top: var(--spacing-small); + padding-bottom: var(--spacing-small); + border-top: 1px solid var(--separator-color); + border-bottom: 1px solid var(--separator-color); + background-color: var(--fragment-background); +} + +table.memberdecls .memTemplItemLeft, +table.memberdecls .memTemplItemRight { + padding-top: 2px; +} + +table.memberdecls .memTemplParams { + border-bottom: 0; + border-left: 1px solid var(--separator-color); + border-right: 1px solid var(--separator-color); + border-radius: var(--border-radius-small) var(--border-radius-small) 0 0; + padding-bottom: var(--spacing-small); +} + +table.memberdecls .memTemplItemLeft { + border-radius: 0 0 0 var(--border-radius-small); + border-left: 1px solid var(--separator-color); + border-top: 0; +} + +table.memberdecls .memTemplItemRight { + border-radius: 0 0 var(--border-radius-small) 0; + border-right: 1px solid var(--separator-color); + padding-left: 0; + border-top: 0; +} + +table.memberdecls .memItemLeft { + border-radius: var(--border-radius-small) 0 0 var(--border-radius-small); + border-left: 1px solid var(--separator-color); + padding-left: var(--spacing-medium); + padding-right: 0; +} + +table.memberdecls .memItemRight { + border-radius: 0 var(--border-radius-small) var(--border-radius-small) 0; + border-right: 1px solid var(--separator-color); + padding-right: var(--spacing-medium); + padding-left: 0; + +} + +table.memberdecls .mdescLeft, table.memberdecls .mdescRight { + background: none; + color: var(--page-foreground-color); + padding: var(--spacing-small) 0; +} + +table.memberdecls .memItemLeft, +table.memberdecls .memTemplItemLeft { + padding-right: var(--spacing-medium); +} + +table.memberdecls .memSeparator { + background: var(--page-background-color); + height: var(--spacing-large); + border: 0; + transition: none; +} + +table.memberdecls .groupheader { + margin-bottom: var(--spacing-large); +} + +table.memberdecls .inherit_header td { + padding: 0 0 var(--spacing-medium) 0; + text-indent: -12px; + color: var(--page-secondary-foreground-color); +} + +table.memberdecls img[src="closed.png"], +table.memberdecls img[src="open.png"], +div.dynheader img[src="open.png"], +div.dynheader img[src="closed.png"] { + width: 0; + height: 0; + border-left: 4px solid transparent; + border-right: 4px solid transparent; + border-top: 5px solid var(--primary-color); + margin-top: 8px; + display: block; + float: left; + margin-left: -10px; + transition: transform 0.25s ease-out; +} + +table.memberdecls img { + margin-right: 10px; +} + +table.memberdecls img[src="closed.png"], +div.dynheader img[src="closed.png"] { + transform: rotate(-90deg); + +} + +.compoundTemplParams { + font-family: var(--font-family-monospace); + color: var(--primary-dark-color); + font-size: var(--code-font-size); +} + +@media screen and (max-width: 767px) { + + table.memberdecls .memItemLeft, + table.memberdecls .memItemRight, + table.memberdecls .mdescLeft, + table.memberdecls .mdescRight, + table.memberdecls .memTemplItemLeft, + table.memberdecls .memTemplItemRight, + table.memberdecls .memTemplParams { + display: block; + text-align: left; + padding-left: var(--spacing-large); + margin: 0 calc(0px - var(--spacing-large)) 0 calc(0px - var(--spacing-large)); + border-right: none; + border-left: none; + border-radius: 0; + white-space: normal; + } + + table.memberdecls .memItemLeft, + table.memberdecls .mdescLeft, + table.memberdecls .memTemplItemLeft { + border-bottom: 0; + padding-bottom: 0; + } + + table.memberdecls .memTemplItemLeft { + padding-top: 0; + } + + table.memberdecls .mdescLeft { + margin-bottom: calc(0px - var(--page-font-size)); + } + + table.memberdecls .memItemRight, + table.memberdecls .mdescRight, + table.memberdecls .memTemplItemRight { + border-top: 0; + padding-top: 0; + padding-right: var(--spacing-large); + overflow-x: auto; + } + + table.memberdecls tr[class^='memitem']:not(.inherit) { + display: block; + width: calc(100vw - 2 * var(--spacing-large)); + } + + table.memberdecls .mdescRight { + color: var(--page-foreground-color); + } + + table.memberdecls tr.inherit { + visibility: hidden; + } + + table.memberdecls tr[style="display: table-row;"] { + display: block !important; + visibility: visible; + width: calc(100vw - 2 * var(--spacing-large)); + animation: fade .5s; + } + + @keyframes fade { + 0% { + opacity: 0; + max-height: 0; + } + + 100% { + opacity: 1; + max-height: 200px; + } + } +} + + +/* + Horizontal Rule + */ + +hr { + margin-top: var(--spacing-large); + margin-bottom: var(--spacing-large); + height: 1px; + background-color: var(--separator-color); + border: 0; +} + +.contents hr { + box-shadow: 100px 0 0 var(--separator-color), + -100px 0 0 var(--separator-color), + 500px 0 0 var(--separator-color), + -500px 0 0 var(--separator-color), + 1500px 0 0 var(--separator-color), + -1500px 0 0 var(--separator-color), + 2000px 0 0 var(--separator-color), + -2000px 0 0 var(--separator-color); +} + +.contents img, .contents .center, .contents center, .contents div.image object { + max-width: 100%; + overflow: auto; +} + +@media screen and (max-width: 767px) { + .contents .dyncontent > .center, .contents > center { + margin-left: calc(0px - var(--spacing-large)); + margin-right: calc(0px - var(--spacing-large)); + max-width: calc(100% + 2 * var(--spacing-large)); + } +} + +/* + Directories + */ +div.directory { + border-top: 1px solid var(--separator-color); + border-bottom: 1px solid var(--separator-color); + width: auto; +} + +table.directory { + font-family: var(--font-family); + font-size: var(--page-font-size); + font-weight: normal; + width: 100%; +} + +table.directory td.entry, table.directory td.desc { + padding: calc(var(--spacing-small) / 2) var(--spacing-small); + line-height: var(--table-line-height); +} + +table.directory tr.even td:last-child { + border-radius: 0 var(--border-radius-small) var(--border-radius-small) 0; +} + +table.directory tr.even td:first-child { + border-radius: var(--border-radius-small) 0 0 var(--border-radius-small); +} + +table.directory tr.even:last-child td:last-child { + border-radius: 0 var(--border-radius-small) 0 0; +} + +table.directory tr.even:last-child td:first-child { + border-radius: var(--border-radius-small) 0 0 0; +} + +table.directory td.desc { + min-width: 250px; +} + +table.directory tr.even { + background-color: var(--odd-color); +} + +table.directory tr.odd { + background-color: transparent; +} + +.icona { + width: auto; + height: auto; + margin: 0 var(--spacing-small); +} + +.icon { + background: var(--primary-color); + border-radius: var(--border-radius-small); + font-size: var(--page-font-size); + padding: calc(var(--page-font-size) / 5); + line-height: var(--page-font-size); + transform: scale(0.8); + height: auto; + width: var(--page-font-size); + user-select: none; +} + +.iconfopen, .icondoc, .iconfclosed { + background-position: center; + margin-bottom: 0; + height: var(--table-line-height); +} + +.icondoc { + filter: saturate(0.2); +} + +@media screen and (max-width: 767px) { + div.directory { + margin-left: calc(0px - var(--spacing-large)); + margin-right: calc(0px - var(--spacing-large)); + } +} + +@media (prefers-color-scheme: dark) { + html:not(.light-mode) .iconfopen, html:not(.light-mode) .iconfclosed { + filter: hue-rotate(180deg) invert(); + } +} + +html.dark-mode .iconfopen, html.dark-mode .iconfclosed { + filter: hue-rotate(180deg) invert(); +} + +/* + Class list + */ + +.classindex dl.odd { + background: var(--odd-color); + border-radius: var(--border-radius-small); +} + +.classindex dl.even { + background-color: transparent; +} + +/* + Class Index Doxygen 1.8 +*/ + +table.classindex { + margin-left: 0; + margin-right: 0; + width: 100%; +} + +table.classindex table div.ah { + background-image: none; + background-color: initial; + border-color: var(--separator-color); + color: var(--page-foreground-color); + box-shadow: var(--box-shadow); + border-radius: var(--border-radius-large); + padding: var(--spacing-small); +} + +div.qindex { + background-color: var(--odd-color); + border-radius: var(--border-radius-small); + border: 1px solid var(--separator-color); + padding: var(--spacing-small) 0; +} + +/* + Footer and nav-path + */ + +#nav-path { + width: 100%; +} + +#nav-path ul { + background-image: none; + background: var(--page-background-color); + border: none; + border-top: 1px solid var(--separator-color); + border-bottom: 1px solid var(--separator-color); + border-bottom: 0; + box-shadow: 0 0.75px 0 var(--separator-color); + font-size: var(--navigation-font-size); +} + +img.footer { + width: 60px; +} + +.navpath li.footer { + color: var(--page-secondary-foreground-color); +} + +address.footer { + color: var(--page-secondary-foreground-color); + margin-bottom: var(--spacing-large); +} + +#nav-path li.navelem { + background-image: none; + display: flex; + align-items: center; +} + +.navpath li.navelem a { + text-shadow: none; + display: inline-block; + color: var(--primary-color) !important; +} + +.navpath li.navelem b { + color: var(--primary-dark-color); + font-weight: 500; +} + +li.navelem { + padding: 0; + margin-left: -8px; +} + +li.navelem:first-child { + margin-left: var(--spacing-large); +} + +li.navelem:first-child:before { + display: none; +} + +#nav-path li.navelem:after { + content: ''; + border: 5px solid var(--page-background-color); + border-bottom-color: transparent; + border-right-color: transparent; + border-top-color: transparent; + transform: translateY(-1px) scaleY(4.2); + z-index: 10; + margin-left: 6px; +} + +#nav-path li.navelem:before { + content: ''; + border: 5px solid var(--separator-color); + border-bottom-color: transparent; + border-right-color: transparent; + border-top-color: transparent; + transform: translateY(-1px) scaleY(3.2); + margin-right: var(--spacing-small); +} + +.navpath li.navelem a:hover { + color: var(--primary-color); +} + +/* + Scrollbars for Webkit +*/ + +#nav-tree::-webkit-scrollbar, +div.fragment::-webkit-scrollbar, +pre.fragment::-webkit-scrollbar, +div.memproto::-webkit-scrollbar, +.contents center::-webkit-scrollbar, +.contents .center::-webkit-scrollbar, +.contents table:not(.memberdecls):not(.mlabels):not(.fieldtable):not(.memname) tbody::-webkit-scrollbar, +div.contents .toc::-webkit-scrollbar, +.contents .dotgraph::-webkit-scrollbar, +.contents .tabs-overview-container::-webkit-scrollbar { + background: transparent; + width: calc(var(--webkit-scrollbar-size) + var(--webkit-scrollbar-padding) + var(--webkit-scrollbar-padding)); + height: calc(var(--webkit-scrollbar-size) + var(--webkit-scrollbar-padding) + var(--webkit-scrollbar-padding)); +} + +#nav-tree::-webkit-scrollbar-thumb, +div.fragment::-webkit-scrollbar-thumb, +pre.fragment::-webkit-scrollbar-thumb, +div.memproto::-webkit-scrollbar-thumb, +.contents center::-webkit-scrollbar-thumb, +.contents .center::-webkit-scrollbar-thumb, +.contents table:not(.memberdecls):not(.mlabels):not(.fieldtable):not(.memname) tbody::-webkit-scrollbar-thumb, +div.contents .toc::-webkit-scrollbar-thumb, +.contents .dotgraph::-webkit-scrollbar-thumb, +.contents .tabs-overview-container::-webkit-scrollbar-thumb { + background-color: transparent; + border: var(--webkit-scrollbar-padding) solid transparent; + border-radius: calc(var(--webkit-scrollbar-padding) + var(--webkit-scrollbar-padding)); + background-clip: padding-box; +} + +#nav-tree:hover::-webkit-scrollbar-thumb, +div.fragment:hover::-webkit-scrollbar-thumb, +pre.fragment:hover::-webkit-scrollbar-thumb, +div.memproto:hover::-webkit-scrollbar-thumb, +.contents center:hover::-webkit-scrollbar-thumb, +.contents .center:hover::-webkit-scrollbar-thumb, +.contents table:not(.memberdecls):not(.mlabels):not(.fieldtable):not(.memname) tbody:hover::-webkit-scrollbar-thumb, +div.contents .toc:hover::-webkit-scrollbar-thumb, +.contents .dotgraph:hover::-webkit-scrollbar-thumb, +.contents .tabs-overview-container:hover::-webkit-scrollbar-thumb { + background-color: var(--webkit-scrollbar-color); +} + +#nav-tree::-webkit-scrollbar-track, +div.fragment::-webkit-scrollbar-track, +pre.fragment::-webkit-scrollbar-track, +div.memproto::-webkit-scrollbar-track, +.contents center::-webkit-scrollbar-track, +.contents .center::-webkit-scrollbar-track, +.contents table:not(.memberdecls):not(.mlabels):not(.fieldtable):not(.memname) tbody::-webkit-scrollbar-track, +div.contents .toc::-webkit-scrollbar-track, +.contents .dotgraph::-webkit-scrollbar-track, +.contents .tabs-overview-container::-webkit-scrollbar-track { + background: transparent; +} + +#nav-tree::-webkit-scrollbar-corner { + background-color: var(--side-nav-background); +} + +#nav-tree, +div.fragment, +pre.fragment, +div.memproto, +.contents center, +.contents .center, +.contents table:not(.memberdecls):not(.mlabels):not(.fieldtable):not(.memname) tbody, +div.contents .toc { + overflow-x: auto; + overflow-x: overlay; +} + +#nav-tree { + overflow-x: auto; + overflow-y: auto; + overflow-y: overlay; +} + +/* + Scrollbars for Firefox +*/ + +#nav-tree, +div.fragment, +pre.fragment, +div.memproto, +.contents center, +.contents .center, +.contents table:not(.memberdecls):not(.mlabels):not(.fieldtable):not(.memname) tbody, +div.contents .toc, +.contents .dotgraph, +.contents .tabs-overview-container { + scrollbar-width: thin; +} + +/* + Optional Dark mode toggle button +*/ + +doxygen-awesome-dark-mode-toggle { + display: inline-block; + margin: 0 0 0 var(--spacing-small); + padding: 0; + width: var(--searchbar-height); + height: var(--searchbar-height); + background: none; + border: none; + border-radius: var(--searchbar-height); + vertical-align: middle; + text-align: center; + line-height: var(--searchbar-height); + font-size: 22px; + display: flex; + align-items: center; + justify-content: center; + user-select: none; + cursor: pointer; +} + +doxygen-awesome-dark-mode-toggle > svg { + transition: transform .1s ease-in-out; +} + +doxygen-awesome-dark-mode-toggle:active > svg { + transform: scale(.5); +} + +doxygen-awesome-dark-mode-toggle:hover { + background-color: rgba(0,0,0,.03); +} + +html.dark-mode doxygen-awesome-dark-mode-toggle:hover { + background-color: rgba(0,0,0,.18); +} + +/* + Optional fragment copy button +*/ +.doxygen-awesome-fragment-wrapper { + position: relative; +} + +doxygen-awesome-fragment-copy-button { + opacity: 0; + background: var(--fragment-background); + width: 28px; + height: 28px; + position: absolute; + right: calc(var(--spacing-large) - (var(--spacing-large) / 2.5)); + top: calc(var(--spacing-large) - (var(--spacing-large) / 2.5)); + border: 1px solid var(--fragment-foreground); + cursor: pointer; + border-radius: var(--border-radius-small); + display: flex; + justify-content: center; + align-items: center; +} + +.doxygen-awesome-fragment-wrapper:hover doxygen-awesome-fragment-copy-button, doxygen-awesome-fragment-copy-button.success { + opacity: .28; +} + +doxygen-awesome-fragment-copy-button:hover, doxygen-awesome-fragment-copy-button.success { + opacity: 1 !important; +} + +doxygen-awesome-fragment-copy-button:active:not([class~=success]) svg { + transform: scale(.91); +} + +doxygen-awesome-fragment-copy-button svg { + fill: var(--fragment-foreground); + width: 18px; + height: 18px; +} + +doxygen-awesome-fragment-copy-button.success svg { + fill: rgb(14, 168, 14); +} + +doxygen-awesome-fragment-copy-button.success { + border-color: rgb(14, 168, 14); +} + +@media screen and (max-width: 767px) { + .textblock > .doxygen-awesome-fragment-wrapper > doxygen-awesome-fragment-copy-button, + .textblock li > .doxygen-awesome-fragment-wrapper > doxygen-awesome-fragment-copy-button, + .memdoc li > .doxygen-awesome-fragment-wrapper > doxygen-awesome-fragment-copy-button, + .memdoc > .doxygen-awesome-fragment-wrapper > doxygen-awesome-fragment-copy-button, + dl dd > .doxygen-awesome-fragment-wrapper > doxygen-awesome-fragment-copy-button { + right: 0; + } +} + +/* + Optional paragraph link button +*/ + +a.anchorlink { + font-size: 90%; + margin-left: var(--spacing-small); + color: var(--page-foreground-color) !important; + text-decoration: none; + opacity: .15; + display: none; + transition: opacity .1s ease-in-out, color .1s ease-in-out; +} + +a.anchorlink svg { + fill: var(--page-foreground-color); +} + +h3 a.anchorlink svg, h4 a.anchorlink svg { + margin-bottom: -3px; + margin-top: -4px; +} + +a.anchorlink:hover { + opacity: .45; +} + +h2:hover a.anchorlink, h1:hover a.anchorlink, h3:hover a.anchorlink, h4:hover a.anchorlink { + display: inline-block; +} + +/* + Optional tab feature +*/ + +.tabbed { + margin: var(--spacing-medium) auto; +} + +.tabbed ul { + padding-inline-start: 0px; + margin: 0; + padding: var(--spacing-small) 0; + border-bottom: 1px solid var(--separator-color); +} + +.tabbed li { + display: none; +} + +.tabbed li.selected { + display: block; +} + +.tabs-overview-container { + overflow-x: auto; + display: block; + overflow-y: visible; +} + +.tabs-overview { + border-bottom: 1px solid var(--separator-color); + display: flex; + flex-direction: row; +} + +.tabs-overview button.tab-button { + color: var(--page-foreground-color); + margin: 0; + border: none; + background: transparent; + padding: var(--spacing-small) 0; + display: inline-block; + font-size: var(--page-font-size); + cursor: pointer; + box-shadow: 0 1px 0 0 var(--separator-color); + position: relative; +} + +.tabs-overview button.tab-button .tab-title { + float: left; + white-space: nowrap; + padding: var(--spacing-small) var(--spacing-large); + border-radius: var(--border-radius-medium); +} + +.tabs-overview button.tab-button:not(:last-child) .tab-title { + box-shadow: 8px 0 0 -7px var(--separator-color); +} + +.tabs-overview button.tab-button:hover .tab-title { + background: var(--separator-color); + box-shadow: none; +} + +.tabs-overview button.tab-button.active { + color: var(--primary-color); +} + +.tabs-overview button.tab-button.active::after { + content: ''; + display: block; + position: absolute; + left: 0px; + bottom: 0; + right: 0px; + height: 3px; + border-radius: var(--border-radius-small) var(--border-radius-small) 0 0; + background-color: var(--primary-color); +} diff --git a/docs/doxygen.css b/docs/doxygen.css new file mode 100644 index 0000000..c7699ac --- /dev/null +++ b/docs/doxygen.css @@ -0,0 +1,1665 @@ +/* The standard CSS for doxygen 1.9.6*/ + +body { + background-color: white; + color: black; +} + +body, table, div, p, dl { + font-weight: 400; + font-size: 14px; + font-family: Roboto,sans-serif; + line-height: 22px; +} + +/* @group Heading Levels */ + +.title { + font-weight: 400; + font-size: 14px; + font-family: Roboto,sans-serif; + line-height: 28px; + font-size: 150%; + font-weight: bold; + margin: 10px 2px; +} + +h1.groupheader { + font-size: 150%; +} + +h2.groupheader { + border-bottom: 1px solid #879ECB; + color: #354C7B; + font-size: 150%; + font-weight: normal; + margin-top: 1.75em; + padding-top: 8px; + padding-bottom: 4px; + width: 100%; +} + +h3.groupheader { + font-size: 100%; +} + +h1, h2, h3, h4, h5, h6 { + -webkit-transition: text-shadow 0.5s linear; + -moz-transition: text-shadow 0.5s linear; + -ms-transition: text-shadow 0.5s linear; + -o-transition: text-shadow 0.5s linear; + transition: text-shadow 0.5s linear; + margin-right: 15px; +} + +h1.glow, h2.glow, h3.glow, h4.glow, h5.glow, h6.glow { + text-shadow: 0 0 15px cyan; +} + +dt { + font-weight: bold; +} + +p.startli, p.startdd { + margin-top: 2px; +} + +th p.starttd, th p.intertd, th p.endtd { + font-size: 100%; + font-weight: 700; +} + +p.starttd { + margin-top: 0px; +} + +p.endli { + margin-bottom: 0px; +} + +p.enddd { + margin-bottom: 4px; +} + +p.endtd { + margin-bottom: 2px; +} + +p.interli { +} + +p.interdd { +} + +p.intertd { +} + +/* @end */ + +caption { + font-weight: bold; +} + +span.legend { + font-size: 70%; + text-align: center; +} + +h3.version { + font-size: 90%; + text-align: center; +} + +div.navtab { + padding-right: 15px; + text-align: right; + line-height: 110%; +} + +div.navtab table { + border-spacing: 0; +} + +td.navtab { + padding-right: 6px; + padding-left: 6px; +} + +td.navtabHL { + background-image: url('tab_a.png'); + background-repeat:repeat-x; + padding-right: 6px; + padding-left: 6px; +} + +td.navtabHL a, td.navtabHL a:visited { + color: white; + text-shadow: 0px 1px 1px rgba(0, 0, 0, 1.0); +} + +a.navtab { + font-weight: bold; +} + +div.qindex{ + text-align: center; + width: 100%; + line-height: 140%; + font-size: 130%; + color: #A0A0A0; +} + +dt.alphachar{ + font-size: 180%; + font-weight: bold; +} + +.alphachar a{ + color: black; +} + +.alphachar a:hover, .alphachar a:visited{ + text-decoration: none; +} + +.classindex dl { + padding: 25px; + column-count:1 +} + +.classindex dd { + display:inline-block; + margin-left: 50px; + width: 90%; + line-height: 1.15em; +} + +.classindex dl.even { + background-color: white; +} + +.classindex dl.odd { + background-color: #F8F9FC; +} + +@media(min-width: 1120px) { + .classindex dl { + column-count:2 + } +} + +@media(min-width: 1320px) { + .classindex dl { + column-count:3 + } +} + + +/* @group Link Styling */ + +a { + color: #3D578C; + font-weight: normal; + text-decoration: none; +} + +.contents a:visited { + color: #4665A2; +} + +a:hover { + text-decoration: underline; +} + +a.el { + font-weight: bold; +} + +a.elRef { +} + +a.code, a.code:visited, a.line, a.line:visited { + color: #4665A2; +} + +a.codeRef, a.codeRef:visited, a.lineRef, a.lineRef:visited { + color: #4665A2; +} + +a.code.hl_class { /* style for links to class names in code snippets */ } +a.code.hl_struct { /* style for links to struct names in code snippets */ } +a.code.hl_union { /* style for links to union names in code snippets */ } +a.code.hl_interface { /* style for links to interface names in code snippets */ } +a.code.hl_protocol { /* style for links to protocol names in code snippets */ } +a.code.hl_category { /* style for links to category names in code snippets */ } +a.code.hl_exception { /* style for links to exception names in code snippets */ } +a.code.hl_service { /* style for links to service names in code snippets */ } +a.code.hl_singleton { /* style for links to singleton names in code snippets */ } +a.code.hl_concept { /* style for links to concept names in code snippets */ } +a.code.hl_namespace { /* style for links to namespace names in code snippets */ } +a.code.hl_package { /* style for links to package names in code snippets */ } +a.code.hl_define { /* style for links to macro names in code snippets */ } +a.code.hl_function { /* style for links to function names in code snippets */ } +a.code.hl_variable { /* style for links to variable names in code snippets */ } +a.code.hl_typedef { /* style for links to typedef names in code snippets */ } +a.code.hl_enumvalue { /* style for links to enum value names in code snippets */ } +a.code.hl_enumeration { /* style for links to enumeration names in code snippets */ } +a.code.hl_signal { /* style for links to Qt signal names in code snippets */ } +a.code.hl_slot { /* style for links to Qt slot names in code snippets */ } +a.code.hl_friend { /* style for links to friend names in code snippets */ } +a.code.hl_dcop { /* style for links to KDE3 DCOP names in code snippets */ } +a.code.hl_property { /* style for links to property names in code snippets */ } +a.code.hl_event { /* style for links to event names in code snippets */ } +a.code.hl_sequence { /* style for links to sequence names in code snippets */ } +a.code.hl_dictionary { /* style for links to dictionary names in code snippets */ } + +/* @end */ + +dl.el { + margin-left: -1cm; +} + +ul { + overflow: visible; +} + +ul.multicol { + -moz-column-gap: 1em; + -webkit-column-gap: 1em; + column-gap: 1em; + -moz-column-count: 3; + -webkit-column-count: 3; + column-count: 3; + list-style-type: none; +} + +#side-nav ul { + overflow: visible; /* reset ul rule for scroll bar in GENERATE_TREEVIEW window */ +} + +#main-nav ul { + overflow: visible; /* reset ul rule for the navigation bar drop down lists */ +} + +.fragment { + text-align: left; + direction: ltr; + overflow-x: auto; /*Fixed: fragment lines overlap floating elements*/ + overflow-y: hidden; +} + +pre.fragment { + border: 1px solid #C4CFE5; + background-color: #FBFCFD; + color: black; + padding: 4px 6px; + margin: 4px 8px 4px 2px; + overflow: auto; + word-wrap: break-word; + font-size: 9pt; + line-height: 125%; + font-family: monospace,fixed; + font-size: 105%; +} + +div.fragment { + padding: 0 0 1px 0; /*Fixed: last line underline overlap border*/ + margin: 4px 8px 4px 2px; + color: black; + background-color: #FBFCFD; + border: 1px solid #C4CFE5; +} + +div.line { + font-family: monospace,fixed; + font-size: 13px; + min-height: 13px; + line-height: 1.0; + text-wrap: unrestricted; + white-space: -moz-pre-wrap; /* Moz */ + white-space: -pre-wrap; /* Opera 4-6 */ + white-space: -o-pre-wrap; /* Opera 7 */ + white-space: pre-wrap; /* CSS3 */ + word-wrap: break-word; /* IE 5.5+ */ + text-indent: -53px; + padding-left: 53px; + padding-bottom: 0px; + margin: 0px; + -webkit-transition-property: background-color, box-shadow; + -webkit-transition-duration: 0.5s; + -moz-transition-property: background-color, box-shadow; + -moz-transition-duration: 0.5s; + -ms-transition-property: background-color, box-shadow; + -ms-transition-duration: 0.5s; + -o-transition-property: background-color, box-shadow; + -o-transition-duration: 0.5s; + transition-property: background-color, box-shadow; + transition-duration: 0.5s; +} + +div.line:after { + content:"\000A"; + white-space: pre; +} + +div.line.glow { + background-color: cyan; + box-shadow: 0 0 10px cyan; +} + + +span.lineno { + padding-right: 4px; + margin-right: 9px; + text-align: right; + border-right: 2px solid #00FF00; + color: black; + background-color: #E8E8E8; + white-space: pre; +} +span.lineno a, span.lineno a:visited { + color: #4665A2; + background-color: #D8D8D8; +} + +span.lineno a:hover { + color: #4665A2; + background-color: #C8C8C8; +} + +.lineno { + -webkit-touch-callout: none; + -webkit-user-select: none; + -khtml-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; +} + +div.classindex ul { + list-style: none; + padding-left: 0; +} + +div.classindex span.ai { + display: inline-block; +} + +div.groupHeader { + margin-left: 16px; + margin-top: 12px; + font-weight: bold; +} + +div.groupText { + margin-left: 16px; + font-style: italic; +} + +body { + color: black; + margin: 0; +} + +div.contents { + margin-top: 10px; + margin-left: 12px; + margin-right: 8px; +} + +p.formulaDsp { + text-align: center; +} + +img.dark-mode-visible { + display: none; +} +img.light-mode-visible { + display: none; +} + +img.formulaDsp { + +} + +img.formulaInl, img.inline { + vertical-align: middle; +} + +div.center { + text-align: center; + margin-top: 0px; + margin-bottom: 0px; + padding: 0px; +} + +div.center img { + border: 0px; +} + +address.footer { + text-align: right; + padding-right: 12px; +} + +img.footer { + border: 0px; + vertical-align: middle; + width: 104px; +} + +.compoundTemplParams { + color: #4665A2; + font-size: 80%; + line-height: 120%; +} + +/* @group Code Colorization */ + +span.keyword { + color: #008000; +} + +span.keywordtype { + color: #604020; +} + +span.keywordflow { + color: #E08000; +} + +span.comment { + color: #800000; +} + +span.preprocessor { + color: #806020; +} + +span.stringliteral { + color: #002080; +} + +span.charliteral { + color: #008080; +} + +span.vhdldigit { + color: #FF00FF; +} + +span.vhdlchar { + color: #000000; +} + +span.vhdlkeyword { + color: #700070; +} + +span.vhdllogic { + color: #FF0000; +} + +blockquote { + background-color: #F7F8FB; + border-left: 2px solid #9CAFD4; + margin: 0 24px 0 4px; + padding: 0 12px 0 16px; +} + +/* @end */ + +td.tiny { + font-size: 75%; +} + +.dirtab { + padding: 4px; + border-collapse: collapse; + border: 1px solid #2D4068; +} + +th.dirtab { + background-color: #374F7F; + color: #FFFFFF; + font-weight: bold; +} + +hr { + height: 0px; + border: none; + border-top: 1px solid #4A6AAA; +} + +hr.footer { + height: 1px; +} + +/* @group Member Descriptions */ + +table.memberdecls { + border-spacing: 0px; + padding: 0px; +} + +.memberdecls td, .fieldtable tr { + -webkit-transition-property: background-color, box-shadow; + -webkit-transition-duration: 0.5s; + -moz-transition-property: background-color, box-shadow; + -moz-transition-duration: 0.5s; + -ms-transition-property: background-color, box-shadow; + -ms-transition-duration: 0.5s; + -o-transition-property: background-color, box-shadow; + -o-transition-duration: 0.5s; + transition-property: background-color, box-shadow; + transition-duration: 0.5s; +} + +.memberdecls td.glow, .fieldtable tr.glow { + background-color: cyan; + box-shadow: 0 0 15px cyan; +} + +.mdescLeft, .mdescRight, +.memItemLeft, .memItemRight, +.memTemplItemLeft, .memTemplItemRight, .memTemplParams { + background-color: #F9FAFC; + border: none; + margin: 4px; + padding: 1px 0 0 8px; +} + +.mdescLeft, .mdescRight { + padding: 0px 8px 4px 8px; + color: #555; +} + +.memSeparator { + border-bottom: 1px solid #DEE4F0; + line-height: 1px; + margin: 0px; + padding: 0px; +} + +.memItemLeft, .memTemplItemLeft { + white-space: nowrap; +} + +.memItemRight, .memTemplItemRight { + width: 100%; +} + +.memTemplParams { + color: #4665A2; + white-space: nowrap; + font-size: 80%; +} + +/* @end */ + +/* @group Member Details */ + +/* Styles for detailed member documentation */ + +.memtitle { + padding: 8px; + border-top: 1px solid #A8B8D9; + border-left: 1px solid #A8B8D9; + border-right: 1px solid #A8B8D9; + border-top-right-radius: 4px; + border-top-left-radius: 4px; + margin-bottom: -1px; + background-image: url('nav_f.png'); + background-repeat: repeat-x; + background-color: #E2E8F2; + line-height: 1.25; + font-weight: 300; + float:left; +} + +.permalink +{ + font-size: 65%; + display: inline-block; + vertical-align: middle; +} + +.memtemplate { + font-size: 80%; + color: #4665A2; + font-weight: normal; + margin-left: 9px; +} + +.mempage { + width: 100%; +} + +.memitem { + padding: 0; + margin-bottom: 10px; + margin-right: 5px; + -webkit-transition: box-shadow 0.5s linear; + -moz-transition: box-shadow 0.5s linear; + -ms-transition: box-shadow 0.5s linear; + -o-transition: box-shadow 0.5s linear; + transition: box-shadow 0.5s linear; + display: table !important; + width: 100%; +} + +.memitem.glow { + box-shadow: 0 0 15px cyan; +} + +.memname { + font-weight: 400; + margin-left: 6px; +} + +.memname td { + vertical-align: bottom; +} + +.memproto, dl.reflist dt { + border-top: 1px solid #A8B8D9; + border-left: 1px solid #A8B8D9; + border-right: 1px solid #A8B8D9; + padding: 6px 0px 6px 0px; + color: #253555; + font-weight: bold; + text-shadow: 0px 1px 1px rgba(255, 255, 255, 0.9); + background-color: #DFE5F1; + box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); + border-top-right-radius: 4px; +} + +.overload { + font-family: monospace,fixed; + font-size: 65%; +} + +.memdoc, dl.reflist dd { + border-bottom: 1px solid #A8B8D9; + border-left: 1px solid #A8B8D9; + border-right: 1px solid #A8B8D9; + padding: 6px 10px 2px 10px; + border-top-width: 0; + background-image:url('nav_g.png'); + background-repeat:repeat-x; + background-color: white; + /* opera specific markup */ + border-bottom-left-radius: 4px; + border-bottom-right-radius: 4px; + box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); + /* firefox specific markup */ + -moz-border-radius-bottomleft: 4px; + -moz-border-radius-bottomright: 4px; + -moz-box-shadow: rgba(0, 0, 0, 0.15) 5px 5px 5px; + /* webkit specific markup */ + -webkit-border-bottom-left-radius: 4px; + -webkit-border-bottom-right-radius: 4px; + -webkit-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); +} + +dl.reflist dt { + padding: 5px; +} + +dl.reflist dd { + margin: 0px 0px 10px 0px; + padding: 5px; +} + +.paramkey { + text-align: right; +} + +.paramtype { + white-space: nowrap; +} + +.paramname { + color: #602020; + white-space: nowrap; +} +.paramname em { + font-style: normal; +} +.paramname code { + line-height: 14px; +} + +.params, .retval, .exception, .tparams { + margin-left: 0px; + padding-left: 0px; +} + +.params .paramname, .retval .paramname, .tparams .paramname, .exception .paramname { + font-weight: bold; + vertical-align: top; +} + +.params .paramtype, .tparams .paramtype { + font-style: italic; + vertical-align: top; +} + +.params .paramdir, .tparams .paramdir { + font-family: monospace,fixed; + vertical-align: top; +} + +table.mlabels { + border-spacing: 0px; +} + +td.mlabels-left { + width: 100%; + padding: 0px; +} + +td.mlabels-right { + vertical-align: bottom; + padding: 0px; + white-space: nowrap; +} + +span.mlabels { + margin-left: 8px; +} + +span.mlabel { + background-color: #728DC1; + border-top:1px solid #5373B4; + border-left:1px solid #5373B4; + border-right:1px solid #C4CFE5; + border-bottom:1px solid #C4CFE5; + text-shadow: none; + color: white; + margin-right: 4px; + padding: 2px 3px; + border-radius: 3px; + font-size: 7pt; + white-space: nowrap; + vertical-align: middle; +} + + + +/* @end */ + +/* these are for tree view inside a (index) page */ + +div.directory { + margin: 10px 0px; + border-top: 1px solid #9CAFD4; + border-bottom: 1px solid #9CAFD4; + width: 100%; +} + +.directory table { + border-collapse:collapse; +} + +.directory td { + margin: 0px; + padding: 0px; + vertical-align: top; +} + +.directory td.entry { + white-space: nowrap; + padding-right: 6px; + padding-top: 3px; +} + +.directory td.entry a { + outline:none; +} + +.directory td.entry a img { + border: none; +} + +.directory td.desc { + width: 100%; + padding-left: 6px; + padding-right: 6px; + padding-top: 3px; + border-left: 1px solid rgba(0,0,0,0.05); +} + +.directory tr.odd { + padding-left: 6px; + background-color: #F8F9FC; +} + +.directory tr.even { + padding-left: 6px; + background-color: white; +} + +.directory img { + vertical-align: -30%; +} + +.directory .levels { + white-space: nowrap; + width: 100%; + text-align: right; + font-size: 9pt; +} + +.directory .levels span { + cursor: pointer; + padding-left: 2px; + padding-right: 2px; + color: #3D578C; +} + +.arrow { + color: #9CAFD4; + -webkit-user-select: none; + -khtml-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; + cursor: pointer; + font-size: 80%; + display: inline-block; + width: 16px; + height: 22px; +} + +.icon { + font-family: Arial,Helvetica; + line-height: normal; + font-weight: bold; + font-size: 12px; + height: 14px; + width: 16px; + display: inline-block; + background-color: #728DC1; + color: white; + text-align: center; + border-radius: 4px; + margin-left: 2px; + margin-right: 2px; +} + +.icona { + width: 24px; + height: 22px; + display: inline-block; +} + +.iconfopen { + width: 24px; + height: 18px; + margin-bottom: 4px; + background-image:url('folderopen.png'); + background-position: 0px -4px; + background-repeat: repeat-y; + vertical-align:top; + display: inline-block; +} + +.iconfclosed { + width: 24px; + height: 18px; + margin-bottom: 4px; + background-image:url('folderclosed.png'); + background-position: 0px -4px; + background-repeat: repeat-y; + vertical-align:top; + display: inline-block; +} + +.icondoc { + width: 24px; + height: 18px; + margin-bottom: 4px; + background-image:url('doc.png'); + background-position: 0px -4px; + background-repeat: repeat-y; + vertical-align:top; + display: inline-block; +} + +/* @end */ + +div.dynheader { + margin-top: 8px; + -webkit-touch-callout: none; + -webkit-user-select: none; + -khtml-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; +} + +address { + font-style: normal; + color: #2A3D61; +} + +table.doxtable caption { + caption-side: top; +} + +table.doxtable { + border-collapse:collapse; + margin-top: 4px; + margin-bottom: 4px; +} + +table.doxtable td, table.doxtable th { + border: 1px solid #2D4068; + padding: 3px 7px 2px; +} + +table.doxtable th { + background-color: #374F7F; + color: #FFFFFF; + font-size: 110%; + padding-bottom: 4px; + padding-top: 5px; +} + +table.fieldtable { + margin-bottom: 10px; + border: 1px solid #A8B8D9; + border-spacing: 0px; + border-radius: 4px; + box-shadow: 2px 2px 2px rgba(0, 0, 0, 0.15); +} + +.fieldtable td, .fieldtable th { + padding: 3px 7px 2px; +} + +.fieldtable td.fieldtype, .fieldtable td.fieldname { + white-space: nowrap; + border-right: 1px solid #A8B8D9; + border-bottom: 1px solid #A8B8D9; + vertical-align: top; +} + +.fieldtable td.fieldname { + padding-top: 3px; +} + +.fieldtable td.fielddoc { + border-bottom: 1px solid #A8B8D9; +} + +.fieldtable td.fielddoc p:first-child { + margin-top: 0px; +} + +.fieldtable td.fielddoc p:last-child { + margin-bottom: 2px; +} + +.fieldtable tr:last-child td { + border-bottom: none; +} + +.fieldtable th { + background-image: url('nav_f.png'); + background-repeat:repeat-x; + background-color: #E2E8F2; + font-size: 90%; + color: #253555; + padding-bottom: 4px; + padding-top: 5px; + text-align:left; + font-weight: 400; + border-top-left-radius: 4px; + border-top-right-radius: 4px; + border-bottom: 1px solid #A8B8D9; +} + + +.tabsearch { + top: 0px; + left: 10px; + height: 36px; + background-image: url('tab_b.png'); + z-index: 101; + overflow: hidden; + font-size: 13px; +} + +.navpath ul +{ + font-size: 11px; + background-image: url('tab_b.png'); + background-repeat:repeat-x; + background-position: 0 -5px; + height:30px; + line-height:30px; + color:#283A5D; + border:solid 1px #C2CDE4; + overflow:hidden; + margin:0px; + padding:0px; +} + +.navpath li +{ + list-style-type:none; + float:left; + padding-left:10px; + padding-right:15px; + background-image:url('bc_s.png'); + background-repeat:no-repeat; + background-position:right; + color: #364D7C; +} + +.navpath li.navelem a +{ + height:32px; + display:block; + text-decoration: none; + outline: none; + color: #283A5D; + font-family: 'Lucida Grande',Geneva,Helvetica,Arial,sans-serif; + text-shadow: 0px 1px 1px rgba(255, 255, 255, 0.9); + text-decoration: none; +} + +.navpath li.navelem a:hover +{ + color: white; + text-shadow: 0px 1px 1px rgba(0, 0, 0, 1.0); +} + +.navpath li.footer +{ + list-style-type:none; + float:right; + padding-left:10px; + padding-right:15px; + background-image:none; + background-repeat:no-repeat; + background-position:right; + color: #2A3D61; + font-size: 8pt; +} + + +div.summary +{ + float: right; + font-size: 8pt; + padding-right: 5px; + width: 50%; + text-align: right; +} + +div.summary a +{ + white-space: nowrap; +} + +table.classindex +{ + margin: 10px; + white-space: nowrap; + margin-left: 3%; + margin-right: 3%; + width: 94%; + border: 0; + border-spacing: 0; + padding: 0; +} + +div.ingroups +{ + font-size: 8pt; + width: 50%; + text-align: left; +} + +div.ingroups a +{ + white-space: nowrap; +} + +div.header +{ + background-image: url('nav_h.png'); + background-repeat:repeat-x; + background-color: #F9FAFC; + margin: 0px; + border-bottom: 1px solid #C4CFE5; +} + +div.headertitle +{ + padding: 5px 5px 5px 10px; +} + +.PageDocRTL-title div.headertitle { + text-align: right; + direction: rtl; +} + +dl { + padding: 0 0 0 0; +} + +/* dl.note, dl.warning, dl.attention, dl.pre, dl.post, dl.invariant, dl.deprecated, dl.todo, dl.test, dl.bug, dl.examples */ +dl.section { + margin-left: 0px; + padding-left: 0px; +} + +dl.note { + margin-left: -7px; + padding-left: 3px; + border-left: 4px solid; + border-color: #D0C000; +} + +dl.warning, dl.attention { + margin-left: -7px; + padding-left: 3px; + border-left: 4px solid; + border-color: #FF0000; +} + +dl.pre, dl.post, dl.invariant { + margin-left: -7px; + padding-left: 3px; + border-left: 4px solid; + border-color: #00D000; +} + +dl.deprecated { + margin-left: -7px; + padding-left: 3px; + border-left: 4px solid; + border-color: #505050; +} + +dl.todo { + margin-left: -7px; + padding-left: 3px; + border-left: 4px solid; + border-color: #00C0E0; +} + +dl.test { + margin-left: -7px; + padding-left: 3px; + border-left: 4px solid; + border-color: #3030E0; +} + +dl.bug { + margin-left: -7px; + padding-left: 3px; + border-left: 4px solid; + border-color: #C08050; +} + +dl.section dd { + margin-bottom: 6px; +} + + +#projectrow +{ + height: 56px; +} + +#projectlogo +{ + text-align: center; + vertical-align: bottom; + border-collapse: separate; +} + +#projectlogo img +{ + border: 0px none; +} + +#projectalign +{ + vertical-align: middle; + padding-left: 0.5em; +} + +#projectname +{ + font-size: 200%; + font-family: Tahoma,Arial,sans-serif; + margin: 0px; + padding: 2px 0px; +} + +#projectbrief +{ + font-size: 90%; + font-family: Tahoma,Arial,sans-serif; + margin: 0px; + padding: 0px; +} + +#projectnumber +{ + font-size: 50%; + font-family: 50% Tahoma,Arial,sans-serif; + margin: 0px; + padding: 0px; +} + +#titlearea +{ + padding: 0px; + margin: 0px; + width: 100%; + border-bottom: 1px solid #5373B4; + background-color: white; +} + +.image +{ + text-align: center; +} + +.dotgraph +{ + text-align: center; +} + +.mscgraph +{ + text-align: center; +} + +.plantumlgraph +{ + text-align: center; +} + +.diagraph +{ + text-align: center; +} + +.caption +{ + font-weight: bold; +} + +dl.citelist { + margin-bottom:50px; +} + +dl.citelist dt { + color:#334975; + float:left; + font-weight:bold; + margin-right:10px; + padding:5px; + text-align:right; + width:52px; +} + +dl.citelist dd { + margin:2px 0 2px 72px; + padding:5px 0; +} + +div.toc { + padding: 14px 25px; + background-color: #F4F6FA; + border: 1px solid #D8DFEE; + border-radius: 7px 7px 7px 7px; + float: right; + height: auto; + margin: 0 8px 10px 10px; + width: 200px; +} + +div.toc li { + background: url("bdwn.png") no-repeat scroll 0 5px transparent; + font: 10px/1.2 Verdana,'DejaVu Sans',Geneva,sans-serif; + margin-top: 5px; + padding-left: 10px; + padding-top: 2px; +} + +div.toc h3 { + font: bold 12px/1.2 Verdana,'DejaVu Sans',Geneva,sans-serif; + color: #4665A2; + border-bottom: 0 none; + margin: 0; +} + +div.toc ul { + list-style: none outside none; + border: medium none; + padding: 0px; +} + +div.toc li.level1 { + margin-left: 0px; +} + +div.toc li.level2 { + margin-left: 15px; +} + +div.toc li.level3 { + margin-left: 30px; +} + +div.toc li.level4 { + margin-left: 45px; +} + +span.emoji { + /* font family used at the site: https://unicode.org/emoji/charts/full-emoji-list.html + * font-family: "Noto Color Emoji", "Apple Color Emoji", "Segoe UI Emoji", Times, Symbola, Aegyptus, Code2000, Code2001, Code2002, Musica, serif, LastResort; + */ +} + +span.obfuscator { + display: none; +} + +.inherit_header { + font-weight: bold; + color: gray; + cursor: pointer; + -webkit-touch-callout: none; + -webkit-user-select: none; + -khtml-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; +} + +.inherit_header td { + padding: 6px 0px 2px 5px; +} + +.inherit { + display: none; +} + +tr.heading h2 { + margin-top: 12px; + margin-bottom: 4px; +} + +/* tooltip related style info */ + +.ttc { + position: absolute; + display: none; +} + +#powerTip { + cursor: default; + /*white-space: nowrap;*/ + color: black; + background-color: white; + border: 1px solid gray; + border-radius: 4px 4px 4px 4px; + box-shadow: 1px 1px 7px gray; + display: none; + font-size: smaller; + max-width: 80%; + opacity: 0.9; + padding: 1ex 1em 1em; + position: absolute; + z-index: 2147483647; +} + +#powerTip div.ttdoc { + color: grey; + font-style: italic; +} + +#powerTip div.ttname a { + font-weight: bold; +} + +#powerTip a { + color: #4665A2; +} + +#powerTip div.ttname { + font-weight: bold; +} + +#powerTip div.ttdeci { + color: #006318; +} + +#powerTip div { + margin: 0px; + padding: 0px; + font-size: 12px; + font-family: Roboto,sans-serif; + line-height: 16px; +} + +#powerTip:before, #powerTip:after { + content: ""; + position: absolute; + margin: 0px; +} + +#powerTip.n:after, #powerTip.n:before, +#powerTip.s:after, #powerTip.s:before, +#powerTip.w:after, #powerTip.w:before, +#powerTip.e:after, #powerTip.e:before, +#powerTip.ne:after, #powerTip.ne:before, +#powerTip.se:after, #powerTip.se:before, +#powerTip.nw:after, #powerTip.nw:before, +#powerTip.sw:after, #powerTip.sw:before { + border: solid transparent; + content: " "; + height: 0; + width: 0; + position: absolute; +} + +#powerTip.n:after, #powerTip.s:after, +#powerTip.w:after, #powerTip.e:after, +#powerTip.nw:after, #powerTip.ne:after, +#powerTip.sw:after, #powerTip.se:after { + border-color: rgba(255, 255, 255, 0); +} + +#powerTip.n:before, #powerTip.s:before, +#powerTip.w:before, #powerTip.e:before, +#powerTip.nw:before, #powerTip.ne:before, +#powerTip.sw:before, #powerTip.se:before { + border-color: rgba(128, 128, 128, 0); +} + +#powerTip.n:after, #powerTip.n:before, +#powerTip.ne:after, #powerTip.ne:before, +#powerTip.nw:after, #powerTip.nw:before { + top: 100%; +} + +#powerTip.n:after, #powerTip.ne:after, #powerTip.nw:after { + border-top-color: white; + border-width: 10px; + margin: 0px -10px; +} +#powerTip.n:before, #powerTip.ne:before, #powerTip.nw:before { + border-top-color: gray; + border-width: 11px; + margin: 0px -11px; +} +#powerTip.n:after, #powerTip.n:before { + left: 50%; +} + +#powerTip.nw:after, #powerTip.nw:before { + right: 14px; +} + +#powerTip.ne:after, #powerTip.ne:before { + left: 14px; +} + +#powerTip.s:after, #powerTip.s:before, +#powerTip.se:after, #powerTip.se:before, +#powerTip.sw:after, #powerTip.sw:before { + bottom: 100%; +} + +#powerTip.s:after, #powerTip.se:after, #powerTip.sw:after { + border-bottom-color: white; + border-width: 10px; + margin: 0px -10px; +} + +#powerTip.s:before, #powerTip.se:before, #powerTip.sw:before { + border-bottom-color: gray; + border-width: 11px; + margin: 0px -11px; +} + +#powerTip.s:after, #powerTip.s:before { + left: 50%; +} + +#powerTip.sw:after, #powerTip.sw:before { + right: 14px; +} + +#powerTip.se:after, #powerTip.se:before { + left: 14px; +} + +#powerTip.e:after, #powerTip.e:before { + left: 100%; +} +#powerTip.e:after { + border-left-color: gray; + border-width: 10px; + top: 50%; + margin-top: -10px; +} +#powerTip.e:before { + border-left-color: gray; + border-width: 11px; + top: 50%; + margin-top: -11px; +} + +#powerTip.w:after, #powerTip.w:before { + right: 100%; +} +#powerTip.w:after { + border-right-color: gray; + border-width: 10px; + top: 50%; + margin-top: -10px; +} +#powerTip.w:before { + border-right-color: gray; + border-width: 11px; + top: 50%; + margin-top: -11px; +} + +@media print +{ + #top { display: none; } + #side-nav { display: none; } + #nav-path { display: none; } + body { overflow:visible; } + h1, h2, h3, h4, h5, h6 { page-break-after: avoid; } + .summary { display: none; } + .memitem { page-break-inside: avoid; } + #doc-content + { + margin-left:0 !important; + height:auto !important; + width:auto !important; + overflow:inherit; + display:inline; + } +} + +/* @group Markdown */ + +table.markdownTable { + border-collapse:collapse; + margin-top: 4px; + margin-bottom: 4px; +} + +table.markdownTable td, table.markdownTable th { + border: 1px solid #2D4068; + padding: 3px 7px 2px; +} + +table.markdownTable tr { +} + +th.markdownTableHeadLeft, th.markdownTableHeadRight, th.markdownTableHeadCenter, th.markdownTableHeadNone { + background-color: #374F7F; + color: #FFFFFF; + font-size: 110%; + padding-bottom: 4px; + padding-top: 5px; +} + +th.markdownTableHeadLeft, td.markdownTableBodyLeft { + text-align: left +} + +th.markdownTableHeadRight, td.markdownTableBodyRight { + text-align: right +} + +th.markdownTableHeadCenter, td.markdownTableBodyCenter { + text-align: center +} + +tt, code, kbd, samp +{ + display: inline-block; +} +/* @end */ + +u { + text-decoration: underline; +} + +details>summary { + list-style-type: none; +} + +details > summary::-webkit-details-marker { + display: none; +} + +details>summary::before { + content: "\25ba"; + padding-right:4px; + font-size: 80%; +} + +details[open]>summary::before { + content: "\25bc"; + padding-right:4px; + font-size: 80%; +} + diff --git a/docs/doxygen.svg b/docs/doxygen.svg new file mode 100644 index 0000000..d42dad5 --- /dev/null +++ b/docs/doxygen.svg @@ -0,0 +1,26 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/docs/dynsections.js b/docs/dynsections.js new file mode 100644 index 0000000..1f4cd14 --- /dev/null +++ b/docs/dynsections.js @@ -0,0 +1,130 @@ +/* + @licstart The following is the entire license notice for the JavaScript code in this file. + + The MIT License (MIT) + + Copyright (C) 1997-2020 by Dimitri van Heesch + + Permission is hereby granted, free of charge, to any person obtaining a copy of this software + and associated documentation files (the "Software"), to deal in the Software without restriction, + including without limitation the rights to use, copy, modify, merge, publish, distribute, + sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is + furnished to do so, subject to the following conditions: + + The above copyright notice and this permission notice shall be included in all copies or + substantial portions of the Software. + + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING + BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND + NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, + DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + + @licend The above is the entire license notice for the JavaScript code in this file + */ +function toggleVisibility(linkObj) +{ + var base = $(linkObj).attr('id'); + var summary = $('#'+base+'-summary'); + var content = $('#'+base+'-content'); + var trigger = $('#'+base+'-trigger'); + var src=$(trigger).attr('src'); + if (content.is(':visible')===true) { + content.hide(); + summary.show(); + $(linkObj).addClass('closed').removeClass('opened'); + $(trigger).attr('src',src.substring(0,src.length-8)+'closed.png'); + } else { + content.show(); + summary.hide(); + $(linkObj).removeClass('closed').addClass('opened'); + $(trigger).attr('src',src.substring(0,src.length-10)+'open.png'); + } + return false; +} + +function updateStripes() +{ + $('table.directory tr'). + removeClass('even').filter(':visible:even').addClass('even'); + $('table.directory tr'). + removeClass('odd').filter(':visible:odd').addClass('odd'); +} + +function toggleLevel(level) +{ + $('table.directory tr').each(function() { + var l = this.id.split('_').length-1; + var i = $('#img'+this.id.substring(3)); + var a = $('#arr'+this.id.substring(3)); + if (l + + + + + + +2 Dimensional Ising Model: File List + + + + + + + + + + + + + + + + +
+
+ + + + + + +
+
2 Dimensional Ising Model +
+
Simulate the change in energy and magnetization in a ferro magnet
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+
+
+
+
+
Loading...
+
Searching...
+
No Matches
+
+
+
+
+ +
+
File List
+
+
+
Here is a list of all documented files with brief descriptions:
+
[detail level 123]
+ + + + + + + + + + + + + + + + + + + + + +
  include
 constants.hppLibrary of constants
 data_type.hppHeader for the data_t type
 IsingModel.hppThe definition of the Ising model
 monte_carlo.hppFunctions for monte carlo simulations
 testlib.hppA small test library
 typedefs.hppUseful typedefs for cleaner code
 utils.hppFunction prototypes and macros that are useful
  src
  scripts
 burn_in_time.py
 pd_estimate.py
 phase_transition.py
 data_type.cppImplementation for the data_t type
 IsingModel.cppThe implementation of the Ising model
 main.cppThe main program
 monte_carlo.cppImplementation of the monte carlo functions
 phase_transition_mpi.cppSweep over different temperatures and generate data
 test_suite.cppSweep over different temperatures and generate data
 testlib.cppImplementation of the testing library
 utils.cppImplementation of the utils
+
+
+
+ + + + diff --git a/docs/files_dup.js b/docs/files_dup.js new file mode 100644 index 0000000..89e9042 --- /dev/null +++ b/docs/files_dup.js @@ -0,0 +1,5 @@ +var files_dup = +[ + [ "include", "dir_d44c64559bbebec7f509842c48db8b23.html", "dir_d44c64559bbebec7f509842c48db8b23" ], + [ "src", "dir_68267d1309a1af8e8297ef4c3efbcdba.html", "dir_68267d1309a1af8e8297ef4c3efbcdba" ] +]; \ No newline at end of file diff --git a/docs/folderclosed.png b/docs/folderclosed.png new file mode 100644 index 0000000000000000000000000000000000000000..bb8ab35edce8e97554e360005ee9fc5bffb36e66 GIT binary patch literal 616 zcmV-u0+;=XP)a9#ETzayK)T~Jw&MMH>OIr#&;dC}is*2Mqdf&akCc=O@`qC+4i z5Iu3w#1M@KqXCz8TIZd1wli&kkl2HVcAiZ8PUn5z_kG@-y;?yK06=cA0U%H0PH+kU zl6dp}OR(|r8-RG+YLu`zbI}5TlOU6ToR41{9=uz^?dGTNL;wIMf|V3`d1Wj3y!#6` zBLZ?xpKR~^2x}?~zA(_NUu3IaDB$tKma*XUdOZN~c=dLt_h_k!dbxm_*ibDM zlFX`g{k$X}yIe%$N)cn1LNu=q9_CS)*>A zsX_mM4L@`(cSNQKMFc$RtYbx{79#j-J7hk*>*+ZZhM4Hw?I?rsXCi#mRWJ=-0LGV5a-WR0Qgt<|Nqf)C-@80`5gIz45^_20000IqP)X=#(TiCT&PiIIVc55T}TU}EUh*{q$|`3@{d>{Tc9Bo>e= zfmF3!f>fbI9#GoEHh0f`i5)wkLpva0ztf%HpZneK?w-7AK@b4Itw{y|Zd3k!fH?q2 zlhckHd_V2M_X7+)U&_Xcfvtw60l;--DgZmLSw-Y?S>)zIqMyJ1#FwLU*%bl38ok+! zh78H87n`ZTS;uhzAR$M`zZ`bVhq=+%u9^$5jDplgxd44}9;IRqUH1YHH|@6oFe%z( zo4)_>E$F&^P-f(#)>(TrnbE>Pefs9~@iN=|)Rz|V`sGfHNrJ)0gJb8xx+SBmRf@1l zvuzt=vGfI)<-F9!o&3l?>9~0QbUDT(wFdnQPv%xdD)m*g%!20>Bc9iYmGAp<9YAa( z0QgYgTWqf1qN++Gqp z8@AYPTB3E|6s=WLG?xw0tm|U!o=&zd+H0oRYE;Dbx+Na9s^STqX|Gnq%H8s(nGDGJ j8vwW|`Ts`)fSK|Kx=IK@RG@g200000NkvXXu0mjfauFEA literal 0 HcmV?d00001 diff --git a/docs/functions.html b/docs/functions.html new file mode 100644 index 0000000..ac97e55 --- /dev/null +++ b/docs/functions.html @@ -0,0 +1,130 @@ + + + + + + + +2 Dimensional Ising Model: Class Members + + + + + + + + + + + + + + + + +
+
+ + + + + + +
+
2 Dimensional Ising Model +
+
Simulate the change in energy and magnetization in a ferro magnet
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+
+
+
+
+
Loading...
+
Searching...
+
No Matches
+
+
+
+
+ +
+
Here is a list of all documented class members with links to the class documentation for each member:
+
+
+ + + + diff --git a/docs/functions_func.html b/docs/functions_func.html new file mode 100644 index 0000000..35e1c22 --- /dev/null +++ b/docs/functions_func.html @@ -0,0 +1,123 @@ + + + + + + + +2 Dimensional Ising Model: Class Members - Functions + + + + + + + + + + + + + + + + +
+
+ + + + + + +
+
2 Dimensional Ising Model +
+
Simulate the change in energy and magnetization in a ferro magnet
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+
+
+
+
+
Loading...
+
Searching...
+
No Matches
+
+
+
+
+ +
+
+
+ + + + diff --git a/docs/functions_vars.html b/docs/functions_vars.html new file mode 100644 index 0000000..5332b4c --- /dev/null +++ b/docs/functions_vars.html @@ -0,0 +1,119 @@ + + + + + + + +2 Dimensional Ising Model: Class Members - Variables + + + + + + + + + + + + + + + + +
+
+ + + + + + +
+
2 Dimensional Ising Model +
+
Simulate the change in energy and magnetization in a ferro magnet
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+
+
+
+
+
Loading...
+
Searching...
+
No Matches
+
+
+
+
+ +
+
+
+ + + + diff --git a/docs/globals.html b/docs/globals.html new file mode 100644 index 0000000..5d49ff3 --- /dev/null +++ b/docs/globals.html @@ -0,0 +1,123 @@ + + + + + + + +2 Dimensional Ising Model: File Members + + + + + + + + + + + + + + + + +
+
+ + + + + + +
+
2 Dimensional Ising Model +
+
Simulate the change in energy and magnetization in a ferro magnet
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+
+
+
+
+
Loading...
+
Searching...
+
No Matches
+
+
+
+
+ +
+
Here is a list of all documented file members with links to the documentation:
+
+
+ + + + diff --git a/docs/globals_defs.html b/docs/globals_defs.html new file mode 100644 index 0000000..a96a42a --- /dev/null +++ b/docs/globals_defs.html @@ -0,0 +1,116 @@ + + + + + + + +2 Dimensional Ising Model: File Members + + + + + + + + + + + + + + + + +
+
+ + + + + + +
+
2 Dimensional Ising Model +
+
Simulate the change in energy and magnetization in a ferro magnet
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+
+
+
+
+
Loading...
+
Searching...
+
No Matches
+
+
+
+
+ +
+
+
+ + + + diff --git a/docs/globals_func.html b/docs/globals_func.html new file mode 100644 index 0000000..08348b6 --- /dev/null +++ b/docs/globals_func.html @@ -0,0 +1,119 @@ + + + + + + + +2 Dimensional Ising Model: File Members + + + + + + + + + + + + + + + + +
+
+ + + + + + +
+
2 Dimensional Ising Model +
+
Simulate the change in energy and magnetization in a ferro magnet
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+
+
+
+
+
Loading...
+
Searching...
+
No Matches
+
+
+
+
+ +
+
+
+ + + + diff --git a/docs/index.html b/docs/index.html new file mode 100644 index 0000000..d282042 --- /dev/null +++ b/docs/index.html @@ -0,0 +1,216 @@ + + + + + + + +2 Dimensional Ising Model: Ising Model + + + + + + + + + + + + + + + + +
+
+ + + + + + +
+
2 Dimensional Ising Model +
+
Simulate the change in energy and magnetization in a ferro magnet
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+
+
+
+
+
Loading...
+
Searching...
+
No Matches
+
+
+
+
+ +
+
Ising Model
+
+
+

Repo

+

Documentation

+

+Requirements

+

+Operating systems

+
    +
  • Linux
      +
    • Has been tested on Fedora 38
    • +
    • Will most likely work on other Linux distributions
    • +
    +
  • +
  • MacOS
      +
    • Might work, but hasn't been tested
    • +
    +
  • +
  • Windows
      +
    • Will most likely not work
    • +
    +
  • +
+

+Tools

+ +

+Libraries

+ +

+Compiling

+

Compiling is as easy as running this command while being inside the src directory:

+
make
+

+Running programs

+

+C++ binaries

+

To run main or test_suite, just run this command while being inside src:

+
./<program-name>
+

+Python scripts

+

+Install libraries

+

Before running the scripts, make sure that all libraries are installed. Using pip, you can install all requirements like this:

+
pip install -r requirements.txt
+

This recursively install all the packages that are listed in requirements.txt.

+

+Running scripts

+

For the Python scripts, run them from the src directory like this:

+
python scripts/<script-name>
+

If you have any problems running the scripts, you might have to run this instead:

+
python3 scripts/<script-name>
+

+Batch system

+

For the phase_transition_mpi program, there are scripts in the src/jobs directory that come along with it. This is to be able to run it on a batch system using Slurm if you have access to one. This is the recommended way to use this program as it takes approximately 90 minutes to complete when using 8 processes where each process has 10 threads.

+

If you happen to have such a system available to you, then you should clone this repo on that system, then compile it by running:

+
make phase_transition_mpi
+

You might have to load the Armadillo library using the module system before compiling.

+

After compiling, you can schedule it by running:

+
sbatch jobs/<script-name>
+

+Performance

+

This section aims to give an idea to the time it takes for the program to run so that you know a bit what to expect if you decide to run it for yourself.

+

+CPU

+

The times mentioned here are times achieved on a computer with these specifications:

+
    +
  • CPU model
      +
    • Intel i7-9850H
    • +
    +
  • +
  • Threads
      +
    • 12
    • +
    +
  • +
  • Clock speed
      +
    • 4.6GHz
    • +
    +
  • +
+

+Times

+

+Credits

+

The Doxygen theme used here is doxygen-awesome-css.

+
+
+
+ + + + diff --git a/docs/index.js b/docs/index.js new file mode 100644 index 0000000..6788a1b --- /dev/null +++ b/docs/index.js @@ -0,0 +1,22 @@ +var index = +[ + [ "Requirements", "index.html#autotoc_md1", [ + [ "Operating systems", "index.html#autotoc_md2", null ], + [ "Tools", "index.html#autotoc_md3", null ], + [ "Libraries", "index.html#autotoc_md4", null ] + ] ], + [ "Compiling", "index.html#autotoc_md5", null ], + [ "Running programs", "index.html#autotoc_md6", [ + [ "C++ binaries", "index.html#autotoc_md7", null ], + [ "Python scripts", "index.html#autotoc_md8", [ + [ "Install libraries", "index.html#autotoc_md9", null ], + [ "Running scripts", "index.html#autotoc_md10", null ] + ] ], + [ "Batch system", "index.html#autotoc_md11", null ] + ] ], + [ "Performance", "index.html#autotoc_md12", [ + [ "CPU", "index.html#autotoc_md13", null ], + [ "Times", "index.html#autotoc_md14", null ] + ] ], + [ "Credits", "index.html#autotoc_md15", null ] +]; \ No newline at end of file diff --git a/docs/jquery.js b/docs/jquery.js new file mode 100644 index 0000000..1dffb65 --- /dev/null +++ b/docs/jquery.js @@ -0,0 +1,34 @@ +/*! jQuery v3.6.0 | (c) OpenJS Foundation and other contributors | jquery.org/license */ +!function(e,t){"use strict";"object"==typeof module&&"object"==typeof module.exports?module.exports=e.document?t(e,!0):function(e){if(!e.document)throw new Error("jQuery requires a window with a document");return t(e)}:t(e)}("undefined"!=typeof window?window:this,function(C,e){"use strict";var t=[],r=Object.getPrototypeOf,s=t.slice,g=t.flat?function(e){return t.flat.call(e)}:function(e){return t.concat.apply([],e)},u=t.push,i=t.indexOf,n={},o=n.toString,v=n.hasOwnProperty,a=v.toString,l=a.call(Object),y={},m=function(e){return"function"==typeof e&&"number"!=typeof e.nodeType&&"function"!=typeof e.item},x=function(e){return null!=e&&e===e.window},E=C.document,c={type:!0,src:!0,nonce:!0,noModule:!0};function b(e,t,n){var r,i,o=(n=n||E).createElement("script");if(o.text=e,t)for(r in c)(i=t[r]||t.getAttribute&&t.getAttribute(r))&&o.setAttribute(r,i);n.head.appendChild(o).parentNode.removeChild(o)}function w(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?n[o.call(e)]||"object":typeof e}var f="3.6.0",S=function(e,t){return new S.fn.init(e,t)};function p(e){var t=!!e&&"length"in e&&e.length,n=w(e);return!m(e)&&!x(e)&&("array"===n||0===t||"number"==typeof t&&0+~]|"+M+")"+M+"*"),U=new RegExp(M+"|>"),X=new RegExp(F),V=new RegExp("^"+I+"$"),G={ID:new RegExp("^#("+I+")"),CLASS:new RegExp("^\\.("+I+")"),TAG:new RegExp("^("+I+"|[*])"),ATTR:new RegExp("^"+W),PSEUDO:new RegExp("^"+F),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+M+"*(even|odd|(([+-]|)(\\d*)n|)"+M+"*(?:([+-]|)"+M+"*(\\d+)|))"+M+"*\\)|)","i"),bool:new RegExp("^(?:"+R+")$","i"),needsContext:new RegExp("^"+M+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+M+"*((?:-\\d)?\\d*)"+M+"*\\)|)(?=[^-]|$)","i")},Y=/HTML$/i,Q=/^(?:input|select|textarea|button)$/i,J=/^h\d$/i,K=/^[^{]+\{\s*\[native \w/,Z=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,ee=/[+~]/,te=new RegExp("\\\\[\\da-fA-F]{1,6}"+M+"?|\\\\([^\\r\\n\\f])","g"),ne=function(e,t){var n="0x"+e.slice(1)-65536;return t||(n<0?String.fromCharCode(n+65536):String.fromCharCode(n>>10|55296,1023&n|56320))},re=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\0-\x1f\x7f-\uFFFF\w-]/g,ie=function(e,t){return t?"\0"===e?"\ufffd":e.slice(0,-1)+"\\"+e.charCodeAt(e.length-1).toString(16)+" ":"\\"+e},oe=function(){T()},ae=be(function(e){return!0===e.disabled&&"fieldset"===e.nodeName.toLowerCase()},{dir:"parentNode",next:"legend"});try{H.apply(t=O.call(p.childNodes),p.childNodes),t[p.childNodes.length].nodeType}catch(e){H={apply:t.length?function(e,t){L.apply(e,O.call(t))}:function(e,t){var n=e.length,r=0;while(e[n++]=t[r++]);e.length=n-1}}}function se(t,e,n,r){var i,o,a,s,u,l,c,f=e&&e.ownerDocument,p=e?e.nodeType:9;if(n=n||[],"string"!=typeof t||!t||1!==p&&9!==p&&11!==p)return n;if(!r&&(T(e),e=e||C,E)){if(11!==p&&(u=Z.exec(t)))if(i=u[1]){if(9===p){if(!(a=e.getElementById(i)))return n;if(a.id===i)return n.push(a),n}else if(f&&(a=f.getElementById(i))&&y(e,a)&&a.id===i)return n.push(a),n}else{if(u[2])return H.apply(n,e.getElementsByTagName(t)),n;if((i=u[3])&&d.getElementsByClassName&&e.getElementsByClassName)return H.apply(n,e.getElementsByClassName(i)),n}if(d.qsa&&!N[t+" "]&&(!v||!v.test(t))&&(1!==p||"object"!==e.nodeName.toLowerCase())){if(c=t,f=e,1===p&&(U.test(t)||z.test(t))){(f=ee.test(t)&&ye(e.parentNode)||e)===e&&d.scope||((s=e.getAttribute("id"))?s=s.replace(re,ie):e.setAttribute("id",s=S)),o=(l=h(t)).length;while(o--)l[o]=(s?"#"+s:":scope")+" "+xe(l[o]);c=l.join(",")}try{return H.apply(n,f.querySelectorAll(c)),n}catch(e){N(t,!0)}finally{s===S&&e.removeAttribute("id")}}}return g(t.replace($,"$1"),e,n,r)}function ue(){var r=[];return function e(t,n){return r.push(t+" ")>b.cacheLength&&delete e[r.shift()],e[t+" "]=n}}function le(e){return e[S]=!0,e}function ce(e){var t=C.createElement("fieldset");try{return!!e(t)}catch(e){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function fe(e,t){var n=e.split("|"),r=n.length;while(r--)b.attrHandle[n[r]]=t}function pe(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&e.sourceIndex-t.sourceIndex;if(r)return r;if(n)while(n=n.nextSibling)if(n===t)return-1;return e?1:-1}function de(t){return function(e){return"input"===e.nodeName.toLowerCase()&&e.type===t}}function he(n){return function(e){var t=e.nodeName.toLowerCase();return("input"===t||"button"===t)&&e.type===n}}function ge(t){return function(e){return"form"in e?e.parentNode&&!1===e.disabled?"label"in e?"label"in e.parentNode?e.parentNode.disabled===t:e.disabled===t:e.isDisabled===t||e.isDisabled!==!t&&ae(e)===t:e.disabled===t:"label"in e&&e.disabled===t}}function ve(a){return le(function(o){return o=+o,le(function(e,t){var n,r=a([],e.length,o),i=r.length;while(i--)e[n=r[i]]&&(e[n]=!(t[n]=e[n]))})})}function ye(e){return e&&"undefined"!=typeof e.getElementsByTagName&&e}for(e in d=se.support={},i=se.isXML=function(e){var t=e&&e.namespaceURI,n=e&&(e.ownerDocument||e).documentElement;return!Y.test(t||n&&n.nodeName||"HTML")},T=se.setDocument=function(e){var t,n,r=e?e.ownerDocument||e:p;return r!=C&&9===r.nodeType&&r.documentElement&&(a=(C=r).documentElement,E=!i(C),p!=C&&(n=C.defaultView)&&n.top!==n&&(n.addEventListener?n.addEventListener("unload",oe,!1):n.attachEvent&&n.attachEvent("onunload",oe)),d.scope=ce(function(e){return a.appendChild(e).appendChild(C.createElement("div")),"undefined"!=typeof e.querySelectorAll&&!e.querySelectorAll(":scope fieldset div").length}),d.attributes=ce(function(e){return e.className="i",!e.getAttribute("className")}),d.getElementsByTagName=ce(function(e){return e.appendChild(C.createComment("")),!e.getElementsByTagName("*").length}),d.getElementsByClassName=K.test(C.getElementsByClassName),d.getById=ce(function(e){return a.appendChild(e).id=S,!C.getElementsByName||!C.getElementsByName(S).length}),d.getById?(b.filter.ID=function(e){var t=e.replace(te,ne);return function(e){return e.getAttribute("id")===t}},b.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&E){var n=t.getElementById(e);return n?[n]:[]}}):(b.filter.ID=function(e){var n=e.replace(te,ne);return function(e){var t="undefined"!=typeof e.getAttributeNode&&e.getAttributeNode("id");return t&&t.value===n}},b.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&E){var n,r,i,o=t.getElementById(e);if(o){if((n=o.getAttributeNode("id"))&&n.value===e)return[o];i=t.getElementsByName(e),r=0;while(o=i[r++])if((n=o.getAttributeNode("id"))&&n.value===e)return[o]}return[]}}),b.find.TAG=d.getElementsByTagName?function(e,t){return"undefined"!=typeof t.getElementsByTagName?t.getElementsByTagName(e):d.qsa?t.querySelectorAll(e):void 0}:function(e,t){var n,r=[],i=0,o=t.getElementsByTagName(e);if("*"===e){while(n=o[i++])1===n.nodeType&&r.push(n);return r}return o},b.find.CLASS=d.getElementsByClassName&&function(e,t){if("undefined"!=typeof t.getElementsByClassName&&E)return t.getElementsByClassName(e)},s=[],v=[],(d.qsa=K.test(C.querySelectorAll))&&(ce(function(e){var t;a.appendChild(e).innerHTML="",e.querySelectorAll("[msallowcapture^='']").length&&v.push("[*^$]="+M+"*(?:''|\"\")"),e.querySelectorAll("[selected]").length||v.push("\\["+M+"*(?:value|"+R+")"),e.querySelectorAll("[id~="+S+"-]").length||v.push("~="),(t=C.createElement("input")).setAttribute("name",""),e.appendChild(t),e.querySelectorAll("[name='']").length||v.push("\\["+M+"*name"+M+"*="+M+"*(?:''|\"\")"),e.querySelectorAll(":checked").length||v.push(":checked"),e.querySelectorAll("a#"+S+"+*").length||v.push(".#.+[+~]"),e.querySelectorAll("\\\f"),v.push("[\\r\\n\\f]")}),ce(function(e){e.innerHTML="";var t=C.createElement("input");t.setAttribute("type","hidden"),e.appendChild(t).setAttribute("name","D"),e.querySelectorAll("[name=d]").length&&v.push("name"+M+"*[*^$|!~]?="),2!==e.querySelectorAll(":enabled").length&&v.push(":enabled",":disabled"),a.appendChild(e).disabled=!0,2!==e.querySelectorAll(":disabled").length&&v.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),v.push(",.*:")})),(d.matchesSelector=K.test(c=a.matches||a.webkitMatchesSelector||a.mozMatchesSelector||a.oMatchesSelector||a.msMatchesSelector))&&ce(function(e){d.disconnectedMatch=c.call(e,"*"),c.call(e,"[s!='']:x"),s.push("!=",F)}),v=v.length&&new RegExp(v.join("|")),s=s.length&&new RegExp(s.join("|")),t=K.test(a.compareDocumentPosition),y=t||K.test(a.contains)?function(e,t){var n=9===e.nodeType?e.documentElement:e,r=t&&t.parentNode;return e===r||!(!r||1!==r.nodeType||!(n.contains?n.contains(r):e.compareDocumentPosition&&16&e.compareDocumentPosition(r)))}:function(e,t){if(t)while(t=t.parentNode)if(t===e)return!0;return!1},j=t?function(e,t){if(e===t)return l=!0,0;var n=!e.compareDocumentPosition-!t.compareDocumentPosition;return n||(1&(n=(e.ownerDocument||e)==(t.ownerDocument||t)?e.compareDocumentPosition(t):1)||!d.sortDetached&&t.compareDocumentPosition(e)===n?e==C||e.ownerDocument==p&&y(p,e)?-1:t==C||t.ownerDocument==p&&y(p,t)?1:u?P(u,e)-P(u,t):0:4&n?-1:1)}:function(e,t){if(e===t)return l=!0,0;var n,r=0,i=e.parentNode,o=t.parentNode,a=[e],s=[t];if(!i||!o)return e==C?-1:t==C?1:i?-1:o?1:u?P(u,e)-P(u,t):0;if(i===o)return pe(e,t);n=e;while(n=n.parentNode)a.unshift(n);n=t;while(n=n.parentNode)s.unshift(n);while(a[r]===s[r])r++;return r?pe(a[r],s[r]):a[r]==p?-1:s[r]==p?1:0}),C},se.matches=function(e,t){return se(e,null,null,t)},se.matchesSelector=function(e,t){if(T(e),d.matchesSelector&&E&&!N[t+" "]&&(!s||!s.test(t))&&(!v||!v.test(t)))try{var n=c.call(e,t);if(n||d.disconnectedMatch||e.document&&11!==e.document.nodeType)return n}catch(e){N(t,!0)}return 0":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(te,ne),e[3]=(e[3]||e[4]||e[5]||"").replace(te,ne),"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||se.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&se.error(e[0]),e},PSEUDO:function(e){var t,n=!e[6]&&e[2];return G.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":n&&X.test(n)&&(t=h(n,!0))&&(t=n.indexOf(")",n.length-t)-n.length)&&(e[0]=e[0].slice(0,t),e[2]=n.slice(0,t)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(te,ne).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=m[e+" "];return t||(t=new RegExp("(^|"+M+")"+e+"("+M+"|$)"))&&m(e,function(e){return t.test("string"==typeof e.className&&e.className||"undefined"!=typeof e.getAttribute&&e.getAttribute("class")||"")})},ATTR:function(n,r,i){return function(e){var t=se.attr(e,n);return null==t?"!="===r:!r||(t+="","="===r?t===i:"!="===r?t!==i:"^="===r?i&&0===t.indexOf(i):"*="===r?i&&-1:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;function j(e,n,r){return m(n)?S.grep(e,function(e,t){return!!n.call(e,t,e)!==r}):n.nodeType?S.grep(e,function(e){return e===n!==r}):"string"!=typeof n?S.grep(e,function(e){return-1)[^>]*|#([\w-]+))$/;(S.fn.init=function(e,t,n){var r,i;if(!e)return this;if(n=n||D,"string"==typeof e){if(!(r="<"===e[0]&&">"===e[e.length-1]&&3<=e.length?[null,e,null]:q.exec(e))||!r[1]&&t)return!t||t.jquery?(t||n).find(e):this.constructor(t).find(e);if(r[1]){if(t=t instanceof S?t[0]:t,S.merge(this,S.parseHTML(r[1],t&&t.nodeType?t.ownerDocument||t:E,!0)),N.test(r[1])&&S.isPlainObject(t))for(r in t)m(this[r])?this[r](t[r]):this.attr(r,t[r]);return this}return(i=E.getElementById(r[2]))&&(this[0]=i,this.length=1),this}return e.nodeType?(this[0]=e,this.length=1,this):m(e)?void 0!==n.ready?n.ready(e):e(S):S.makeArray(e,this)}).prototype=S.fn,D=S(E);var L=/^(?:parents|prev(?:Until|All))/,H={children:!0,contents:!0,next:!0,prev:!0};function O(e,t){while((e=e[t])&&1!==e.nodeType);return e}S.fn.extend({has:function(e){var t=S(e,this),n=t.length;return this.filter(function(){for(var e=0;e\x20\t\r\n\f]*)/i,he=/^$|^module$|\/(?:java|ecma)script/i;ce=E.createDocumentFragment().appendChild(E.createElement("div")),(fe=E.createElement("input")).setAttribute("type","radio"),fe.setAttribute("checked","checked"),fe.setAttribute("name","t"),ce.appendChild(fe),y.checkClone=ce.cloneNode(!0).cloneNode(!0).lastChild.checked,ce.innerHTML="",y.noCloneChecked=!!ce.cloneNode(!0).lastChild.defaultValue,ce.innerHTML="",y.option=!!ce.lastChild;var ge={thead:[1,"","
"],col:[2,"","
"],tr:[2,"","
"],td:[3,"","
"],_default:[0,"",""]};function ve(e,t){var n;return n="undefined"!=typeof e.getElementsByTagName?e.getElementsByTagName(t||"*"):"undefined"!=typeof e.querySelectorAll?e.querySelectorAll(t||"*"):[],void 0===t||t&&A(e,t)?S.merge([e],n):n}function ye(e,t){for(var n=0,r=e.length;n",""]);var me=/<|&#?\w+;/;function xe(e,t,n,r,i){for(var o,a,s,u,l,c,f=t.createDocumentFragment(),p=[],d=0,h=e.length;d\s*$/g;function je(e,t){return A(e,"table")&&A(11!==t.nodeType?t:t.firstChild,"tr")&&S(e).children("tbody")[0]||e}function De(e){return e.type=(null!==e.getAttribute("type"))+"/"+e.type,e}function qe(e){return"true/"===(e.type||"").slice(0,5)?e.type=e.type.slice(5):e.removeAttribute("type"),e}function Le(e,t){var n,r,i,o,a,s;if(1===t.nodeType){if(Y.hasData(e)&&(s=Y.get(e).events))for(i in Y.remove(t,"handle events"),s)for(n=0,r=s[i].length;n").attr(n.scriptAttrs||{}).prop({charset:n.scriptCharset,src:n.url}).on("load error",i=function(e){r.remove(),i=null,e&&t("error"===e.type?404:200,e.type)}),E.head.appendChild(r[0])},abort:function(){i&&i()}}});var _t,zt=[],Ut=/(=)\?(?=&|$)|\?\?/;S.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var e=zt.pop()||S.expando+"_"+wt.guid++;return this[e]=!0,e}}),S.ajaxPrefilter("json jsonp",function(e,t,n){var r,i,o,a=!1!==e.jsonp&&(Ut.test(e.url)?"url":"string"==typeof e.data&&0===(e.contentType||"").indexOf("application/x-www-form-urlencoded")&&Ut.test(e.data)&&"data");if(a||"jsonp"===e.dataTypes[0])return r=e.jsonpCallback=m(e.jsonpCallback)?e.jsonpCallback():e.jsonpCallback,a?e[a]=e[a].replace(Ut,"$1"+r):!1!==e.jsonp&&(e.url+=(Tt.test(e.url)?"&":"?")+e.jsonp+"="+r),e.converters["script json"]=function(){return o||S.error(r+" was not called"),o[0]},e.dataTypes[0]="json",i=C[r],C[r]=function(){o=arguments},n.always(function(){void 0===i?S(C).removeProp(r):C[r]=i,e[r]&&(e.jsonpCallback=t.jsonpCallback,zt.push(r)),o&&m(i)&&i(o[0]),o=i=void 0}),"script"}),y.createHTMLDocument=((_t=E.implementation.createHTMLDocument("").body).innerHTML="
",2===_t.childNodes.length),S.parseHTML=function(e,t,n){return"string"!=typeof e?[]:("boolean"==typeof t&&(n=t,t=!1),t||(y.createHTMLDocument?((r=(t=E.implementation.createHTMLDocument("")).createElement("base")).href=E.location.href,t.head.appendChild(r)):t=E),o=!n&&[],(i=N.exec(e))?[t.createElement(i[1])]:(i=xe([e],t,o),o&&o.length&&S(o).remove(),S.merge([],i.childNodes)));var r,i,o},S.fn.load=function(e,t,n){var r,i,o,a=this,s=e.indexOf(" ");return-1").append(S.parseHTML(e)).find(r):e)}).always(n&&function(e,t){a.each(function(){n.apply(this,o||[e.responseText,t,e])})}),this},S.expr.pseudos.animated=function(t){return S.grep(S.timers,function(e){return t===e.elem}).length},S.offset={setOffset:function(e,t,n){var r,i,o,a,s,u,l=S.css(e,"position"),c=S(e),f={};"static"===l&&(e.style.position="relative"),s=c.offset(),o=S.css(e,"top"),u=S.css(e,"left"),("absolute"===l||"fixed"===l)&&-1<(o+u).indexOf("auto")?(a=(r=c.position()).top,i=r.left):(a=parseFloat(o)||0,i=parseFloat(u)||0),m(t)&&(t=t.call(e,n,S.extend({},s))),null!=t.top&&(f.top=t.top-s.top+a),null!=t.left&&(f.left=t.left-s.left+i),"using"in t?t.using.call(e,f):c.css(f)}},S.fn.extend({offset:function(t){if(arguments.length)return void 0===t?this:this.each(function(e){S.offset.setOffset(this,t,e)});var e,n,r=this[0];return r?r.getClientRects().length?(e=r.getBoundingClientRect(),n=r.ownerDocument.defaultView,{top:e.top+n.pageYOffset,left:e.left+n.pageXOffset}):{top:0,left:0}:void 0},position:function(){if(this[0]){var e,t,n,r=this[0],i={top:0,left:0};if("fixed"===S.css(r,"position"))t=r.getBoundingClientRect();else{t=this.offset(),n=r.ownerDocument,e=r.offsetParent||n.documentElement;while(e&&(e===n.body||e===n.documentElement)&&"static"===S.css(e,"position"))e=e.parentNode;e&&e!==r&&1===e.nodeType&&((i=S(e).offset()).top+=S.css(e,"borderTopWidth",!0),i.left+=S.css(e,"borderLeftWidth",!0))}return{top:t.top-i.top-S.css(r,"marginTop",!0),left:t.left-i.left-S.css(r,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){var e=this.offsetParent;while(e&&"static"===S.css(e,"position"))e=e.offsetParent;return e||re})}}),S.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(t,i){var o="pageYOffset"===i;S.fn[t]=function(e){return $(this,function(e,t,n){var r;if(x(e)?r=e:9===e.nodeType&&(r=e.defaultView),void 0===n)return r?r[i]:e[t];r?r.scrollTo(o?r.pageXOffset:n,o?n:r.pageYOffset):e[t]=n},t,e,arguments.length)}}),S.each(["top","left"],function(e,n){S.cssHooks[n]=Fe(y.pixelPosition,function(e,t){if(t)return t=We(e,n),Pe.test(t)?S(e).position()[n]+"px":t})}),S.each({Height:"height",Width:"width"},function(a,s){S.each({padding:"inner"+a,content:s,"":"outer"+a},function(r,o){S.fn[o]=function(e,t){var n=arguments.length&&(r||"boolean"!=typeof e),i=r||(!0===e||!0===t?"margin":"border");return $(this,function(e,t,n){var r;return x(e)?0===o.indexOf("outer")?e["inner"+a]:e.document.documentElement["client"+a]:9===e.nodeType?(r=e.documentElement,Math.max(e.body["scroll"+a],r["scroll"+a],e.body["offset"+a],r["offset"+a],r["client"+a])):void 0===n?S.css(e,t,i):S.style(e,t,n,i)},s,n?e:void 0,n)}})}),S.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(e,t){S.fn[t]=function(e){return this.on(t,e)}}),S.fn.extend({bind:function(e,t,n){return this.on(e,null,t,n)},unbind:function(e,t){return this.off(e,null,t)},delegate:function(e,t,n,r){return this.on(t,e,n,r)},undelegate:function(e,t,n){return 1===arguments.length?this.off(e,"**"):this.off(t,e||"**",n)},hover:function(e,t){return this.mouseenter(e).mouseleave(t||e)}}),S.each("blur focus focusin focusout resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu".split(" "),function(e,n){S.fn[n]=function(e,t){return 0",options:{classes:{},disabled:!1,create:null},_createWidget:function(t,e){e=y(e||this.defaultElement||this)[0],this.element=y(e),this.uuid=i++,this.eventNamespace="."+this.widgetName+this.uuid,this.bindings=y(),this.hoverable=y(),this.focusable=y(),this.classesElementLookup={},e!==this&&(y.data(e,this.widgetFullName,this),this._on(!0,this.element,{remove:function(t){t.target===e&&this.destroy()}}),this.document=y(e.style?e.ownerDocument:e.document||e),this.window=y(this.document[0].defaultView||this.document[0].parentWindow)),this.options=y.widget.extend({},this.options,this._getCreateOptions(),t),this._create(),this.options.disabled&&this._setOptionDisabled(this.options.disabled),this._trigger("create",null,this._getCreateEventData()),this._init()},_getCreateOptions:function(){return{}},_getCreateEventData:y.noop,_create:y.noop,_init:y.noop,destroy:function(){var i=this;this._destroy(),y.each(this.classesElementLookup,function(t,e){i._removeClass(e,t)}),this.element.off(this.eventNamespace).removeData(this.widgetFullName),this.widget().off(this.eventNamespace).removeAttr("aria-disabled"),this.bindings.off(this.eventNamespace)},_destroy:y.noop,widget:function(){return this.element},option:function(t,e){var i,s,n,o=t;if(0===arguments.length)return y.widget.extend({},this.options);if("string"==typeof t)if(o={},t=(i=t.split(".")).shift(),i.length){for(s=o[t]=y.widget.extend({},this.options[t]),n=0;n
"),i=e.children()[0];return y("body").append(e),t=i.offsetWidth,e.css("overflow","scroll"),t===(i=i.offsetWidth)&&(i=e[0].clientWidth),e.remove(),s=t-i},getScrollInfo:function(t){var e=t.isWindow||t.isDocument?"":t.element.css("overflow-x"),i=t.isWindow||t.isDocument?"":t.element.css("overflow-y"),e="scroll"===e||"auto"===e&&t.widthx(D(s),D(n))?o.important="horizontal":o.important="vertical",p.using.call(this,t,o)}),h.offset(y.extend(l,{using:t}))})},y.ui.position={fit:{left:function(t,e){var i=e.within,s=i.isWindow?i.scrollLeft:i.offset.left,n=i.width,o=t.left-e.collisionPosition.marginLeft,h=s-o,a=o+e.collisionWidth-n-s;e.collisionWidth>n?0n?0=this.options.distance},_mouseDelayMet:function(){return this.mouseDelayMet},_mouseStart:function(){},_mouseDrag:function(){},_mouseStop:function(){},_mouseCapture:function(){return!0}}),y.ui.plugin={add:function(t,e,i){var s,n=y.ui[t].prototype;for(s in i)n.plugins[s]=n.plugins[s]||[],n.plugins[s].push([e,i[s]])},call:function(t,e,i,s){var n,o=t.plugins[e];if(o&&(s||t.element[0].parentNode&&11!==t.element[0].parentNode.nodeType))for(n=0;n").css({overflow:"hidden",position:this.element.css("position"),width:this.element.outerWidth(),height:this.element.outerHeight(),top:this.element.css("top"),left:this.element.css("left")})),this.element=this.element.parent().data("ui-resizable",this.element.resizable("instance")),this.elementIsWrapper=!0,t={marginTop:this.originalElement.css("marginTop"),marginRight:this.originalElement.css("marginRight"),marginBottom:this.originalElement.css("marginBottom"),marginLeft:this.originalElement.css("marginLeft")},this.element.css(t),this.originalElement.css("margin",0),this.originalResizeStyle=this.originalElement.css("resize"),this.originalElement.css("resize","none"),this._proportionallyResizeElements.push(this.originalElement.css({position:"static",zoom:1,display:"block"})),this.originalElement.css(t),this._proportionallyResize()),this._setupHandles(),e.autoHide&&y(this.element).on("mouseenter",function(){e.disabled||(i._removeClass("ui-resizable-autohide"),i._handles.show())}).on("mouseleave",function(){e.disabled||i.resizing||(i._addClass("ui-resizable-autohide"),i._handles.hide())}),this._mouseInit()},_destroy:function(){this._mouseDestroy(),this._addedHandles.remove();function t(t){y(t).removeData("resizable").removeData("ui-resizable").off(".resizable")}var e;return this.elementIsWrapper&&(t(this.element),e=this.element,this.originalElement.css({position:e.css("position"),width:e.outerWidth(),height:e.outerHeight(),top:e.css("top"),left:e.css("left")}).insertAfter(e),e.remove()),this.originalElement.css("resize",this.originalResizeStyle),t(this.originalElement),this},_setOption:function(t,e){switch(this._super(t,e),t){case"handles":this._removeHandles(),this._setupHandles();break;case"aspectRatio":this._aspectRatio=!!e}},_setupHandles:function(){var t,e,i,s,n,o=this.options,h=this;if(this.handles=o.handles||(y(".ui-resizable-handle",this.element).length?{n:".ui-resizable-n",e:".ui-resizable-e",s:".ui-resizable-s",w:".ui-resizable-w",se:".ui-resizable-se",sw:".ui-resizable-sw",ne:".ui-resizable-ne",nw:".ui-resizable-nw"}:"e,s,se"),this._handles=y(),this._addedHandles=y(),this.handles.constructor===String)for("all"===this.handles&&(this.handles="n,e,s,w,se,sw,ne,nw"),i=this.handles.split(","),this.handles={},e=0;e"),this._addClass(n,"ui-resizable-handle "+s),n.css({zIndex:o.zIndex}),this.handles[t]=".ui-resizable-"+t,this.element.children(this.handles[t]).length||(this.element.append(n),this._addedHandles=this._addedHandles.add(n));this._renderAxis=function(t){var e,i,s;for(e in t=t||this.element,this.handles)this.handles[e].constructor===String?this.handles[e]=this.element.children(this.handles[e]).first().show():(this.handles[e].jquery||this.handles[e].nodeType)&&(this.handles[e]=y(this.handles[e]),this._on(this.handles[e],{mousedown:h._mouseDown})),this.elementIsWrapper&&this.originalElement[0].nodeName.match(/^(textarea|input|select|button)$/i)&&(i=y(this.handles[e],this.element),s=/sw|ne|nw|se|n|s/.test(e)?i.outerHeight():i.outerWidth(),i=["padding",/ne|nw|n/.test(e)?"Top":/se|sw|s/.test(e)?"Bottom":/^e$/.test(e)?"Right":"Left"].join(""),t.css(i,s),this._proportionallyResize()),this._handles=this._handles.add(this.handles[e])},this._renderAxis(this.element),this._handles=this._handles.add(this.element.find(".ui-resizable-handle")),this._handles.disableSelection(),this._handles.on("mouseover",function(){h.resizing||(this.className&&(n=this.className.match(/ui-resizable-(se|sw|ne|nw|n|e|s|w)/i)),h.axis=n&&n[1]?n[1]:"se")}),o.autoHide&&(this._handles.hide(),this._addClass("ui-resizable-autohide"))},_removeHandles:function(){this._addedHandles.remove()},_mouseCapture:function(t){var e,i,s=!1;for(e in this.handles)(i=y(this.handles[e])[0])!==t.target&&!y.contains(i,t.target)||(s=!0);return!this.options.disabled&&s},_mouseStart:function(t){var e,i,s=this.options,n=this.element;return this.resizing=!0,this._renderProxy(),e=this._num(this.helper.css("left")),i=this._num(this.helper.css("top")),s.containment&&(e+=y(s.containment).scrollLeft()||0,i+=y(s.containment).scrollTop()||0),this.offset=this.helper.offset(),this.position={left:e,top:i},this.size=this._helper?{width:this.helper.width(),height:this.helper.height()}:{width:n.width(),height:n.height()},this.originalSize=this._helper?{width:n.outerWidth(),height:n.outerHeight()}:{width:n.width(),height:n.height()},this.sizeDiff={width:n.outerWidth()-n.width(),height:n.outerHeight()-n.height()},this.originalPosition={left:e,top:i},this.originalMousePosition={left:t.pageX,top:t.pageY},this.aspectRatio="number"==typeof s.aspectRatio?s.aspectRatio:this.originalSize.width/this.originalSize.height||1,s=y(".ui-resizable-"+this.axis).css("cursor"),y("body").css("cursor","auto"===s?this.axis+"-resize":s),this._addClass("ui-resizable-resizing"),this._propagate("start",t),!0},_mouseDrag:function(t){var e=this.originalMousePosition,i=this.axis,s=t.pageX-e.left||0,e=t.pageY-e.top||0,i=this._change[i];return this._updatePrevProperties(),i&&(e=i.apply(this,[t,s,e]),this._updateVirtualBoundaries(t.shiftKey),(this._aspectRatio||t.shiftKey)&&(e=this._updateRatio(e,t)),e=this._respectSize(e,t),this._updateCache(e),this._propagate("resize",t),e=this._applyChanges(),!this._helper&&this._proportionallyResizeElements.length&&this._proportionallyResize(),y.isEmptyObject(e)||(this._updatePrevProperties(),this._trigger("resize",t,this.ui()),this._applyChanges())),!1},_mouseStop:function(t){this.resizing=!1;var e,i,s,n=this.options,o=this;return this._helper&&(s=(e=(i=this._proportionallyResizeElements).length&&/textarea/i.test(i[0].nodeName))&&this._hasScroll(i[0],"left")?0:o.sizeDiff.height,i=e?0:o.sizeDiff.width,e={width:o.helper.width()-i,height:o.helper.height()-s},i=parseFloat(o.element.css("left"))+(o.position.left-o.originalPosition.left)||null,s=parseFloat(o.element.css("top"))+(o.position.top-o.originalPosition.top)||null,n.animate||this.element.css(y.extend(e,{top:s,left:i})),o.helper.height(o.size.height),o.helper.width(o.size.width),this._helper&&!n.animate&&this._proportionallyResize()),y("body").css("cursor","auto"),this._removeClass("ui-resizable-resizing"),this._propagate("stop",t),this._helper&&this.helper.remove(),!1},_updatePrevProperties:function(){this.prevPosition={top:this.position.top,left:this.position.left},this.prevSize={width:this.size.width,height:this.size.height}},_applyChanges:function(){var t={};return this.position.top!==this.prevPosition.top&&(t.top=this.position.top+"px"),this.position.left!==this.prevPosition.left&&(t.left=this.position.left+"px"),this.size.width!==this.prevSize.width&&(t.width=this.size.width+"px"),this.size.height!==this.prevSize.height&&(t.height=this.size.height+"px"),this.helper.css(t),t},_updateVirtualBoundaries:function(t){var e,i,s=this.options,n={minWidth:this._isNumber(s.minWidth)?s.minWidth:0,maxWidth:this._isNumber(s.maxWidth)?s.maxWidth:1/0,minHeight:this._isNumber(s.minHeight)?s.minHeight:0,maxHeight:this._isNumber(s.maxHeight)?s.maxHeight:1/0};(this._aspectRatio||t)&&(e=n.minHeight*this.aspectRatio,i=n.minWidth/this.aspectRatio,s=n.maxHeight*this.aspectRatio,t=n.maxWidth/this.aspectRatio,e>n.minWidth&&(n.minWidth=e),i>n.minHeight&&(n.minHeight=i),st.width,h=this._isNumber(t.height)&&e.minHeight&&e.minHeight>t.height,a=this.originalPosition.left+this.originalSize.width,r=this.originalPosition.top+this.originalSize.height,l=/sw|nw|w/.test(i),i=/nw|ne|n/.test(i);return o&&(t.width=e.minWidth),h&&(t.height=e.minHeight),s&&(t.width=e.maxWidth),n&&(t.height=e.maxHeight),o&&l&&(t.left=a-e.minWidth),s&&l&&(t.left=a-e.maxWidth),h&&i&&(t.top=r-e.minHeight),n&&i&&(t.top=r-e.maxHeight),t.width||t.height||t.left||!t.top?t.width||t.height||t.top||!t.left||(t.left=null):t.top=null,t},_getPaddingPlusBorderDimensions:function(t){for(var e=0,i=[],s=[t.css("borderTopWidth"),t.css("borderRightWidth"),t.css("borderBottomWidth"),t.css("borderLeftWidth")],n=[t.css("paddingTop"),t.css("paddingRight"),t.css("paddingBottom"),t.css("paddingLeft")];e<4;e++)i[e]=parseFloat(s[e])||0,i[e]+=parseFloat(n[e])||0;return{height:i[0]+i[2],width:i[1]+i[3]}},_proportionallyResize:function(){if(this._proportionallyResizeElements.length)for(var t,e=0,i=this.helper||this.element;e").css({overflow:"hidden"}),this._addClass(this.helper,this._helper),this.helper.css({width:this.element.outerWidth(),height:this.element.outerHeight(),position:"absolute",left:this.elementOffset.left+"px",top:this.elementOffset.top+"px",zIndex:++e.zIndex}),this.helper.appendTo("body").disableSelection()):this.helper=this.element},_change:{e:function(t,e){return{width:this.originalSize.width+e}},w:function(t,e){var i=this.originalSize;return{left:this.originalPosition.left+e,width:i.width-e}},n:function(t,e,i){var s=this.originalSize;return{top:this.originalPosition.top+i,height:s.height-i}},s:function(t,e,i){return{height:this.originalSize.height+i}},se:function(t,e,i){return y.extend(this._change.s.apply(this,arguments),this._change.e.apply(this,[t,e,i]))},sw:function(t,e,i){return y.extend(this._change.s.apply(this,arguments),this._change.w.apply(this,[t,e,i]))},ne:function(t,e,i){return y.extend(this._change.n.apply(this,arguments),this._change.e.apply(this,[t,e,i]))},nw:function(t,e,i){return y.extend(this._change.n.apply(this,arguments),this._change.w.apply(this,[t,e,i]))}},_propagate:function(t,e){y.ui.plugin.call(this,t,[e,this.ui()]),"resize"!==t&&this._trigger(t,e,this.ui())},plugins:{},ui:function(){return{originalElement:this.originalElement,element:this.element,helper:this.helper,position:this.position,size:this.size,originalSize:this.originalSize,originalPosition:this.originalPosition}}}),y.ui.plugin.add("resizable","animate",{stop:function(e){var i=y(this).resizable("instance"),t=i.options,s=i._proportionallyResizeElements,n=s.length&&/textarea/i.test(s[0].nodeName),o=n&&i._hasScroll(s[0],"left")?0:i.sizeDiff.height,h=n?0:i.sizeDiff.width,n={width:i.size.width-h,height:i.size.height-o},h=parseFloat(i.element.css("left"))+(i.position.left-i.originalPosition.left)||null,o=parseFloat(i.element.css("top"))+(i.position.top-i.originalPosition.top)||null;i.element.animate(y.extend(n,o&&h?{top:o,left:h}:{}),{duration:t.animateDuration,easing:t.animateEasing,step:function(){var t={width:parseFloat(i.element.css("width")),height:parseFloat(i.element.css("height")),top:parseFloat(i.element.css("top")),left:parseFloat(i.element.css("left"))};s&&s.length&&y(s[0]).css({width:t.width,height:t.height}),i._updateCache(t),i._propagate("resize",e)}})}}),y.ui.plugin.add("resizable","containment",{start:function(){var i,s,n=y(this).resizable("instance"),t=n.options,e=n.element,o=t.containment,h=o instanceof y?o.get(0):/parent/.test(o)?e.parent().get(0):o;h&&(n.containerElement=y(h),/document/.test(o)||o===document?(n.containerOffset={left:0,top:0},n.containerPosition={left:0,top:0},n.parentData={element:y(document),left:0,top:0,width:y(document).width(),height:y(document).height()||document.body.parentNode.scrollHeight}):(i=y(h),s=[],y(["Top","Right","Left","Bottom"]).each(function(t,e){s[t]=n._num(i.css("padding"+e))}),n.containerOffset=i.offset(),n.containerPosition=i.position(),n.containerSize={height:i.innerHeight()-s[3],width:i.innerWidth()-s[1]},t=n.containerOffset,e=n.containerSize.height,o=n.containerSize.width,o=n._hasScroll(h,"left")?h.scrollWidth:o,e=n._hasScroll(h)?h.scrollHeight:e,n.parentData={element:h,left:t.left,top:t.top,width:o,height:e}))},resize:function(t){var e=y(this).resizable("instance"),i=e.options,s=e.containerOffset,n=e.position,o=e._aspectRatio||t.shiftKey,h={top:0,left:0},a=e.containerElement,t=!0;a[0]!==document&&/static/.test(a.css("position"))&&(h=s),n.left<(e._helper?s.left:0)&&(e.size.width=e.size.width+(e._helper?e.position.left-s.left:e.position.left-h.left),o&&(e.size.height=e.size.width/e.aspectRatio,t=!1),e.position.left=i.helper?s.left:0),n.top<(e._helper?s.top:0)&&(e.size.height=e.size.height+(e._helper?e.position.top-s.top:e.position.top),o&&(e.size.width=e.size.height*e.aspectRatio,t=!1),e.position.top=e._helper?s.top:0),i=e.containerElement.get(0)===e.element.parent().get(0),n=/relative|absolute/.test(e.containerElement.css("position")),i&&n?(e.offset.left=e.parentData.left+e.position.left,e.offset.top=e.parentData.top+e.position.top):(e.offset.left=e.element.offset().left,e.offset.top=e.element.offset().top),n=Math.abs(e.sizeDiff.width+(e._helper?e.offset.left-h.left:e.offset.left-s.left)),s=Math.abs(e.sizeDiff.height+(e._helper?e.offset.top-h.top:e.offset.top-s.top)),n+e.size.width>=e.parentData.width&&(e.size.width=e.parentData.width-n,o&&(e.size.height=e.size.width/e.aspectRatio,t=!1)),s+e.size.height>=e.parentData.height&&(e.size.height=e.parentData.height-s,o&&(e.size.width=e.size.height*e.aspectRatio,t=!1)),t||(e.position.left=e.prevPosition.left,e.position.top=e.prevPosition.top,e.size.width=e.prevSize.width,e.size.height=e.prevSize.height)},stop:function(){var t=y(this).resizable("instance"),e=t.options,i=t.containerOffset,s=t.containerPosition,n=t.containerElement,o=y(t.helper),h=o.offset(),a=o.outerWidth()-t.sizeDiff.width,o=o.outerHeight()-t.sizeDiff.height;t._helper&&!e.animate&&/relative/.test(n.css("position"))&&y(this).css({left:h.left-s.left-i.left,width:a,height:o}),t._helper&&!e.animate&&/static/.test(n.css("position"))&&y(this).css({left:h.left-s.left-i.left,width:a,height:o})}}),y.ui.plugin.add("resizable","alsoResize",{start:function(){var t=y(this).resizable("instance").options;y(t.alsoResize).each(function(){var t=y(this);t.data("ui-resizable-alsoresize",{width:parseFloat(t.width()),height:parseFloat(t.height()),left:parseFloat(t.css("left")),top:parseFloat(t.css("top"))})})},resize:function(t,i){var e=y(this).resizable("instance"),s=e.options,n=e.originalSize,o=e.originalPosition,h={height:e.size.height-n.height||0,width:e.size.width-n.width||0,top:e.position.top-o.top||0,left:e.position.left-o.left||0};y(s.alsoResize).each(function(){var t=y(this),s=y(this).data("ui-resizable-alsoresize"),n={},e=t.parents(i.originalElement[0]).length?["width","height"]:["width","height","top","left"];y.each(e,function(t,e){var i=(s[e]||0)+(h[e]||0);i&&0<=i&&(n[e]=i||null)}),t.css(n)})},stop:function(){y(this).removeData("ui-resizable-alsoresize")}}),y.ui.plugin.add("resizable","ghost",{start:function(){var t=y(this).resizable("instance"),e=t.size;t.ghost=t.originalElement.clone(),t.ghost.css({opacity:.25,display:"block",position:"relative",height:e.height,width:e.width,margin:0,left:0,top:0}),t._addClass(t.ghost,"ui-resizable-ghost"),!1!==y.uiBackCompat&&"string"==typeof t.options.ghost&&t.ghost.addClass(this.options.ghost),t.ghost.appendTo(t.helper)},resize:function(){var t=y(this).resizable("instance");t.ghost&&t.ghost.css({position:"relative",height:t.size.height,width:t.size.width})},stop:function(){var t=y(this).resizable("instance");t.ghost&&t.helper&&t.helper.get(0).removeChild(t.ghost.get(0))}}),y.ui.plugin.add("resizable","grid",{resize:function(){var t,e=y(this).resizable("instance"),i=e.options,s=e.size,n=e.originalSize,o=e.originalPosition,h=e.axis,a="number"==typeof i.grid?[i.grid,i.grid]:i.grid,r=a[0]||1,l=a[1]||1,u=Math.round((s.width-n.width)/r)*r,p=Math.round((s.height-n.height)/l)*l,d=n.width+u,c=n.height+p,f=i.maxWidth&&i.maxWidthd,s=i.minHeight&&i.minHeight>c;i.grid=a,m&&(d+=r),s&&(c+=l),f&&(d-=r),g&&(c-=l),/^(se|s|e)$/.test(h)?(e.size.width=d,e.size.height=c):/^(ne)$/.test(h)?(e.size.width=d,e.size.height=c,e.position.top=o.top-p):/^(sw)$/.test(h)?(e.size.width=d,e.size.height=c,e.position.left=o.left-u):((c-l<=0||d-r<=0)&&(t=e._getPaddingPlusBorderDimensions(this)),0=f[g]?0:Math.min(f[g],n));!a&&1-1){targetElements.on(evt+EVENT_NAMESPACE,function elementToggle(event){$.powerTip.toggle(this,event)})}else{targetElements.on(evt+EVENT_NAMESPACE,function elementOpen(event){$.powerTip.show(this,event)})}});$.each(options.closeEvents,function(idx,evt){if($.inArray(evt,options.openEvents)<0){targetElements.on(evt+EVENT_NAMESPACE,function elementClose(event){$.powerTip.hide(this,!isMouseEvent(event))})}});targetElements.on("keydown"+EVENT_NAMESPACE,function elementKeyDown(event){if(event.keyCode===27){$.powerTip.hide(this,true)}})}return targetElements};$.fn.powerTip.defaults={fadeInTime:200,fadeOutTime:100,followMouse:false,popupId:"powerTip",popupClass:null,intentSensitivity:7,intentPollInterval:100,closeDelay:100,placement:"n",smartPlacement:false,offset:10,mouseOnToPopup:false,manual:false,openEvents:["mouseenter","focus"],closeEvents:["mouseleave","blur"]};$.fn.powerTip.smartPlacementLists={n:["n","ne","nw","s"],e:["e","ne","se","w","nw","sw","n","s","e"],s:["s","se","sw","n"],w:["w","nw","sw","e","ne","se","n","s","w"],nw:["nw","w","sw","n","s","se","nw"],ne:["ne","e","se","n","s","sw","ne"],sw:["sw","w","nw","s","n","ne","sw"],se:["se","e","ne","s","n","nw","se"],"nw-alt":["nw-alt","n","ne-alt","sw-alt","s","se-alt","w","e"],"ne-alt":["ne-alt","n","nw-alt","se-alt","s","sw-alt","e","w"],"sw-alt":["sw-alt","s","se-alt","nw-alt","n","ne-alt","w","e"],"se-alt":["se-alt","s","sw-alt","ne-alt","n","nw-alt","e","w"]};$.powerTip={show:function apiShowTip(element,event){if(isMouseEvent(event)){trackMouse(event);session.previousX=event.pageX;session.previousY=event.pageY;$(element).data(DATA_DISPLAYCONTROLLER).show()}else{$(element).first().data(DATA_DISPLAYCONTROLLER).show(true,true)}return element},reposition:function apiResetPosition(element){$(element).first().data(DATA_DISPLAYCONTROLLER).resetPosition();return element},hide:function apiCloseTip(element,immediate){var displayController;immediate=element?immediate:true;if(element){displayController=$(element).first().data(DATA_DISPLAYCONTROLLER)}else if(session.activeHover){displayController=session.activeHover.data(DATA_DISPLAYCONTROLLER)}if(displayController){displayController.hide(immediate)}return element},toggle:function apiToggle(element,event){if(session.activeHover&&session.activeHover.is(element)){$.powerTip.hide(element,!isMouseEvent(event))}else{$.powerTip.show(element,event)}return element}};$.powerTip.showTip=$.powerTip.show;$.powerTip.closeTip=$.powerTip.hide;function CSSCoordinates(){var me=this;me.top="auto";me.left="auto";me.right="auto";me.bottom="auto";me.set=function(property,value){if($.isNumeric(value)){me[property]=Math.round(value)}}}function DisplayController(element,options,tipController){var hoverTimer=null,myCloseDelay=null;function openTooltip(immediate,forceOpen){cancelTimer();if(!element.data(DATA_HASACTIVEHOVER)){if(!immediate){session.tipOpenImminent=true;hoverTimer=setTimeout(function intentDelay(){hoverTimer=null;checkForIntent()},options.intentPollInterval)}else{if(forceOpen){element.data(DATA_FORCEDOPEN,true)}closeAnyDelayed();tipController.showTip(element)}}else{cancelClose()}}function closeTooltip(disableDelay){if(myCloseDelay){myCloseDelay=session.closeDelayTimeout=clearTimeout(myCloseDelay);session.delayInProgress=false}cancelTimer();session.tipOpenImminent=false;if(element.data(DATA_HASACTIVEHOVER)){element.data(DATA_FORCEDOPEN,false);if(!disableDelay){session.delayInProgress=true;session.closeDelayTimeout=setTimeout(function closeDelay(){session.closeDelayTimeout=null;tipController.hideTip(element);session.delayInProgress=false;myCloseDelay=null},options.closeDelay);myCloseDelay=session.closeDelayTimeout}else{tipController.hideTip(element)}}}function checkForIntent(){var xDifference=Math.abs(session.previousX-session.currentX),yDifference=Math.abs(session.previousY-session.currentY),totalDifference=xDifference+yDifference;if(totalDifference",{id:options.popupId});if($body.length===0){$body=$("body")}$body.append(tipElement);session.tooltips=session.tooltips?session.tooltips.add(tipElement):tipElement}if(options.followMouse){if(!tipElement.data(DATA_HASMOUSEMOVE)){$document.on("mousemove"+EVENT_NAMESPACE,positionTipOnCursor);$window.on("scroll"+EVENT_NAMESPACE,positionTipOnCursor);tipElement.data(DATA_HASMOUSEMOVE,true)}}function beginShowTip(element){element.data(DATA_HASACTIVEHOVER,true);tipElement.queue(function queueTipInit(next){showTip(element);next()})}function showTip(element){var tipContent;if(!element.data(DATA_HASACTIVEHOVER)){return}if(session.isTipOpen){if(!session.isClosing){hideTip(session.activeHover)}tipElement.delay(100).queue(function queueTipAgain(next){showTip(element);next()});return}element.trigger("powerTipPreRender");tipContent=getTooltipContent(element);if(tipContent){tipElement.empty().append(tipContent)}else{return}element.trigger("powerTipRender");session.activeHover=element;session.isTipOpen=true;tipElement.data(DATA_MOUSEONTOTIP,options.mouseOnToPopup);tipElement.addClass(options.popupClass);if(!options.followMouse||element.data(DATA_FORCEDOPEN)){positionTipOnElement(element);session.isFixedTipOpen=true}else{positionTipOnCursor()}if(!element.data(DATA_FORCEDOPEN)&&!options.followMouse){$document.on("click"+EVENT_NAMESPACE,function documentClick(event){var target=event.target;if(target!==element[0]){if(options.mouseOnToPopup){if(target!==tipElement[0]&&!$.contains(tipElement[0],target)){$.powerTip.hide()}}else{$.powerTip.hide()}}})}if(options.mouseOnToPopup&&!options.manual){tipElement.on("mouseenter"+EVENT_NAMESPACE,function tipMouseEnter(){if(session.activeHover){session.activeHover.data(DATA_DISPLAYCONTROLLER).cancel()}});tipElement.on("mouseleave"+EVENT_NAMESPACE,function tipMouseLeave(){if(session.activeHover){session.activeHover.data(DATA_DISPLAYCONTROLLER).hide()}})}tipElement.fadeIn(options.fadeInTime,function fadeInCallback(){if(!session.desyncTimeout){session.desyncTimeout=setInterval(closeDesyncedTip,500)}element.trigger("powerTipOpen")})}function hideTip(element){session.isClosing=true;session.isTipOpen=false;session.desyncTimeout=clearInterval(session.desyncTimeout);element.data(DATA_HASACTIVEHOVER,false);element.data(DATA_FORCEDOPEN,false);$document.off("click"+EVENT_NAMESPACE);tipElement.off(EVENT_NAMESPACE);tipElement.fadeOut(options.fadeOutTime,function fadeOutCallback(){var coords=new CSSCoordinates;session.activeHover=null;session.isClosing=false;session.isFixedTipOpen=false;tipElement.removeClass();coords.set("top",session.currentY+options.offset);coords.set("left",session.currentX+options.offset);tipElement.css(coords);element.trigger("powerTipClose")})}function positionTipOnCursor(){var tipWidth,tipHeight,coords,collisions,collisionCount;if(!session.isFixedTipOpen&&(session.isTipOpen||session.tipOpenImminent&&tipElement.data(DATA_HASMOUSEMOVE))){tipWidth=tipElement.outerWidth();tipHeight=tipElement.outerHeight();coords=new CSSCoordinates;coords.set("top",session.currentY+options.offset);coords.set("left",session.currentX+options.offset);collisions=getViewportCollisions(coords,tipWidth,tipHeight);if(collisions!==Collision.none){collisionCount=countFlags(collisions);if(collisionCount===1){if(collisions===Collision.right){coords.set("left",session.scrollLeft+session.windowWidth-tipWidth)}else if(collisions===Collision.bottom){coords.set("top",session.scrollTop+session.windowHeight-tipHeight)}}else{coords.set("left",session.currentX-tipWidth-options.offset);coords.set("top",session.currentY-tipHeight-options.offset)}}tipElement.css(coords)}}function positionTipOnElement(element){var priorityList,finalPlacement;if(options.smartPlacement||options.followMouse&&element.data(DATA_FORCEDOPEN)){priorityList=$.fn.powerTip.smartPlacementLists[options.placement];$.each(priorityList,function(idx,pos){var collisions=getViewportCollisions(placeTooltip(element,pos),tipElement.outerWidth(),tipElement.outerHeight());finalPlacement=pos;return collisions!==Collision.none})}else{placeTooltip(element,options.placement);finalPlacement=options.placement}tipElement.removeClass("w nw sw e ne se n s w se-alt sw-alt ne-alt nw-alt");tipElement.addClass(finalPlacement)}function placeTooltip(element,placement){var iterationCount=0,tipWidth,tipHeight,coords=new CSSCoordinates;coords.set("top",0);coords.set("left",0);tipElement.css(coords);do{tipWidth=tipElement.outerWidth();tipHeight=tipElement.outerHeight();coords=placementCalculator.compute(element,placement,tipWidth,tipHeight,options.offset);tipElement.css(coords)}while(++iterationCount<=5&&(tipWidth!==tipElement.outerWidth()||tipHeight!==tipElement.outerHeight()));return coords}function closeDesyncedTip(){var isDesynced=false,hasDesyncableCloseEvent=$.grep(["mouseleave","mouseout","blur","focusout"],function(eventType){return $.inArray(eventType,options.closeEvents)!==-1}).length>0;if(session.isTipOpen&&!session.isClosing&&!session.delayInProgress&&hasDesyncableCloseEvent){if(session.activeHover.data(DATA_HASACTIVEHOVER)===false||session.activeHover.is(":disabled")){isDesynced=true}else if(!isMouseOver(session.activeHover)&&!session.activeHover.is(":focus")&&!session.activeHover.data(DATA_FORCEDOPEN)){if(tipElement.data(DATA_MOUSEONTOTIP)){if(!isMouseOver(tipElement)){isDesynced=true}}else{isDesynced=true}}if(isDesynced){hideTip(session.activeHover)}}}this.showTip=beginShowTip;this.hideTip=hideTip;this.resetPosition=positionTipOnElement}function isSvgElement(element){return Boolean(window.SVGElement&&element[0]instanceof SVGElement)}function isMouseEvent(event){return Boolean(event&&$.inArray(event.type,MOUSE_EVENTS)>-1&&typeof event.pageX==="number")}function initTracking(){if(!session.mouseTrackingActive){session.mouseTrackingActive=true;getViewportDimensions();$(getViewportDimensions);$document.on("mousemove"+EVENT_NAMESPACE,trackMouse);$window.on("resize"+EVENT_NAMESPACE,trackResize);$window.on("scroll"+EVENT_NAMESPACE,trackScroll)}}function getViewportDimensions(){session.scrollLeft=$window.scrollLeft();session.scrollTop=$window.scrollTop();session.windowWidth=$window.width();session.windowHeight=$window.height()}function trackResize(){session.windowWidth=$window.width();session.windowHeight=$window.height()}function trackScroll(){var x=$window.scrollLeft(),y=$window.scrollTop();if(x!==session.scrollLeft){session.currentX+=x-session.scrollLeft;session.scrollLeft=x}if(y!==session.scrollTop){session.currentY+=y-session.scrollTop;session.scrollTop=y}}function trackMouse(event){session.currentX=event.pageX;session.currentY=event.pageY}function isMouseOver(element){var elementPosition=element.offset(),elementBox=element[0].getBoundingClientRect(),elementWidth=elementBox.right-elementBox.left,elementHeight=elementBox.bottom-elementBox.top;return session.currentX>=elementPosition.left&&session.currentX<=elementPosition.left+elementWidth&&session.currentY>=elementPosition.top&&session.currentY<=elementPosition.top+elementHeight}function getTooltipContent(element){var tipText=element.data(DATA_POWERTIP),tipObject=element.data(DATA_POWERTIPJQ),tipTarget=element.data(DATA_POWERTIPTARGET),targetElement,content;if(tipText){if($.isFunction(tipText)){tipText=tipText.call(element[0])}content=tipText}else if(tipObject){if($.isFunction(tipObject)){tipObject=tipObject.call(element[0])}if(tipObject.length>0){content=tipObject.clone(true,true)}}else if(tipTarget){targetElement=$("#"+tipTarget);if(targetElement.length>0){content=targetElement.html()}}return content}function getViewportCollisions(coords,elementWidth,elementHeight){var viewportTop=session.scrollTop,viewportLeft=session.scrollLeft,viewportBottom=viewportTop+session.windowHeight,viewportRight=viewportLeft+session.windowWidth,collisions=Collision.none;if(coords.topviewportBottom||Math.abs(coords.bottom-session.windowHeight)>viewportBottom){collisions|=Collision.bottom}if(coords.leftviewportRight){collisions|=Collision.left}if(coords.left+elementWidth>viewportRight||coords.right1)){a.preventDefault();var c=a.originalEvent.changedTouches[0],d=document.createEvent("MouseEvents");d.initMouseEvent(b,!0,!0,window,1,c.screenX,c.screenY,c.clientX,c.clientY,!1,!1,!1,!1,0,null),a.target.dispatchEvent(d)}}if(a.support.touch="ontouchend"in document,a.support.touch){var e,b=a.ui.mouse.prototype,c=b._mouseInit,d=b._mouseDestroy;b._touchStart=function(a){var b=this;!e&&b._mouseCapture(a.originalEvent.changedTouches[0])&&(e=!0,b._touchMoved=!1,f(a,"mouseover"),f(a,"mousemove"),f(a,"mousedown"))},b._touchMove=function(a){e&&(this._touchMoved=!0,f(a,"mousemove"))},b._touchEnd=function(a){e&&(f(a,"mouseup"),f(a,"mouseout"),this._touchMoved||f(a,"click"),e=!1)},b._mouseInit=function(){var b=this;b.element.bind({touchstart:a.proxy(b,"_touchStart"),touchmove:a.proxy(b,"_touchMove"),touchend:a.proxy(b,"_touchEnd")}),c.call(b)},b._mouseDestroy=function(){var b=this;b.element.unbind({touchstart:a.proxy(b,"_touchStart"),touchmove:a.proxy(b,"_touchMove"),touchend:a.proxy(b,"_touchEnd")}),d.call(b)}}}(jQuery);/*! SmartMenus jQuery Plugin - v1.1.0 - September 17, 2017 + * http://www.smartmenus.org/ + * Copyright Vasil Dinkov, Vadikom Web Ltd. http://vadikom.com; Licensed MIT */(function(t){"function"==typeof define&&define.amd?define(["jquery"],t):"object"==typeof module&&"object"==typeof module.exports?module.exports=t(require("jquery")):t(jQuery)})(function($){function initMouseDetection(t){var e=".smartmenus_mouse";if(mouseDetectionEnabled||t)mouseDetectionEnabled&&t&&($(document).off(e),mouseDetectionEnabled=!1);else{var i=!0,s=null,o={mousemove:function(t){var e={x:t.pageX,y:t.pageY,timeStamp:(new Date).getTime()};if(s){var o=Math.abs(s.x-e.x),a=Math.abs(s.y-e.y);if((o>0||a>0)&&2>=o&&2>=a&&300>=e.timeStamp-s.timeStamp&&(mouse=!0,i)){var n=$(t.target).closest("a");n.is("a")&&$.each(menuTrees,function(){return $.contains(this.$root[0],n[0])?(this.itemEnter({currentTarget:n[0]}),!1):void 0}),i=!1}}s=e}};o[touchEvents?"touchstart":"pointerover pointermove pointerout MSPointerOver MSPointerMove MSPointerOut"]=function(t){isTouchEvent(t.originalEvent)&&(mouse=!1)},$(document).on(getEventsNS(o,e)),mouseDetectionEnabled=!0}}function isTouchEvent(t){return!/^(4|mouse)$/.test(t.pointerType)}function getEventsNS(t,e){e||(e="");var i={};for(var s in t)i[s.split(" ").join(e+" ")+e]=t[s];return i}var menuTrees=[],mouse=!1,touchEvents="ontouchstart"in window,mouseDetectionEnabled=!1,requestAnimationFrame=window.requestAnimationFrame||function(t){return setTimeout(t,1e3/60)},cancelAnimationFrame=window.cancelAnimationFrame||function(t){clearTimeout(t)},canAnimate=!!$.fn.animate;return $.SmartMenus=function(t,e){this.$root=$(t),this.opts=e,this.rootId="",this.accessIdPrefix="",this.$subArrow=null,this.activatedItems=[],this.visibleSubMenus=[],this.showTimeout=0,this.hideTimeout=0,this.scrollTimeout=0,this.clickActivated=!1,this.focusActivated=!1,this.zIndexInc=0,this.idInc=0,this.$firstLink=null,this.$firstSub=null,this.disabled=!1,this.$disableOverlay=null,this.$touchScrollingSub=null,this.cssTransforms3d="perspective"in t.style||"webkitPerspective"in t.style,this.wasCollapsible=!1,this.init()},$.extend($.SmartMenus,{hideAll:function(){$.each(menuTrees,function(){this.menuHideAll()})},destroy:function(){for(;menuTrees.length;)menuTrees[0].destroy();initMouseDetection(!0)},prototype:{init:function(t){var e=this;if(!t){menuTrees.push(this),this.rootId=((new Date).getTime()+Math.random()+"").replace(/\D/g,""),this.accessIdPrefix="sm-"+this.rootId+"-",this.$root.hasClass("sm-rtl")&&(this.opts.rightToLeftSubMenus=!0);var i=".smartmenus";this.$root.data("smartmenus",this).attr("data-smartmenus-id",this.rootId).dataSM("level",1).on(getEventsNS({"mouseover focusin":$.proxy(this.rootOver,this),"mouseout focusout":$.proxy(this.rootOut,this),keydown:$.proxy(this.rootKeyDown,this)},i)).on(getEventsNS({mouseenter:$.proxy(this.itemEnter,this),mouseleave:$.proxy(this.itemLeave,this),mousedown:$.proxy(this.itemDown,this),focus:$.proxy(this.itemFocus,this),blur:$.proxy(this.itemBlur,this),click:$.proxy(this.itemClick,this)},i),"a"),i+=this.rootId,this.opts.hideOnClick&&$(document).on(getEventsNS({touchstart:$.proxy(this.docTouchStart,this),touchmove:$.proxy(this.docTouchMove,this),touchend:$.proxy(this.docTouchEnd,this),click:$.proxy(this.docClick,this)},i)),$(window).on(getEventsNS({"resize orientationchange":$.proxy(this.winResize,this)},i)),this.opts.subIndicators&&(this.$subArrow=$("").addClass("sub-arrow"),this.opts.subIndicatorsText&&this.$subArrow.html(this.opts.subIndicatorsText)),initMouseDetection()}if(this.$firstSub=this.$root.find("ul").each(function(){e.menuInit($(this))}).eq(0),this.$firstLink=this.$root.find("a").eq(0),this.opts.markCurrentItem){var s=/(index|default)\.[^#\?\/]*/i,o=/#.*/,a=window.location.href.replace(s,""),n=a.replace(o,"");this.$root.find("a").each(function(){var t=this.href.replace(s,""),i=$(this);(t==a||t==n)&&(i.addClass("current"),e.opts.markCurrentTree&&i.parentsUntil("[data-smartmenus-id]","ul").each(function(){$(this).dataSM("parent-a").addClass("current")}))})}this.wasCollapsible=this.isCollapsible()},destroy:function(t){if(!t){var e=".smartmenus";this.$root.removeData("smartmenus").removeAttr("data-smartmenus-id").removeDataSM("level").off(e),e+=this.rootId,$(document).off(e),$(window).off(e),this.opts.subIndicators&&(this.$subArrow=null)}this.menuHideAll();var i=this;this.$root.find("ul").each(function(){var t=$(this);t.dataSM("scroll-arrows")&&t.dataSM("scroll-arrows").remove(),t.dataSM("shown-before")&&((i.opts.subMenusMinWidth||i.opts.subMenusMaxWidth)&&t.css({width:"",minWidth:"",maxWidth:""}).removeClass("sm-nowrap"),t.dataSM("scroll-arrows")&&t.dataSM("scroll-arrows").remove(),t.css({zIndex:"",top:"",left:"",marginLeft:"",marginTop:"",display:""})),0==(t.attr("id")||"").indexOf(i.accessIdPrefix)&&t.removeAttr("id")}).removeDataSM("in-mega").removeDataSM("shown-before").removeDataSM("scroll-arrows").removeDataSM("parent-a").removeDataSM("level").removeDataSM("beforefirstshowfired").removeAttr("role").removeAttr("aria-hidden").removeAttr("aria-labelledby").removeAttr("aria-expanded"),this.$root.find("a.has-submenu").each(function(){var t=$(this);0==t.attr("id").indexOf(i.accessIdPrefix)&&t.removeAttr("id")}).removeClass("has-submenu").removeDataSM("sub").removeAttr("aria-haspopup").removeAttr("aria-controls").removeAttr("aria-expanded").closest("li").removeDataSM("sub"),this.opts.subIndicators&&this.$root.find("span.sub-arrow").remove(),this.opts.markCurrentItem&&this.$root.find("a.current").removeClass("current"),t||(this.$root=null,this.$firstLink=null,this.$firstSub=null,this.$disableOverlay&&(this.$disableOverlay.remove(),this.$disableOverlay=null),menuTrees.splice($.inArray(this,menuTrees),1))},disable:function(t){if(!this.disabled){if(this.menuHideAll(),!t&&!this.opts.isPopup&&this.$root.is(":visible")){var e=this.$root.offset();this.$disableOverlay=$('
').css({position:"absolute",top:e.top,left:e.left,width:this.$root.outerWidth(),height:this.$root.outerHeight(),zIndex:this.getStartZIndex(!0),opacity:0}).appendTo(document.body)}this.disabled=!0}},docClick:function(t){return this.$touchScrollingSub?(this.$touchScrollingSub=null,void 0):((this.visibleSubMenus.length&&!$.contains(this.$root[0],t.target)||$(t.target).closest("a").length)&&this.menuHideAll(),void 0)},docTouchEnd:function(){if(this.lastTouch){if(!(!this.visibleSubMenus.length||void 0!==this.lastTouch.x2&&this.lastTouch.x1!=this.lastTouch.x2||void 0!==this.lastTouch.y2&&this.lastTouch.y1!=this.lastTouch.y2||this.lastTouch.target&&$.contains(this.$root[0],this.lastTouch.target))){this.hideTimeout&&(clearTimeout(this.hideTimeout),this.hideTimeout=0);var t=this;this.hideTimeout=setTimeout(function(){t.menuHideAll()},350)}this.lastTouch=null}},docTouchMove:function(t){if(this.lastTouch){var e=t.originalEvent.touches[0];this.lastTouch.x2=e.pageX,this.lastTouch.y2=e.pageY}},docTouchStart:function(t){var e=t.originalEvent.touches[0];this.lastTouch={x1:e.pageX,y1:e.pageY,target:e.target}},enable:function(){this.disabled&&(this.$disableOverlay&&(this.$disableOverlay.remove(),this.$disableOverlay=null),this.disabled=!1)},getClosestMenu:function(t){for(var e=$(t).closest("ul");e.dataSM("in-mega");)e=e.parent().closest("ul");return e[0]||null},getHeight:function(t){return this.getOffset(t,!0)},getOffset:function(t,e){var i;"none"==t.css("display")&&(i={position:t[0].style.position,visibility:t[0].style.visibility},t.css({position:"absolute",visibility:"hidden"}).show());var s=t[0].getBoundingClientRect&&t[0].getBoundingClientRect(),o=s&&(e?s.height||s.bottom-s.top:s.width||s.right-s.left);return o||0===o||(o=e?t[0].offsetHeight:t[0].offsetWidth),i&&t.hide().css(i),o},getStartZIndex:function(t){var e=parseInt(this[t?"$root":"$firstSub"].css("z-index"));return!t&&isNaN(e)&&(e=parseInt(this.$root.css("z-index"))),isNaN(e)?1:e},getTouchPoint:function(t){return t.touches&&t.touches[0]||t.changedTouches&&t.changedTouches[0]||t},getViewport:function(t){var e=t?"Height":"Width",i=document.documentElement["client"+e],s=window["inner"+e];return s&&(i=Math.min(i,s)),i},getViewportHeight:function(){return this.getViewport(!0)},getViewportWidth:function(){return this.getViewport()},getWidth:function(t){return this.getOffset(t)},handleEvents:function(){return!this.disabled&&this.isCSSOn()},handleItemEvents:function(t){return this.handleEvents()&&!this.isLinkInMegaMenu(t)},isCollapsible:function(){return"static"==this.$firstSub.css("position")},isCSSOn:function(){return"inline"!=this.$firstLink.css("display")},isFixed:function(){var t="fixed"==this.$root.css("position");return t||this.$root.parentsUntil("body").each(function(){return"fixed"==$(this).css("position")?(t=!0,!1):void 0}),t},isLinkInMegaMenu:function(t){return $(this.getClosestMenu(t[0])).hasClass("mega-menu")},isTouchMode:function(){return!mouse||this.opts.noMouseOver||this.isCollapsible()},itemActivate:function(t,e){var i=t.closest("ul"),s=i.dataSM("level");if(s>1&&(!this.activatedItems[s-2]||this.activatedItems[s-2][0]!=i.dataSM("parent-a")[0])){var o=this;$(i.parentsUntil("[data-smartmenus-id]","ul").get().reverse()).add(i).each(function(){o.itemActivate($(this).dataSM("parent-a"))})}if((!this.isCollapsible()||e)&&this.menuHideSubMenus(this.activatedItems[s-1]&&this.activatedItems[s-1][0]==t[0]?s:s-1),this.activatedItems[s-1]=t,this.$root.triggerHandler("activate.smapi",t[0])!==!1){var a=t.dataSM("sub");a&&(this.isTouchMode()||!this.opts.showOnClick||this.clickActivated)&&this.menuShow(a)}},itemBlur:function(t){var e=$(t.currentTarget);this.handleItemEvents(e)&&this.$root.triggerHandler("blur.smapi",e[0])},itemClick:function(t){var e=$(t.currentTarget);if(this.handleItemEvents(e)){if(this.$touchScrollingSub&&this.$touchScrollingSub[0]==e.closest("ul")[0])return this.$touchScrollingSub=null,t.stopPropagation(),!1;if(this.$root.triggerHandler("click.smapi",e[0])===!1)return!1;var i=$(t.target).is(".sub-arrow"),s=e.dataSM("sub"),o=s?2==s.dataSM("level"):!1,a=this.isCollapsible(),n=/toggle$/.test(this.opts.collapsibleBehavior),r=/link$/.test(this.opts.collapsibleBehavior),h=/^accordion/.test(this.opts.collapsibleBehavior);if(s&&!s.is(":visible")){if((!r||!a||i)&&(this.opts.showOnClick&&o&&(this.clickActivated=!0),this.itemActivate(e,h),s.is(":visible")))return this.focusActivated=!0,!1}else if(a&&(n||i))return this.itemActivate(e,h),this.menuHide(s),n&&(this.focusActivated=!1),!1;return this.opts.showOnClick&&o||e.hasClass("disabled")||this.$root.triggerHandler("select.smapi",e[0])===!1?!1:void 0}},itemDown:function(t){var e=$(t.currentTarget);this.handleItemEvents(e)&&e.dataSM("mousedown",!0)},itemEnter:function(t){var e=$(t.currentTarget);if(this.handleItemEvents(e)){if(!this.isTouchMode()){this.showTimeout&&(clearTimeout(this.showTimeout),this.showTimeout=0);var i=this;this.showTimeout=setTimeout(function(){i.itemActivate(e)},this.opts.showOnClick&&1==e.closest("ul").dataSM("level")?1:this.opts.showTimeout)}this.$root.triggerHandler("mouseenter.smapi",e[0])}},itemFocus:function(t){var e=$(t.currentTarget);this.handleItemEvents(e)&&(!this.focusActivated||this.isTouchMode()&&e.dataSM("mousedown")||this.activatedItems.length&&this.activatedItems[this.activatedItems.length-1][0]==e[0]||this.itemActivate(e,!0),this.$root.triggerHandler("focus.smapi",e[0]))},itemLeave:function(t){var e=$(t.currentTarget);this.handleItemEvents(e)&&(this.isTouchMode()||(e[0].blur(),this.showTimeout&&(clearTimeout(this.showTimeout),this.showTimeout=0)),e.removeDataSM("mousedown"),this.$root.triggerHandler("mouseleave.smapi",e[0]))},menuHide:function(t){if(this.$root.triggerHandler("beforehide.smapi",t[0])!==!1&&(canAnimate&&t.stop(!0,!0),"none"!=t.css("display"))){var e=function(){t.css("z-index","")};this.isCollapsible()?canAnimate&&this.opts.collapsibleHideFunction?this.opts.collapsibleHideFunction.call(this,t,e):t.hide(this.opts.collapsibleHideDuration,e):canAnimate&&this.opts.hideFunction?this.opts.hideFunction.call(this,t,e):t.hide(this.opts.hideDuration,e),t.dataSM("scroll")&&(this.menuScrollStop(t),t.css({"touch-action":"","-ms-touch-action":"","-webkit-transform":"",transform:""}).off(".smartmenus_scroll").removeDataSM("scroll").dataSM("scroll-arrows").hide()),t.dataSM("parent-a").removeClass("highlighted").attr("aria-expanded","false"),t.attr({"aria-expanded":"false","aria-hidden":"true"});var i=t.dataSM("level");this.activatedItems.splice(i-1,1),this.visibleSubMenus.splice($.inArray(t,this.visibleSubMenus),1),this.$root.triggerHandler("hide.smapi",t[0])}},menuHideAll:function(){this.showTimeout&&(clearTimeout(this.showTimeout),this.showTimeout=0);for(var t=this.opts.isPopup?1:0,e=this.visibleSubMenus.length-1;e>=t;e--)this.menuHide(this.visibleSubMenus[e]);this.opts.isPopup&&(canAnimate&&this.$root.stop(!0,!0),this.$root.is(":visible")&&(canAnimate&&this.opts.hideFunction?this.opts.hideFunction.call(this,this.$root):this.$root.hide(this.opts.hideDuration))),this.activatedItems=[],this.visibleSubMenus=[],this.clickActivated=!1,this.focusActivated=!1,this.zIndexInc=0,this.$root.triggerHandler("hideAll.smapi")},menuHideSubMenus:function(t){for(var e=this.activatedItems.length-1;e>=t;e--){var i=this.activatedItems[e].dataSM("sub");i&&this.menuHide(i)}},menuInit:function(t){if(!t.dataSM("in-mega")){t.hasClass("mega-menu")&&t.find("ul").dataSM("in-mega",!0);for(var e=2,i=t[0];(i=i.parentNode.parentNode)!=this.$root[0];)e++;var s=t.prevAll("a").eq(-1);s.length||(s=t.prevAll().find("a").eq(-1)),s.addClass("has-submenu").dataSM("sub",t),t.dataSM("parent-a",s).dataSM("level",e).parent().dataSM("sub",t);var o=s.attr("id")||this.accessIdPrefix+ ++this.idInc,a=t.attr("id")||this.accessIdPrefix+ ++this.idInc;s.attr({id:o,"aria-haspopup":"true","aria-controls":a,"aria-expanded":"false"}),t.attr({id:a,role:"group","aria-hidden":"true","aria-labelledby":o,"aria-expanded":"false"}),this.opts.subIndicators&&s[this.opts.subIndicatorsPos](this.$subArrow.clone())}},menuPosition:function(t){var e,i,s=t.dataSM("parent-a"),o=s.closest("li"),a=o.parent(),n=t.dataSM("level"),r=this.getWidth(t),h=this.getHeight(t),u=s.offset(),l=u.left,c=u.top,d=this.getWidth(s),m=this.getHeight(s),p=$(window),f=p.scrollLeft(),v=p.scrollTop(),b=this.getViewportWidth(),S=this.getViewportHeight(),g=a.parent().is("[data-sm-horizontal-sub]")||2==n&&!a.hasClass("sm-vertical"),M=this.opts.rightToLeftSubMenus&&!o.is("[data-sm-reverse]")||!this.opts.rightToLeftSubMenus&&o.is("[data-sm-reverse]"),w=2==n?this.opts.mainMenuSubOffsetX:this.opts.subMenusSubOffsetX,T=2==n?this.opts.mainMenuSubOffsetY:this.opts.subMenusSubOffsetY;if(g?(e=M?d-r-w:w,i=this.opts.bottomToTopSubMenus?-h-T:m+T):(e=M?w-r:d-w,i=this.opts.bottomToTopSubMenus?m-T-h:T),this.opts.keepInViewport){var y=l+e,I=c+i;if(M&&f>y?e=g?f-y+e:d-w:!M&&y+r>f+b&&(e=g?f+b-r-y+e:w-r),g||(S>h&&I+h>v+S?i+=v+S-h-I:(h>=S||v>I)&&(i+=v-I)),g&&(I+h>v+S+.49||v>I)||!g&&h>S+.49){var x=this;t.dataSM("scroll-arrows")||t.dataSM("scroll-arrows",$([$('')[0],$('')[0]]).on({mouseenter:function(){t.dataSM("scroll").up=$(this).hasClass("scroll-up"),x.menuScroll(t)},mouseleave:function(e){x.menuScrollStop(t),x.menuScrollOut(t,e)},"mousewheel DOMMouseScroll":function(t){t.preventDefault()}}).insertAfter(t));var A=".smartmenus_scroll";if(t.dataSM("scroll",{y:this.cssTransforms3d?0:i-m,step:1,itemH:m,subH:h,arrowDownH:this.getHeight(t.dataSM("scroll-arrows").eq(1))}).on(getEventsNS({mouseover:function(e){x.menuScrollOver(t,e)},mouseout:function(e){x.menuScrollOut(t,e)},"mousewheel DOMMouseScroll":function(e){x.menuScrollMousewheel(t,e)}},A)).dataSM("scroll-arrows").css({top:"auto",left:"0",marginLeft:e+(parseInt(t.css("border-left-width"))||0),width:r-(parseInt(t.css("border-left-width"))||0)-(parseInt(t.css("border-right-width"))||0),zIndex:t.css("z-index")}).eq(g&&this.opts.bottomToTopSubMenus?0:1).show(),this.isFixed()){var C={};C[touchEvents?"touchstart touchmove touchend":"pointerdown pointermove pointerup MSPointerDown MSPointerMove MSPointerUp"]=function(e){x.menuScrollTouch(t,e)},t.css({"touch-action":"none","-ms-touch-action":"none"}).on(getEventsNS(C,A))}}}t.css({top:"auto",left:"0",marginLeft:e,marginTop:i-m})},menuScroll:function(t,e,i){var s,o=t.dataSM("scroll"),a=t.dataSM("scroll-arrows"),n=o.up?o.upEnd:o.downEnd;if(!e&&o.momentum){if(o.momentum*=.92,s=o.momentum,.5>s)return this.menuScrollStop(t),void 0}else s=i||(e||!this.opts.scrollAccelerate?this.opts.scrollStep:Math.floor(o.step));var r=t.dataSM("level");if(this.activatedItems[r-1]&&this.activatedItems[r-1].dataSM("sub")&&this.activatedItems[r-1].dataSM("sub").is(":visible")&&this.menuHideSubMenus(r-1),o.y=o.up&&o.y>=n||!o.up&&n>=o.y?o.y:Math.abs(n-o.y)>s?o.y+(o.up?s:-s):n,t.css(this.cssTransforms3d?{"-webkit-transform":"translate3d(0, "+o.y+"px, 0)",transform:"translate3d(0, "+o.y+"px, 0)"}:{marginTop:o.y}),mouse&&(o.up&&o.y>o.downEnd||!o.up&&o.y0;t.dataSM("scroll-arrows").eq(i?0:1).is(":visible")&&(t.dataSM("scroll").up=i,this.menuScroll(t,!0))}e.preventDefault()},menuScrollOut:function(t,e){mouse&&(/^scroll-(up|down)/.test((e.relatedTarget||"").className)||(t[0]==e.relatedTarget||$.contains(t[0],e.relatedTarget))&&this.getClosestMenu(e.relatedTarget)==t[0]||t.dataSM("scroll-arrows").css("visibility","hidden"))},menuScrollOver:function(t,e){if(mouse&&!/^scroll-(up|down)/.test(e.target.className)&&this.getClosestMenu(e.target)==t[0]){this.menuScrollRefreshData(t);var i=t.dataSM("scroll"),s=$(window).scrollTop()-t.dataSM("parent-a").offset().top-i.itemH;t.dataSM("scroll-arrows").eq(0).css("margin-top",s).end().eq(1).css("margin-top",s+this.getViewportHeight()-i.arrowDownH).end().css("visibility","visible")}},menuScrollRefreshData:function(t){var e=t.dataSM("scroll"),i=$(window).scrollTop()-t.dataSM("parent-a").offset().top-e.itemH;this.cssTransforms3d&&(i=-(parseFloat(t.css("margin-top"))-i)),$.extend(e,{upEnd:i,downEnd:i+this.getViewportHeight()-e.subH})},menuScrollStop:function(t){return this.scrollTimeout?(cancelAnimationFrame(this.scrollTimeout),this.scrollTimeout=0,t.dataSM("scroll").step=1,!0):void 0},menuScrollTouch:function(t,e){if(e=e.originalEvent,isTouchEvent(e)){var i=this.getTouchPoint(e);if(this.getClosestMenu(i.target)==t[0]){var s=t.dataSM("scroll");if(/(start|down)$/i.test(e.type))this.menuScrollStop(t)?(e.preventDefault(),this.$touchScrollingSub=t):this.$touchScrollingSub=null,this.menuScrollRefreshData(t),$.extend(s,{touchStartY:i.pageY,touchStartTime:e.timeStamp});else if(/move$/i.test(e.type)){var o=void 0!==s.touchY?s.touchY:s.touchStartY;if(void 0!==o&&o!=i.pageY){this.$touchScrollingSub=t;var a=i.pageY>o;void 0!==s.up&&s.up!=a&&$.extend(s,{touchStartY:i.pageY,touchStartTime:e.timeStamp}),$.extend(s,{up:a,touchY:i.pageY}),this.menuScroll(t,!0,Math.abs(i.pageY-o))}e.preventDefault()}else void 0!==s.touchY&&((s.momentum=15*Math.pow(Math.abs(i.pageY-s.touchStartY)/(e.timeStamp-s.touchStartTime),2))&&(this.menuScrollStop(t),this.menuScroll(t),e.preventDefault()),delete s.touchY)}}},menuShow:function(t){if((t.dataSM("beforefirstshowfired")||(t.dataSM("beforefirstshowfired",!0),this.$root.triggerHandler("beforefirstshow.smapi",t[0])!==!1))&&this.$root.triggerHandler("beforeshow.smapi",t[0])!==!1&&(t.dataSM("shown-before",!0),canAnimate&&t.stop(!0,!0),!t.is(":visible"))){var e=t.dataSM("parent-a"),i=this.isCollapsible();if((this.opts.keepHighlighted||i)&&e.addClass("highlighted"),i)t.removeClass("sm-nowrap").css({zIndex:"",width:"auto",minWidth:"",maxWidth:"",top:"",left:"",marginLeft:"",marginTop:""});else{if(t.css("z-index",this.zIndexInc=(this.zIndexInc||this.getStartZIndex())+1),(this.opts.subMenusMinWidth||this.opts.subMenusMaxWidth)&&(t.css({width:"auto",minWidth:"",maxWidth:""}).addClass("sm-nowrap"),this.opts.subMenusMinWidth&&t.css("min-width",this.opts.subMenusMinWidth),this.opts.subMenusMaxWidth)){var s=this.getWidth(t);t.css("max-width",this.opts.subMenusMaxWidth),s>this.getWidth(t)&&t.removeClass("sm-nowrap").css("width",this.opts.subMenusMaxWidth)}this.menuPosition(t)}var o=function(){t.css("overflow","")};i?canAnimate&&this.opts.collapsibleShowFunction?this.opts.collapsibleShowFunction.call(this,t,o):t.show(this.opts.collapsibleShowDuration,o):canAnimate&&this.opts.showFunction?this.opts.showFunction.call(this,t,o):t.show(this.opts.showDuration,o),e.attr("aria-expanded","true"),t.attr({"aria-expanded":"true","aria-hidden":"false"}),this.visibleSubMenus.push(t),this.$root.triggerHandler("show.smapi",t[0])}},popupHide:function(t){this.hideTimeout&&(clearTimeout(this.hideTimeout),this.hideTimeout=0);var e=this;this.hideTimeout=setTimeout(function(){e.menuHideAll()},t?1:this.opts.hideTimeout)},popupShow:function(t,e){if(!this.opts.isPopup)return alert('SmartMenus jQuery Error:\n\nIf you want to show this menu via the "popupShow" method, set the isPopup:true option.'),void 0;if(this.hideTimeout&&(clearTimeout(this.hideTimeout),this.hideTimeout=0),this.$root.dataSM("shown-before",!0),canAnimate&&this.$root.stop(!0,!0),!this.$root.is(":visible")){this.$root.css({left:t,top:e});var i=this,s=function(){i.$root.css("overflow","")};canAnimate&&this.opts.showFunction?this.opts.showFunction.call(this,this.$root,s):this.$root.show(this.opts.showDuration,s),this.visibleSubMenus[0]=this.$root}},refresh:function(){this.destroy(!0),this.init(!0)},rootKeyDown:function(t){if(this.handleEvents())switch(t.keyCode){case 27:var e=this.activatedItems[0];if(e){this.menuHideAll(),e[0].focus();var i=e.dataSM("sub");i&&this.menuHide(i)}break;case 32:var s=$(t.target);if(s.is("a")&&this.handleItemEvents(s)){var i=s.dataSM("sub");i&&!i.is(":visible")&&(this.itemClick({currentTarget:t.target}),t.preventDefault())}}},rootOut:function(t){if(this.handleEvents()&&!this.isTouchMode()&&t.target!=this.$root[0]&&(this.hideTimeout&&(clearTimeout(this.hideTimeout),this.hideTimeout=0),!this.opts.showOnClick||!this.opts.hideOnClick)){var e=this;this.hideTimeout=setTimeout(function(){e.menuHideAll()},this.opts.hideTimeout)}},rootOver:function(t){this.handleEvents()&&!this.isTouchMode()&&t.target!=this.$root[0]&&this.hideTimeout&&(clearTimeout(this.hideTimeout),this.hideTimeout=0)},winResize:function(t){if(this.handleEvents()){if(!("onorientationchange"in window)||"orientationchange"==t.type){var e=this.isCollapsible();this.wasCollapsible&&e||(this.activatedItems.length&&this.activatedItems[this.activatedItems.length-1][0].blur(),this.menuHideAll()),this.wasCollapsible=e}}else if(this.$disableOverlay){var i=this.$root.offset();this.$disableOverlay.css({top:i.top,left:i.left,width:this.$root.outerWidth(),height:this.$root.outerHeight()})}}}}),$.fn.dataSM=function(t,e){return e?this.data(t+"_smartmenus",e):this.data(t+"_smartmenus")},$.fn.removeDataSM=function(t){return this.removeData(t+"_smartmenus")},$.fn.smartmenus=function(options){if("string"==typeof options){var args=arguments,method=options;return Array.prototype.shift.call(args),this.each(function(){var t=$(this).data("smartmenus");t&&t[method]&&t[method].apply(t,args)})}return this.each(function(){var dataOpts=$(this).data("sm-options")||null;if(dataOpts)try{dataOpts=eval("("+dataOpts+")")}catch(e){dataOpts=null,alert('ERROR\n\nSmartMenus jQuery init:\nInvalid "data-sm-options" attribute value syntax.')}new $.SmartMenus(this,$.extend({},$.fn.smartmenus.defaults,options,dataOpts))})},$.fn.smartmenus.defaults={isPopup:!1,mainMenuSubOffsetX:0,mainMenuSubOffsetY:0,subMenusSubOffsetX:0,subMenusSubOffsetY:0,subMenusMinWidth:"10em",subMenusMaxWidth:"20em",subIndicators:!0,subIndicatorsPos:"append",subIndicatorsText:"",scrollStep:30,scrollAccelerate:!0,showTimeout:250,hideTimeout:500,showDuration:0,showFunction:null,hideDuration:0,hideFunction:function(t,e){t.fadeOut(200,e)},collapsibleShowDuration:0,collapsibleShowFunction:function(t,e){t.slideDown(200,e)},collapsibleHideDuration:0,collapsibleHideFunction:function(t,e){t.slideUp(200,e)},showOnClick:!1,hideOnClick:!0,noMouseOver:!1,keepInViewport:!0,keepHighlighted:!0,markCurrentItem:!1,markCurrentTree:!0,rightToLeftSubMenus:!1,bottomToTopSubMenus:!1,collapsibleBehavior:"default"},$}); \ No newline at end of file diff --git a/docs/main_8cpp.html b/docs/main_8cpp.html new file mode 100644 index 0000000..45bb8b4 --- /dev/null +++ b/docs/main_8cpp.html @@ -0,0 +1,261 @@ + + + + + + + +2 Dimensional Ising Model: src/main.cpp File Reference + + + + + + + + + + + + + + + + +
+
+ + + + + + +
+
2 Dimensional Ising Model +
+
Simulate the change in energy and magnetization in a ferro magnet
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+
+
+
+
+
Loading...
+
Searching...
+
No Matches
+
+
+
+
+ +
+ +
main.cpp File Reference
+
+
+ +

The main program. +More...

+
#include "data_type.hpp"
+#include "monte_carlo.hpp"
+#include "utils.hpp"
+#include <csignal>
+#include <cstdlib>
+#include <iostream>
+#include <omp.h>
+
+

Go to the source code of this file.

+ + + + + + + + + + + + + +

+Functions

void create_burn_in_time_data ()
 
void create_pd_estimate_data ()
 
void test_parallel_speedup ()
 
void create_phase_transition_data ()
 
int main (int argc, char **argv)
 The main function.
 
+

Detailed Description

+

The main program.

+
Author
Cory Alexander Balaton (coryab)
+
+Janita Ovidie Sandtrøen Willumsen (janitaws)
+
Version
0.1
+
Bug:
No known bugs
+ +

Definition in file main.cpp.

+

Function Documentation

+ +

◆ create_burn_in_time_data()

+ +
+
+ + + + + + + +
void create_burn_in_time_data ()
+
+ +

Definition at line 21 of file main.cpp.

+ +
+
+ +

◆ create_pd_estimate_data()

+ +
+
+ + + + + + + +
void create_pd_estimate_data ()
+
+ +

Definition at line 34 of file main.cpp.

+ +
+
+ +

◆ create_phase_transition_data()

+ +
+
+ + + + + + + +
void create_phase_transition_data ()
+
+ +

Definition at line 62 of file main.cpp.

+ +
+
+ +

◆ main()

+ +
+
+ + + + + + + + + + + + + + + + + + +
int main (int argc,
char ** argv 
)
+
+ +

The main function.

+ +

Definition at line 84 of file main.cpp.

+ +
+
+ +

◆ test_parallel_speedup()

+ +
+
+ + + + + + + +
void test_parallel_speedup ()
+
+ +

Definition at line 41 of file main.cpp.

+ +
+
+
+
+ + + + diff --git a/docs/main_8cpp.js b/docs/main_8cpp.js new file mode 100644 index 0000000..89e321a --- /dev/null +++ b/docs/main_8cpp.js @@ -0,0 +1,4 @@ +var main_8cpp = +[ + [ "main", "main_8cpp.html#a3c04138a5bfe5d72780bb7e82a18e627", null ] +]; \ No newline at end of file diff --git a/docs/main_8cpp_source.html b/docs/main_8cpp_source.html new file mode 100644 index 0000000..5a6dd8e --- /dev/null +++ b/docs/main_8cpp_source.html @@ -0,0 +1,226 @@ + + + + + + + +2 Dimensional Ising Model: src/main.cpp Source File + + + + + + + + + + + + + + + + +
+
+ + + + + + +
+
2 Dimensional Ising Model +
+
Simulate the change in energy and magnetization in a ferro magnet
+
+
+ + + + + + + +
+
+ +
+
+
+ +
+ +
+
+ + +
+
+
+
+
+
Loading...
+
Searching...
+
No Matches
+
+
+
+
+ +
+
main.cpp
+
+
+Go to the documentation of this file.
1
+
12#include "data_type.hpp"
+
13#include "monte_carlo.hpp"
+
14#include "utils.hpp"
+
15
+
16#include <csignal>
+
17#include <cstdlib>
+
18#include <iostream>
+
19#include <omp.h>
+
20
+
21void create_burn_in_time_data()
+
22{
+
23 // Test burn-in time
+
24 monte_carlo_progression(1.0, 20, 20000,
+
25 "output/burn_in_time/unordered_1_0.txt");
+
26 monte_carlo_progression(1.0, 20, 20000, 1,
+
27 "output/burn_in_time/ordered_1_0.txt");
+
28 monte_carlo_progression(2.4, 20, 20000,
+
29 "output/burn_in_time/unordered_2_4.txt");
+
30 monte_carlo_progression(2.4, 20, 20000, 1,
+
31 "output/burn_in_time/ordered_2_4.txt");
+
32}
+
33
+
34void create_pd_estimate_data()
+
35{
+
36 // Estimate pd
+
37 pd_estimate(1.0, 20, 1000000, "output/pd_estimate/estimate_1_0.txt");
+
38 pd_estimate(2.4, 20, 1000000, "output/pd_estimate/estimate_2_4.txt");
+
39}
+
40
+
41void test_parallel_speedup()
+
42{
+
43 // Test the openmp speedup
+
44 data_t data;
+
45 double t0, t1, t2;
+
46 int tries = 5;
+
47 t0 = omp_get_wtime();
+
48 for (size_t i = 0; i < tries; i++)
+
49 monte_carlo_serial(20, 1.0, 10000);
+
50 t1 = omp_get_wtime();
+
51 for (size_t i = 0; i < tries; i++)
+
52 monte_carlo_parallel(20, 1.0, 10000);
+
53 t2 = omp_get_wtime();
+
54
+
55 std::cout << "Time serial : " << (t1 - t0) / tries << " seconds"
+
56 << '\n';
+
57 std::cout << "Time parallel : " << (t2 - t1) / tries << " seconds"
+
58 << '\n';
+
59 std::cout << "Speedup parallel: " << (t1 - t0) / (t2 - t1) << '\n';
+
60}
+
61
+
62void create_phase_transition_data()
+
63{
+
64 double t0, t1;
+
65
+
66 t0 = omp_get_wtime();
+
67 // Phase transition
+
68 phase_transition(20, 2.1, 2.4, 40, monte_carlo_parallel,
+
69 "output/phase_transition/size_20.txt");
+
70 phase_transition(40, 2.1, 2.4, 40, monte_carlo_parallel,
+
71 "output/phase_transition/size_40.txt");
+
72 phase_transition(60, 2.1, 2.4, 40, monte_carlo_parallel,
+
73 "output/phase_transition/size_60.txt");
+
74 phase_transition(80, 2.1, 2.4, 40, monte_carlo_parallel,
+
75 "output/phase_transition/size_80.txt");
+
76 phase_transition(100, 2.1, 2.4, 40, monte_carlo_parallel,
+
77 "output/phase_transition/size_100.txt");
+
78 t1 = omp_get_wtime();
+
79
+
80 std::cout << "Time: " << t1 - t0 << std::endl;
+
81}
+
82
+
84int main(int argc, char **argv)
+
85{
+
86 if (argc < 2) {
+
87 std::cout << "Need at least 1 argument, got " << argc - 1
+
88 << " arguments." << std::endl;
+
89 abort();
+
90 }
+
91
+
92 int arg = atoi(argv[1]);
+
93
+
94 switch (arg) {
+
95 case 1:
+
96 create_burn_in_time_data();
+
97 break;
+
98 case 2:
+
99 create_pd_estimate_data();
+
100 break;
+
101 case 3:
+
102 test_parallel_speedup();
+
103 break;
+
104 case 4:
+
105 create_phase_transition_data();
+
106 break;
+
107 default:
+
108 std::cout << "Not a valid option!" << std::endl;
+
109 abort();
+
110 }
+
111
+
112 return 0;
+
113}
+ +
Header for the data_t type.
+
Functions for monte carlo simulations.
+
void phase_transition(int L, double start_T, double end_T, int points_T, std::function< data_t(int, double, int)> monte_carlo, std::string outfile)
Perform the MCMC algorithm using a range of temperatures.
+
data_t monte_carlo_serial(int L, double T, int cycles)
Execute the Metropolis algorithm for a certain amount of Monte Carlo cycles.
+
void pd_estimate(double T, int L, int cycles, const std::string filename)
Estimate the probability distribution for the energy.
Definition: monte_carlo.cpp:85
+
void monte_carlo_progression(double T, int L, int cycles, const std::string filename)
Write the expected values for each Monte Carlo cycles to file.
Definition: monte_carlo.cpp:17
+
data_t monte_carlo_parallel(int L, double T, int cycles)
Execute the Metropolis algorithm for a certain amount of Monte Carlo cycles in parallel.
+
int main()
The main function.
Definition: test_suite.cpp:148
+
Function prototypes and macros that are useful.
+
+
+ + + + diff --git a/docs/menu.js b/docs/menu.js new file mode 100644 index 0000000..b0b2693 --- /dev/null +++ b/docs/menu.js @@ -0,0 +1,136 @@ +/* + @licstart The following is the entire license notice for the JavaScript code in this file. + + The MIT License (MIT) + + Copyright (C) 1997-2020 by Dimitri van Heesch + + Permission is hereby granted, free of charge, to any person obtaining a copy of this software + and associated documentation files (the "Software"), to deal in the Software without restriction, + including without limitation the rights to use, copy, modify, merge, publish, distribute, + sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is + furnished to do so, subject to the following conditions: + + The above copyright notice and this permission notice shall be included in all copies or + substantial portions of the Software. + + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING + BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND + NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, + DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + + @licend The above is the entire license notice for the JavaScript code in this file + */ +function initMenu(relPath,searchEnabled,serverSide,searchPage,search) { + function makeTree(data,relPath) { + var result=''; + if ('children' in data) { + result+='
    '; + for (var i in data.children) { + var url; + var link; + link = data.children[i].url; + if (link.substring(0,1)=='^') { + url = link.substring(1); + } else { + url = relPath+link; + } + result+='
  • '+ + data.children[i].text+''+ + makeTree(data.children[i],relPath)+'
  • '; + } + result+='
'; + } + return result; + } + var searchBoxHtml; + if (searchEnabled) { + if (serverSide) { + searchBoxHtml='
'+ + '
'+ + '
 '+ + ''+ + '
'+ + '
'+ + '
'+ + '
'; + } else { + searchBoxHtml='
'+ + ''+ + ' '+ + ''+ + ''+ + ''+ + ''+ + ''+ + '
'; + } + } + + $('#main-nav').before('
'+ + ''+ + ''+ + '
'); + $('#main-nav').append(makeTree(menudata,relPath)); + $('#main-nav').children(':first').addClass('sm sm-dox').attr('id','main-menu'); + if (searchBoxHtml) { + $('#main-menu').append('
  • '); + } + var $mainMenuState = $('#main-menu-state'); + var prevWidth = 0; + if ($mainMenuState.length) { + function initResizableIfExists() { + if (typeof initResizable==='function') initResizable(); + } + // animate mobile menu + $mainMenuState.change(function(e) { + var $menu = $('#main-menu'); + var options = { duration: 250, step: initResizableIfExists }; + if (this.checked) { + options['complete'] = function() { $menu.css('display', 'block') }; + $menu.hide().slideDown(options); + } else { + options['complete'] = function() { $menu.css('display', 'none') }; + $menu.show().slideUp(options); + } + }); + // set default menu visibility + function resetState() { + var $menu = $('#main-menu'); + var $mainMenuState = $('#main-menu-state'); + var newWidth = $(window).outerWidth(); + if (newWidth!=prevWidth) { + if ($(window).outerWidth()<768) { + $mainMenuState.prop('checked',false); $menu.hide(); + $('#searchBoxPos1').html(searchBoxHtml); + $('#searchBoxPos2').hide(); + } else { + $menu.show(); + $('#searchBoxPos1').empty(); + $('#searchBoxPos2').html(searchBoxHtml); + $('#searchBoxPos2').show(); + } + if (typeof searchBox!=='undefined') { + searchBox.CloseResultsWindow(); + } + prevWidth = newWidth; + } + } + $(window).ready(function() { resetState(); initResizableIfExists(); }); + $(window).resize(resetState); + } + $('#main-menu').smartmenus(); +} +/* @license-end */ diff --git a/docs/menudata.js b/docs/menudata.js new file mode 100644 index 0000000..64b7dfd --- /dev/null +++ b/docs/menudata.js @@ -0,0 +1,40 @@ +/* + @licstart The following is the entire license notice for the JavaScript code in this file. + + The MIT License (MIT) + + Copyright (C) 1997-2020 by Dimitri van Heesch + + Permission is hereby granted, free of charge, to any person obtaining a copy of this software + and associated documentation files (the "Software"), to deal in the Software without restriction, + including without limitation the rights to use, copy, modify, merge, publish, distribute, + sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is + furnished to do so, subject to the following conditions: + + The above copyright notice and this permission notice shall be included in all copies or + substantial portions of the Software. + + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING + BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND + NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, + DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + + @licend The above is the entire license notice for the JavaScript code in this file +*/ +var menudata={children:[ +{text:"Main Page",url:"index.html"}, +{text:"Related Pages",url:"pages.html"}, +{text:"Classes",url:"annotated.html",children:[ +{text:"Class List",url:"annotated.html"}, +{text:"Class Index",url:"classes.html"}, +{text:"Class Members",url:"functions.html",children:[ +{text:"All",url:"functions.html"}, +{text:"Functions",url:"functions_func.html"}, +{text:"Variables",url:"functions_vars.html"}]}]}, +{text:"Files",url:"files.html",children:[ +{text:"File List",url:"files.html"}, +{text:"File Members",url:"globals.html",children:[ +{text:"All",url:"globals.html"}, +{text:"Functions",url:"globals_func.html"}, +{text:"Macros",url:"globals_defs.html"}]}]}]} diff --git a/docs/monte__carlo_8cpp.html b/docs/monte__carlo_8cpp.html new file mode 100644 index 0000000..f0385af --- /dev/null +++ b/docs/monte__carlo_8cpp.html @@ -0,0 +1,483 @@ + + + + + + + +2 Dimensional Ising Model: src/monte_carlo.cpp File Reference + + + + + + + + + + + + + + + + +
    +
    + + + + + + +
    +
    2 Dimensional Ising Model +
    +
    Simulate the change in energy and magnetization in a ferro magnet
    +
    +
    + + + + + + + +
    +
    + +
    +
    +
    + +
    + +
    +
    + + +
    +
    +
    +
    +
    +
    Loading...
    +
    Searching...
    +
    No Matches
    +
    +
    +
    +
    + +
    + +
    monte_carlo.cpp File Reference
    +
    +
    + +

    Implementation of the monte carlo functions. +More...

    +
    #include "monte_carlo.hpp"
    +#include <cmath>
    +#include <cstdint>
    +
    +

    Go to the source code of this file.

    + + + + + + + + + + + + + + + + + + + + +

    +Functions

    void monte_carlo_progression (double T, int L, int cycles, const std::string filename)
     Write the expected values for each Monte Carlo cycles to file.
     
    void monte_carlo_progression (double T, int L, int cycles, int value, const std::string filename)
     Write the expected values for each Monte Carlo cycles to file.
     
    void pd_estimate (double T, int L, int cycles, const std::string filename)
     Estimate the probability distribution for the energy.
     
    data_t monte_carlo_serial (int L, double T, int cycles)
     Execute the Metropolis algorithm for a certain amount of Monte Carlo cycles.
     
    data_t monte_carlo_parallel (int L, double T, int cycles)
     Execute the Metropolis algorithm for a certain amount of Monte Carlo cycles in parallel.
     
    void phase_transition (int L, double start, double end, int points, std::function< data_t(int, double, int)> monte_carlo, std::string outfile)
     Perform the MCMC algorithm using a range of temperatures.
     
    +

    Detailed Description

    +

    Implementation of the monte carlo functions.

    +
    Author
    Cory Alexander Balaton (coryab)
    +
    +Janita Ovidie Sandtrøen Willumsen (janitaws)
    +
    Version
    1.0
    +
    Bug:
    No known bugs
    + +

    Definition in file monte_carlo.cpp.

    +

    Function Documentation

    + +

    ◆ monte_carlo_parallel()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    data_t monte_carlo_parallel (int L,
    double T,
    int cycles 
    )
    +
    + +

    Execute the Metropolis algorithm for a certain amount of Monte Carlo cycles in parallel.

    +
    Parameters
    + + + + +
    LThe size of the lattice
    TThe Temperature for the Ising model
    cyclesThe amount of Monte Carlo cycles to do
    +
    +
    +
    Returns
    data_t
    + +

    Definition at line 128 of file monte_carlo.cpp.

    + +
    +
    + +

    ◆ monte_carlo_progression() [1/2]

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    void monte_carlo_progression (double T,
    int L,
    int cycles,
    const std::string filename 
    )
    +
    + +

    Write the expected values for each Monte Carlo cycles to file.

    +
    Parameters
    + + + + + +
    TTemperature
    LThe size of the lattice
    cyclesThe amount of Monte Carlo cycles to do
    filenameThe file to write to
    +
    +
    + +

    Definition at line 17 of file monte_carlo.cpp.

    + +
    +
    + +

    ◆ monte_carlo_progression() [2/2]

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    void monte_carlo_progression (double T,
    int L,
    int cycles,
    int value,
    const std::string filename 
    )
    +
    + +

    Write the expected values for each Monte Carlo cycles to file.

    +
    Parameters
    + + + + + + +
    TTemperature
    LThe size of the lattice
    cyclesThe amount of Monte Carlo cycles to do
    valueThe value to set the elements in the lattice
    filenameThe file to write to
    +
    +
    + +

    Definition at line 51 of file monte_carlo.cpp.

    + +
    +
    + +

    ◆ monte_carlo_serial()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    data_t monte_carlo_serial (int L,
    double T,
    int cycles 
    )
    +
    + +

    Execute the Metropolis algorithm for a certain amount of Monte Carlo cycles.

    +
    Parameters
    + + + + +
    LThe size of the lattice
    TThe Temperature for the Ising model
    cyclesThe amount of Monte Carlo cycles to do
    +
    +
    +
    Returns
    data_t
    + +

    Definition at line 111 of file monte_carlo.cpp.

    + +
    +
    + +

    ◆ pd_estimate()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    void pd_estimate (double T,
    int L,
    int cycles,
    const std::string filename 
    )
    +
    + +

    Estimate the probability distribution for the energy.

    +
    Parameters
    + + + + + +
    TThe temperature of the Ising model
    LThe size of the lattice
    cyclesThe amount of Monte Carlo cycles to do
    filenameThe file to write to
    +
    +
    + +

    Definition at line 85 of file monte_carlo.cpp.

    + +
    +
    + +

    ◆ phase_transition()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    void phase_transition (int L,
    double start_T,
    double end_T,
    int points_T,
    std::function< data_t(int, double, int)> monte_carlo,
    std::string outfile 
    )
    +
    + +

    Perform the MCMC algorithm using a range of temperatures.

    +
    Parameters
    + + + + + + + +
    LThe size of the lattice
    start_TThe start temperature
    end_TThe end temperature
    point_TThe amount of point to measure
    monte_carloWhich Monte Carlo implementation to use
    outfileThe file to write the data to
    +
    +
    + +

    Definition at line 156 of file monte_carlo.cpp.

    + +
    +
    +
    +
    + + + + diff --git a/docs/monte__carlo_8cpp.js b/docs/monte__carlo_8cpp.js new file mode 100644 index 0000000..f43bc7d --- /dev/null +++ b/docs/monte__carlo_8cpp.js @@ -0,0 +1,9 @@ +var monte__carlo_8cpp = +[ + [ "monte_carlo_parallel", "monte__carlo_8cpp.html#acc34e2049a5030874f6f548f3adab958", null ], + [ "monte_carlo_progression", "monte__carlo_8cpp.html#ac97d0de27f2f0d50fc6ecf3a79f32826", null ], + [ "monte_carlo_progression", "monte__carlo_8cpp.html#a89ddd777796c65eb2b289af11fc0ce09", null ], + [ "monte_carlo_serial", "monte__carlo_8cpp.html#a8f8d4c5e032ed8565a3ac518b32c6aed", null ], + [ "pd_estimate", "monte__carlo_8cpp.html#a962f704ab35208bf6541eb3b707a9559", null ], + [ "phase_transition", "monte__carlo_8cpp.html#a7df22ace588b4d229d1029ce766d0009", null ] +]; \ No newline at end of file diff --git a/docs/monte__carlo_8cpp_source.html b/docs/monte__carlo_8cpp_source.html new file mode 100644 index 0000000..801427d --- /dev/null +++ b/docs/monte__carlo_8cpp_source.html @@ -0,0 +1,299 @@ + + + + + + + +2 Dimensional Ising Model: src/monte_carlo.cpp Source File + + + + + + + + + + + + + + + + +
    +
    + + + + + + +
    +
    2 Dimensional Ising Model +
    +
    Simulate the change in energy and magnetization in a ferro magnet
    +
    +
    + + + + + + + +
    +
    + +
    +
    +
    + +
    + +
    +
    + + +
    +
    +
    +
    +
    +
    Loading...
    +
    Searching...
    +
    No Matches
    +
    +
    +
    +
    + +
    +
    monte_carlo.cpp
    +
    +
    +Go to the documentation of this file.
    1
    +
    12#include "monte_carlo.hpp"
    +
    13
    +
    14#include <cmath>
    +
    15#include <cstdint>
    +
    16
    +
    17void monte_carlo_progression(double T, int L, int cycles,
    +
    18 const std::string filename)
    +
    19{
    +
    20 // Set some variables
    +
    21 data_t data, tmp;
    +
    22 int n_spins = L * L;
    +
    23
    +
    24 // File stuff
    +
    25 std::string directory = utils::dirname(filename);
    +
    26 std::ofstream ofile;
    +
    27
    +
    28 // Create random engine using the mersenne twister
    +
    29 std::random_device rd;
    +
    30 uint32_t rd_sample = rd();
    +
    31 std::mt19937 engine(rd_sample);
    +
    32
    +
    33 std::cout << "Seed: " << rd_sample << std::endl;
    +
    34
    +
    35 IsingModel ising(L, T);
    +
    36
    +
    37 // Create path and open file
    +
    38 utils::mkpath(directory);
    +
    39 ofile.open(filename);
    +
    40
    +
    41 // Loop through cycles
    +
    42 for (size_t i = 1; i <= cycles; i++) {
    +
    43 data += ising.Metropolis();
    +
    44 tmp = data / (i * n_spins);
    +
    45 ofile << i << ',' << tmp.E << ',' << tmp.E2 << ',' << tmp.M << ','
    +
    46 << tmp.M2 << ',' << tmp.M_abs << '\n';
    +
    47 }
    +
    48 ofile.close();
    +
    49}
    +
    50
    +
    51void monte_carlo_progression(double T, int L, int cycles, int value,
    +
    52 const std::string filename)
    +
    53{
    +
    54 // Set some variables
    +
    55 data_t data, tmp;
    +
    56 int n_spins = L * L;
    +
    57
    +
    58 // File stuff
    +
    59 std::string directory = utils::dirname(filename);
    +
    60 std::ofstream ofile;
    +
    61
    +
    62 // Create random engine using the mersenne twister
    +
    63 std::random_device rd;
    +
    64 uint32_t rd_sample = rd();
    +
    65 std::mt19937 engine(rd());
    +
    66
    +
    67 std::cout << "Seed: " << rd_sample << std::endl;
    +
    68
    +
    69 IsingModel ising(L, T, value);
    +
    70
    +
    71 // Create path and open file
    +
    72 utils::mkpath(directory);
    +
    73 ofile.open(filename);
    +
    74
    +
    75 // Loop through cycles
    +
    76 for (size_t i = 1; i <= cycles; i++) {
    +
    77 data += ising.Metropolis();
    +
    78 tmp = data / (i * n_spins);
    +
    79 ofile << i << ',' << tmp.E << ',' << tmp.E2 << ',' << tmp.M << ','
    +
    80 << tmp.M2 << ',' << tmp.M_abs << '\n';
    +
    81 }
    +
    82 ofile.close();
    +
    83}
    +
    84
    +
    85void pd_estimate(double T, int L, int cycles, const std::string filename)
    +
    86{
    +
    87 // Set some variables
    +
    88 data_t data, tmp;
    +
    89 int n_spins = L * L;
    +
    90
    +
    91 // File stuff
    +
    92 std::string directory = utils::dirname(filename);
    +
    93 std::ofstream ofile;
    +
    94
    +
    95 IsingModel ising(L, T);
    +
    96
    +
    97 // Create path and open file
    +
    98 utils::mkpath(directory);
    +
    99 ofile.open(filename);
    +
    100
    +
    101 // Loop through cycles
    +
    102 for (size_t i = 1; i <= cycles; i++) {
    +
    103 data = ising.Metropolis() / n_spins;
    +
    104 ofile << data.E << ',' << data.E2 << ',' << data.M << ',' << data.M2
    +
    105 << ',' << data.M_abs << '\n';
    +
    106 }
    +
    107 ofile.close();
    +
    108}
    +
    109
    +
    110// Code for seeing phase transitions.
    +
    111data_t monte_carlo_serial(int L, double T, int cycles)
    +
    112{
    +
    113 data_t data;
    +
    114 IsingModel model(L, T);
    +
    115
    +
    116 for (size_t i = 0; i < BURN_IN_TIME; i++) {
    +
    117 model.Metropolis();
    +
    118 }
    +
    119
    +
    120 double E, M;
    +
    121 for (size_t i = 0; i < (uint)cycles; i++) {
    +
    122 data += model.Metropolis();
    +
    123 }
    +
    124
    +
    125 return data;
    +
    126}
    +
    127
    +
    128data_t monte_carlo_parallel(int L, double T, int cycles)
    +
    129{
    +
    130 data_t data;
    +
    131#pragma omp parallel
    +
    132 {
    +
    133 // Each thread creates an instance of IsingModel.
    +
    134 IsingModel model(L, T);
    +
    135
    +
    136 // Each thread runs the Metropolis algorithm before starting to collect
    +
    137 // samples
    +
    138 for (size_t i = 0; i < BURN_IN_TIME; i++) {
    +
    139 model.Metropolis();
    +
    140 }
    +
    141
    +
    142 // Now each thread work on one loop together, but using their own
    +
    143 // instances of things, but the total of cycles add up.
    +
    144 // static ensure that each thread gets the same amount of iterations
    +
    145#pragma omp for schedule(static) reduction(+ : data)
    +
    146 for (size_t i = 0; i < (uint)cycles; i++) {
    +
    147 data += model.Metropolis();
    +
    148 }
    +
    149 }
    +
    150
    +
    151 double norm = 1. / (double)cycles;
    +
    152
    +
    153 return data * norm;
    +
    154}
    +
    155
    +
    156void phase_transition(int L, double start, double end, int points,
    +
    157 std::function<data_t(int, double, int)> monte_carlo,
    +
    158 std::string outfile)
    +
    159{
    +
    160 double dt = (end - start) / (double)points;
    +
    161 int cycles = 10000;
    +
    162 int N = L * L;
    +
    163 std::ofstream ofile;
    +
    164
    +
    165 data_t data;
    +
    166
    +
    167 utils::mkpath(utils::dirname(outfile));
    +
    168 ofile.open(outfile);
    +
    169
    +
    170 double temp, CV, X, E_var, M_var;
    +
    171
    +
    172 using utils::scientific_format;
    +
    173 for (size_t i = 0; i < points; i++) {
    +
    174 temp = start + dt * i;
    +
    175 data = monte_carlo(L, temp, cycles);
    +
    176 E_var = (data.E2 - data.E * data.E) / (double)N;
    +
    177 M_var = (data.M2 - data.M_abs * data.M_abs) / (double)N;
    +
    178
    +
    179 ofile << scientific_format(temp) << ','
    +
    180 << scientific_format(data.E / (double)N) << ','
    +
    181 << scientific_format(data.M_abs / N) << ','
    +
    182 << scientific_format(E_var / (temp * temp)) << ','
    +
    183 << scientific_format(M_var / temp) << '\n';
    +
    184 }
    +
    185 ofile.close();
    +
    186}
    +
    The Ising model in 2 dimensions.
    Definition: IsingModel.hpp:37
    +
    data_t Metropolis()
    The Metropolis algorithm.
    Definition: IsingModel.cpp:96
    + +
    data_t monte_carlo_serial(int L, double T, int cycles)
    Execute the Metropolis algorithm for a certain amount of Monte Carlo cycles.
    +
    void monte_carlo_progression(double T, int L, int cycles, const std::string filename)
    Write the expected values for each Monte Carlo cycles to file.
    Definition: monte_carlo.cpp:17
    +
    data_t monte_carlo_parallel(int L, double T, int cycles)
    Execute the Metropolis algorithm for a certain amount of Monte Carlo cycles in parallel.
    +
    Functions for monte carlo simulations.
    +
    void phase_transition(int L, double start_T, double end_T, int points_T, std::function< data_t(int, double, int)> monte_carlo, std::string outfile)
    Perform the MCMC algorithm using a range of temperatures.
    +
    void pd_estimate(double T, int L, int cycles, const std::string filename)
    Estimate the probability distribution for the energy.
    Definition: monte_carlo.cpp:85
    +
    +
    + + + + diff --git a/docs/monte__carlo_8hpp.html b/docs/monte__carlo_8hpp.html new file mode 100644 index 0000000..698a623 --- /dev/null +++ b/docs/monte__carlo_8hpp.html @@ -0,0 +1,550 @@ + + + + + + + +2 Dimensional Ising Model: include/monte_carlo.hpp File Reference + + + + + + + + + + + + + + + + +
    +
    + + + + + + +
    +
    2 Dimensional Ising Model +
    +
    Simulate the change in energy and magnetization in a ferro magnet
    +
    +
    + + + + + + + +
    +
    + +
    +
    +
    + +
    + +
    +
    + + +
    +
    +
    +
    +
    +
    Loading...
    +
    Searching...
    +
    No Matches
    +
    +
    +
    +
    + +
    + +
    monte_carlo.hpp File Reference
    +
    +
    + +

    Functions for monte carlo simulations. +More...

    +
    #include "IsingModel.hpp"
    +#include "data_type.hpp"
    +#include "utils.hpp"
    +#include <functional>
    +#include <string>
    +#include <omp.h>
    +
    +

    Go to the source code of this file.

    + + + + +

    +Macros

    #define BURN_IN_TIME   5000
     
    + + + + + + + + + + + + + + + + + + + + + + +

    +Functions

    int test_2x2_lattice (double tol, int max_cycles)
     Test numerical data with analytical data.
     
    void monte_carlo_progression (double T, int L, int cycles, const std::string filename)
     Write the expected values for each Monte Carlo cycles to file.
     
    void monte_carlo_progression (double T, int L, int cycles, int value, const std::string filename)
     Write the expected values for each Monte Carlo cycles to file.
     
    void pd_estimate (double T, int L, int cycles, const std::string filename)
     Estimate the probability distribution for the energy.
     
    data_t monte_carlo_serial (int L, double T, int cycles)
     Execute the Metropolis algorithm for a certain amount of Monte Carlo cycles.
     
    data_t monte_carlo_parallel (int L, double T, int cycles)
     Execute the Metropolis algorithm for a certain amount of Monte Carlo cycles in parallel.
     
    void phase_transition (int L, double start_T, double end_T, int points_T, std::function< data_t(int, double, int)> monte_carlo, std::string outfile)
     Perform the MCMC algorithm using a range of temperatures.
     
    +

    Detailed Description

    +

    Functions for monte carlo simulations.

    +
    Author
    Cory Alexander Balaton (coryab)
    +
    +Janita Ovidie Sandtrøen Willumsen (janitaws)
    +
    Version
    1.0
    +
    Bug:
    No known bugs
    + +

    Definition in file monte_carlo.hpp.

    +

    Macro Definition Documentation

    + +

    ◆ BURN_IN_TIME

    + +
    +
    + + + + +
    #define BURN_IN_TIME   5000
    +
    + +

    Definition at line 24 of file monte_carlo.hpp.

    + +
    +
    +

    Function Documentation

    + +

    ◆ monte_carlo_parallel()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    data_t monte_carlo_parallel (int L,
    double T,
    int cycles 
    )
    +
    + +

    Execute the Metropolis algorithm for a certain amount of Monte Carlo cycles in parallel.

    +
    Parameters
    + + + + +
    LThe size of the lattice
    TThe Temperature for the Ising model
    cyclesThe amount of Monte Carlo cycles to do
    +
    +
    +
    Returns
    data_t
    + +

    Definition at line 128 of file monte_carlo.cpp.

    + +
    +
    + +

    ◆ monte_carlo_progression() [1/2]

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    void monte_carlo_progression (double T,
    int L,
    int cycles,
    const std::string filename 
    )
    +
    + +

    Write the expected values for each Monte Carlo cycles to file.

    +
    Parameters
    + + + + + +
    TTemperature
    LThe size of the lattice
    cyclesThe amount of Monte Carlo cycles to do
    filenameThe file to write to
    +
    +
    + +

    Definition at line 17 of file monte_carlo.cpp.

    + +
    +
    + +

    ◆ monte_carlo_progression() [2/2]

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    void monte_carlo_progression (double T,
    int L,
    int cycles,
    int value,
    const std::string filename 
    )
    +
    + +

    Write the expected values for each Monte Carlo cycles to file.

    +
    Parameters
    + + + + + + +
    TTemperature
    LThe size of the lattice
    cyclesThe amount of Monte Carlo cycles to do
    valueThe value to set the elements in the lattice
    filenameThe file to write to
    +
    +
    + +

    Definition at line 51 of file monte_carlo.cpp.

    + +
    +
    + +

    ◆ monte_carlo_serial()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    data_t monte_carlo_serial (int L,
    double T,
    int cycles 
    )
    +
    + +

    Execute the Metropolis algorithm for a certain amount of Monte Carlo cycles.

    +
    Parameters
    + + + + +
    LThe size of the lattice
    TThe Temperature for the Ising model
    cyclesThe amount of Monte Carlo cycles to do
    +
    +
    +
    Returns
    data_t
    + +

    Definition at line 111 of file monte_carlo.cpp.

    + +
    +
    + +

    ◆ pd_estimate()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    void pd_estimate (double T,
    int L,
    int cycles,
    const std::string filename 
    )
    +
    + +

    Estimate the probability distribution for the energy.

    +
    Parameters
    + + + + + +
    TThe temperature of the Ising model
    LThe size of the lattice
    cyclesThe amount of Monte Carlo cycles to do
    filenameThe file to write to
    +
    +
    + +

    Definition at line 85 of file monte_carlo.cpp.

    + +
    +
    + +

    ◆ phase_transition()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    void phase_transition (int L,
    double start_T,
    double end_T,
    int points_T,
    std::function< data_t(int, double, int)> monte_carlo,
    std::string outfile 
    )
    +
    + +

    Perform the MCMC algorithm using a range of temperatures.

    +
    Parameters
    + + + + + + + +
    LThe size of the lattice
    start_TThe start temperature
    end_TThe end temperature
    point_TThe amount of point to measure
    monte_carloWhich Monte Carlo implementation to use
    outfileThe file to write the data to
    +
    +
    + +

    Definition at line 156 of file monte_carlo.cpp.

    + +
    +
    + +

    ◆ test_2x2_lattice()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    int test_2x2_lattice (double tol,
    int max_cycles 
    )
    +
    + +

    Test numerical data with analytical data.

    +
    Parameters
    + + + +
    tolThe tolerance between the analytical and numerical solution.
    max_cyclesThe max number of Monte Carlo cycles.
    +
    +
    +

    return int

    + +
    +
    +
    +
    + + + + diff --git a/docs/monte__carlo_8hpp.js b/docs/monte__carlo_8hpp.js new file mode 100644 index 0000000..800643a --- /dev/null +++ b/docs/monte__carlo_8hpp.js @@ -0,0 +1,10 @@ +var monte__carlo_8hpp = +[ + [ "monte_carlo_parallel", "monte__carlo_8hpp.html#acc34e2049a5030874f6f548f3adab958", null ], + [ "monte_carlo_progression", "monte__carlo_8hpp.html#ac97d0de27f2f0d50fc6ecf3a79f32826", null ], + [ "monte_carlo_progression", "monte__carlo_8hpp.html#a89ddd777796c65eb2b289af11fc0ce09", null ], + [ "monte_carlo_serial", "monte__carlo_8hpp.html#a8f8d4c5e032ed8565a3ac518b32c6aed", null ], + [ "pd_estimate", "monte__carlo_8hpp.html#a962f704ab35208bf6541eb3b707a9559", null ], + [ "phase_transition", "monte__carlo_8hpp.html#a2dfe843fbb80e10a763f3260131a148e", null ], + [ "test_2x2_lattice", "monte__carlo_8hpp.html#aa8b4fc86b26f0e3e253ba5556d2d14dc", null ] +]; \ No newline at end of file diff --git a/docs/monte__carlo_8hpp_source.html b/docs/monte__carlo_8hpp_source.html new file mode 100644 index 0000000..feae31e --- /dev/null +++ b/docs/monte__carlo_8hpp_source.html @@ -0,0 +1,161 @@ + + + + + + + +2 Dimensional Ising Model: include/monte_carlo.hpp Source File + + + + + + + + + + + + + + + + +
    +
    + + + + + + +
    +
    2 Dimensional Ising Model +
    +
    Simulate the change in energy and magnetization in a ferro magnet
    +
    +
    + + + + + + + +
    +
    + +
    +
    +
    + +
    + +
    +
    + + +
    +
    +
    +
    +
    +
    Loading...
    +
    Searching...
    +
    No Matches
    +
    +
    +
    +
    + +
    +
    monte_carlo.hpp
    +
    +
    +Go to the documentation of this file.
    1
    +
    12#ifndef __MONTE_CARLO__
    +
    13#define __MONTE_CARLO__
    +
    14
    +
    15#include "IsingModel.hpp"
    +
    16#include "data_type.hpp"
    +
    17#include "utils.hpp"
    +
    18
    +
    19#include <functional>
    +
    20#include <string>
    +
    21#include <omp.h>
    +
    22
    +
    23//#define BURN_IN_TIME 12500
    +
    24#define BURN_IN_TIME 5000
    +
    25
    +
    26#pragma omp declare reduction(+: data_t: omp_out += omp_in)
    +
    27
    +
    35int test_2x2_lattice(double tol, int max_cycles);
    +
    36
    +
    44void monte_carlo_progression(double T, int L, int cycles,
    +
    45 const std::string filename);
    +
    46
    +
    55void monte_carlo_progression(double T, int L, int cycles, int value,
    +
    56 const std::string filename);
    +
    57
    +
    65void pd_estimate(double T, int L, int cycles, const std::string filename);
    +
    66
    +
    76data_t monte_carlo_serial(int L, double T, int cycles);
    +
    77
    +
    87data_t monte_carlo_parallel(int L, double T, int cycles);
    +
    88
    + +
    99 int L, double start_T, double end_T, int points_T,
    +
    100 std::function<data_t(int, double, int)> monte_carlo,
    +
    101 std::string outfile);
    +
    102
    +
    103#endif
    +
    The definition of the Ising model.
    + +
    Header for the data_t type.
    +
    void phase_transition(int L, double start_T, double end_T, int points_T, std::function< data_t(int, double, int)> monte_carlo, std::string outfile)
    Perform the MCMC algorithm using a range of temperatures.
    +
    data_t monte_carlo_serial(int L, double T, int cycles)
    Execute the Metropolis algorithm for a certain amount of Monte Carlo cycles.
    +
    void pd_estimate(double T, int L, int cycles, const std::string filename)
    Estimate the probability distribution for the energy.
    Definition: monte_carlo.cpp:85
    +
    int test_2x2_lattice(double tol, int max_cycles)
    Test numerical data with analytical data.
    +
    void monte_carlo_progression(double T, int L, int cycles, const std::string filename)
    Write the expected values for each Monte Carlo cycles to file.
    Definition: monte_carlo.cpp:17
    +
    data_t monte_carlo_parallel(int L, double T, int cycles)
    Execute the Metropolis algorithm for a certain amount of Monte Carlo cycles in parallel.
    +
    Function prototypes and macros that are useful.
    +
    +
    + + + + diff --git a/docs/nav_f.png b/docs/nav_f.png new file mode 100644 index 0000000000000000000000000000000000000000..72a58a529ed3a9ed6aa0c51a79cf207e026deee2 GIT binary patch literal 153 zcmeAS@N?(olHy`uVBq!ia0vp^j6iI`!2~2XGqLUlQVE_ejv*C{Z|{2ZH7M}7UYxc) zn!W8uqtnIQ>_z8U literal 0 HcmV?d00001 diff --git a/docs/nav_fd.png b/docs/nav_fd.png new file mode 100644 index 0000000000000000000000000000000000000000..032fbdd4c54f54fa9a2e6423b94ef4b2ebdfaceb GIT binary patch literal 169 zcmeAS@N?(olHy`uVBq!ia0vp^j6iI`!2~2XGqLUlQU#tajv*C{Z|C~*H7f|XvG1G8 zt7aS*L7xwMeS}!z6R#{C5tIw-s~AJ==F^i}x3XyJseHR@yF& zerFf(Zf;Dd{+(0lDIROL@Sj-Ju2JQ8&-n%4%q?>|^bShc&lR?}7HeMo@BDl5N(aHY Uj$gdr1MOz;boFyt=akR{0D!zeaR2}S literal 0 HcmV?d00001 diff --git a/docs/nav_g.png b/docs/nav_g.png new file mode 100644 index 0000000000000000000000000000000000000000..2093a237a94f6c83e19ec6e5fd42f7ddabdafa81 GIT binary patch literal 95 zcmeAS@N?(olHy`uVBq!ia0vp^j6lrB!3HFm1ilyoDK$?Q$B+ufw|5PB85lU25BhtE tr?otc=hd~V+ws&_A@j8Fiv!KF$B+ufw|5=67#uj90@pIL wZ=Q8~_Ju`#59=RjDrmm`tMD@M=!-l18IR?&vFVdQ&MBb@0HFXL6W-eg#Jd_@e6*DPn)w;=|1H}Zvm9l6xXXB%>yL=NQU;mg M>FVdQ&MBb@0Bdt1Qvd(} literal 0 HcmV?d00001 diff --git a/docs/navtree.css b/docs/navtree.css new file mode 100644 index 0000000..d70f378 --- /dev/null +++ b/docs/navtree.css @@ -0,0 +1,150 @@ +#nav-tree .children_ul { + margin:0; + padding:4px; +} + +#nav-tree ul { + list-style:none outside none; + margin:0px; + padding:0px; +} + +#nav-tree li { + white-space:nowrap; + margin:0px; + padding:0px; +} + +#nav-tree .plus { + margin:0px; +} + +#nav-tree .selected { + background-image: url('tab_a.png'); + background-repeat:repeat-x; + color: white; + text-shadow: 0px 1px 1px rgba(0, 0, 0, 1.0); +} + +#nav-tree .selected .arrow { + color: #9CAFD4; + text-shadow: none; +} + +#nav-tree img { + margin:0px; + padding:0px; + border:0px; + vertical-align: middle; +} + +#nav-tree a { + text-decoration:none; + padding:0px; + margin:0px; + outline:none; +} + +#nav-tree .label { + margin:0px; + padding:0px; + font: 12px 'Lucida Grande',Geneva,Helvetica,Arial,sans-serif; +} + +#nav-tree .label a { + padding:2px; +} + +#nav-tree .selected a { + text-decoration:none; + color:white; +} + +#nav-tree .children_ul { + margin:0px; + padding:0px; +} + +#nav-tree .item { + margin:0px; + padding:0px; +} + +#nav-tree { + padding: 0px 0px; + font-size:14px; + overflow:auto; +} + +#doc-content { + overflow:auto; + display:block; + padding:0px; + margin:0px; + -webkit-overflow-scrolling : touch; /* iOS 5+ */ +} + +#side-nav { + padding:0 6px 0 0; + margin: 0px; + display:block; + position: absolute; + left: 0px; + width: $width; + overflow : hidden; +} + +.ui-resizable .ui-resizable-handle { + display:block; +} + +.ui-resizable-e { + background-image:url('splitbar.png'); + background-size:100%; + background-repeat:repeat-y; + background-attachment: scroll; + cursor:ew-resize; + height:100%; + right:0; + top:0; + width:6px; +} + +.ui-resizable-handle { + display:none; + font-size:0.1px; + position:absolute; + z-index:1; +} + +#nav-tree-contents { + margin: 6px 0px 0px 0px; +} + +#nav-tree { + background-repeat:repeat-x; + background-color: #F9FAFC; + -webkit-overflow-scrolling : touch; /* iOS 5+ */ +} + +#nav-sync { + position:absolute; + top:5px; + right:24px; + z-index:0; +} + +#nav-sync img { + opacity:0.3; +} + +#nav-sync img:hover { + opacity:0.9; +} + +@media print +{ + #nav-tree { display: none; } + div.ui-resizable-handle { display: none; position: relative; } +} + diff --git a/docs/navtree.js b/docs/navtree.js new file mode 100644 index 0000000..2798368 --- /dev/null +++ b/docs/navtree.js @@ -0,0 +1,549 @@ +/* + @licstart The following is the entire license notice for the JavaScript code in this file. + + The MIT License (MIT) + + Copyright (C) 1997-2020 by Dimitri van Heesch + + Permission is hereby granted, free of charge, to any person obtaining a copy of this software + and associated documentation files (the "Software"), to deal in the Software without restriction, + including without limitation the rights to use, copy, modify, merge, publish, distribute, + sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is + furnished to do so, subject to the following conditions: + + The above copyright notice and this permission notice shall be included in all copies or + substantial portions of the Software. + + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING + BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND + NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, + DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + + @licend The above is the entire license notice for the JavaScript code in this file + */ +var navTreeSubIndices = new Array(); +var arrowDown = '▼'; +var arrowRight = '►'; + +function getData(varName) +{ + var i = varName.lastIndexOf('/'); + var n = i>=0 ? varName.substring(i+1) : varName; + return eval(n.replace(/\-/g,'_')); +} + +function stripPath(uri) +{ + return uri.substring(uri.lastIndexOf('/')+1); +} + +function stripPath2(uri) +{ + var i = uri.lastIndexOf('/'); + var s = uri.substring(i+1); + var m = uri.substring(0,i+1).match(/\/d\w\/d\w\w\/$/); + return m ? uri.substring(i-6) : s; +} + +function hashValue() +{ + return $(location).attr('hash').substring(1).replace(/[^\w\-]/g,''); +} + +function hashUrl() +{ + return '#'+hashValue(); +} + +function pathName() +{ + return $(location).attr('pathname').replace(/[^-A-Za-z0-9+&@#/%?=~_|!:,.;\(\)]/g, ''); +} + +function localStorageSupported() +{ + try { + return 'localStorage' in window && window['localStorage'] !== null && window.localStorage.getItem; + } + catch(e) { + return false; + } +} + +function storeLink(link) +{ + if (!$("#nav-sync").hasClass('sync') && localStorageSupported()) { + window.localStorage.setItem('navpath',link); + } +} + +function deleteLink() +{ + if (localStorageSupported()) { + window.localStorage.setItem('navpath',''); + } +} + +function cachedLink() +{ + if (localStorageSupported()) { + return window.localStorage.getItem('navpath'); + } else { + return ''; + } +} + +function getScript(scriptName,func,show) +{ + var head = document.getElementsByTagName("head")[0]; + var script = document.createElement('script'); + script.id = scriptName; + script.type = 'text/javascript'; + script.onload = func; + script.src = scriptName+'.js'; + head.appendChild(script); +} + +function createIndent(o,domNode,node,level) +{ + var level=-1; + var n = node; + while (n.parentNode) { level++; n=n.parentNode; } + if (node.childrenData) { + var imgNode = document.createElement("span"); + imgNode.className = 'arrow'; + imgNode.style.paddingLeft=(16*level).toString()+'px'; + imgNode.innerHTML=arrowRight; + node.plus_img = imgNode; + node.expandToggle = document.createElement("a"); + node.expandToggle.href = "javascript:void(0)"; + node.expandToggle.onclick = function() { + if (node.expanded) { + $(node.getChildrenUL()).slideUp("fast"); + node.plus_img.innerHTML=arrowRight; + node.expanded = false; + } else { + expandNode(o, node, false, false); + } + } + node.expandToggle.appendChild(imgNode); + domNode.appendChild(node.expandToggle); + } else { + var span = document.createElement("span"); + span.className = 'arrow'; + span.style.width = 16*(level+1)+'px'; + span.innerHTML = ' '; + domNode.appendChild(span); + } +} + +var animationInProgress = false; + +function gotoAnchor(anchor,aname,updateLocation) +{ + var pos, docContent = $('#doc-content'); + var ancParent = $(anchor.parent()); + if (ancParent.hasClass('memItemLeft') || + ancParent.hasClass('memtitle') || + ancParent.hasClass('fieldname') || + ancParent.hasClass('fieldtype') || + ancParent.is(':header')) + { + pos = ancParent.position().top; + } else if (anchor.position()) { + pos = anchor.position().top; + } + if (pos) { + var dist = Math.abs(Math.min( + pos-docContent.offset().top, + docContent[0].scrollHeight- + docContent.height()-docContent.scrollTop())); + animationInProgress=true; + docContent.animate({ + scrollTop: pos + docContent.scrollTop() - docContent.offset().top + },Math.max(50,Math.min(500,dist)),function(){ + if (updateLocation) window.location.href=aname; + animationInProgress=false; + }); + } +} + +function newNode(o, po, text, link, childrenData, lastNode) +{ + var node = new Object(); + node.children = Array(); + node.childrenData = childrenData; + node.depth = po.depth + 1; + node.relpath = po.relpath; + node.isLast = lastNode; + + node.li = document.createElement("li"); + po.getChildrenUL().appendChild(node.li); + node.parentNode = po; + + node.itemDiv = document.createElement("div"); + node.itemDiv.className = "item"; + + node.labelSpan = document.createElement("span"); + node.labelSpan.className = "label"; + + createIndent(o,node.itemDiv,node,0); + node.itemDiv.appendChild(node.labelSpan); + node.li.appendChild(node.itemDiv); + + var a = document.createElement("a"); + node.labelSpan.appendChild(a); + node.label = document.createTextNode(text); + node.expanded = false; + a.appendChild(node.label); + if (link) { + var url; + if (link.substring(0,1)=='^') { + url = link.substring(1); + link = url; + } else { + url = node.relpath+link; + } + a.className = stripPath(link.replace('#',':')); + if (link.indexOf('#')!=-1) { + var aname = '#'+link.split('#')[1]; + var srcPage = stripPath(pathName()); + var targetPage = stripPath(link.split('#')[0]); + a.href = srcPage!=targetPage ? url : "javascript:void(0)"; + a.onclick = function(){ + storeLink(link); + if (!$(a).parent().parent().hasClass('selected')) + { + $('.item').removeClass('selected'); + $('.item').removeAttr('id'); + $(a).parent().parent().addClass('selected'); + $(a).parent().parent().attr('id','selected'); + } + var anchor = $(aname); + gotoAnchor(anchor,aname,true); + }; + } else { + a.href = url; + a.onclick = function() { storeLink(link); } + } + } else { + if (childrenData != null) + { + a.className = "nolink"; + a.href = "javascript:void(0)"; + a.onclick = node.expandToggle.onclick; + } + } + + node.childrenUL = null; + node.getChildrenUL = function() { + if (!node.childrenUL) { + node.childrenUL = document.createElement("ul"); + node.childrenUL.className = "children_ul"; + node.childrenUL.style.display = "none"; + node.li.appendChild(node.childrenUL); + } + return node.childrenUL; + }; + + return node; +} + +function showRoot() +{ + var headerHeight = $("#top").height(); + var footerHeight = $("#nav-path").height(); + var windowHeight = $(window).height() - headerHeight - footerHeight; + (function (){ // retry until we can scroll to the selected item + try { + var navtree=$('#nav-tree'); + navtree.scrollTo('#selected',100,{offset:-windowHeight/2}); + } catch (err) { + setTimeout(arguments.callee, 0); + } + })(); +} + +function expandNode(o, node, imm, showRoot) +{ + if (node.childrenData && !node.expanded) { + if (typeof(node.childrenData)==='string') { + var varName = node.childrenData; + getScript(node.relpath+varName,function(){ + node.childrenData = getData(varName); + expandNode(o, node, imm, showRoot); + }, showRoot); + } else { + if (!node.childrenVisited) { + getNode(o, node); + } + $(node.getChildrenUL()).slideDown("fast"); + node.plus_img.innerHTML = arrowDown; + node.expanded = true; + } + } +} + +function glowEffect(n,duration) +{ + n.addClass('glow').delay(duration).queue(function(next){ + $(this).removeClass('glow');next(); + }); +} + +function highlightAnchor() +{ + var aname = hashUrl(); + var anchor = $(aname); + if (anchor.parent().attr('class')=='memItemLeft'){ + var rows = $('.memberdecls tr[class$="'+hashValue()+'"]'); + glowEffect(rows.children(),300); // member without details + } else if (anchor.parent().attr('class')=='fieldname'){ + glowEffect(anchor.parent().parent(),1000); // enum value + } else if (anchor.parent().attr('class')=='fieldtype'){ + glowEffect(anchor.parent().parent(),1000); // struct field + } else if (anchor.parent().is(":header")) { + glowEffect(anchor.parent(),1000); // section header + } else { + glowEffect(anchor.next(),1000); // normal member + } +} + +function selectAndHighlight(hash,n) +{ + var a; + if (hash) { + var link=stripPath(pathName())+':'+hash.substring(1); + a=$('.item a[class$="'+link+'"]'); + } + if (a && a.length) { + a.parent().parent().addClass('selected'); + a.parent().parent().attr('id','selected'); + highlightAnchor(); + } else if (n) { + $(n.itemDiv).addClass('selected'); + $(n.itemDiv).attr('id','selected'); + } + var topOffset=5; + if (typeof page_layout!=='undefined' && page_layout==1) { + topOffset+=$('#top').outerHeight(); + } + if ($('#nav-tree-contents .item:first').hasClass('selected')) { + topOffset+=25; + } + $('#nav-sync').css('top',topOffset+'px'); + showRoot(); +} + +function showNode(o, node, index, hash) +{ + if (node && node.childrenData) { + if (typeof(node.childrenData)==='string') { + var varName = node.childrenData; + getScript(node.relpath+varName,function(){ + node.childrenData = getData(varName); + showNode(o,node,index,hash); + },true); + } else { + if (!node.childrenVisited) { + getNode(o, node); + } + $(node.getChildrenUL()).css({'display':'block'}); + node.plus_img.innerHTML = arrowDown; + node.expanded = true; + var n = node.children[o.breadcrumbs[index]]; + if (index+11) hash = '#'+parts[1].replace(/[^\w\-]/g,''); + else hash=''; + } + if (hash.match(/^#l\d+$/)) { + var anchor=$('a[name='+hash.substring(1)+']'); + glowEffect(anchor.parent(),1000); // line number + hash=''; // strip line number anchors + } + var url=root+hash; + var i=-1; + while (NAVTREEINDEX[i+1]<=url) i++; + if (i==-1) { i=0; root=NAVTREE[0][1]; } // fallback: show index + if (navTreeSubIndices[i]) { + gotoNode(o,i,root,hash,relpath) + } else { + getScript(relpath+'navtreeindex'+i,function(){ + navTreeSubIndices[i] = eval('NAVTREEINDEX'+i); + if (navTreeSubIndices[i]) { + gotoNode(o,i,root,hash,relpath); + } + },true); + } +} + +function showSyncOff(n,relpath) +{ + n.html(''); +} + +function showSyncOn(n,relpath) +{ + n.html(''); +} + +function toggleSyncButton(relpath) +{ + var navSync = $('#nav-sync'); + if (navSync.hasClass('sync')) { + navSync.removeClass('sync'); + showSyncOff(navSync,relpath); + storeLink(stripPath2(pathName())+hashUrl()); + } else { + navSync.addClass('sync'); + showSyncOn(navSync,relpath); + deleteLink(); + } +} + +var loadTriggered = false; +var readyTriggered = false; +var loadObject,loadToRoot,loadUrl,loadRelPath; + +$(window).on('load',function(){ + if (readyTriggered) { // ready first + navTo(loadObject,loadToRoot,loadUrl,loadRelPath); + showRoot(); + } + loadTriggered=true; +}); + +function initNavTree(toroot,relpath) +{ + var o = new Object(); + o.toroot = toroot; + o.node = new Object(); + o.node.li = document.getElementById("nav-tree-contents"); + o.node.childrenData = NAVTREE; + o.node.children = new Array(); + o.node.childrenUL = document.createElement("ul"); + o.node.getChildrenUL = function() { return o.node.childrenUL; }; + o.node.li.appendChild(o.node.childrenUL); + o.node.depth = 0; + o.node.relpath = relpath; + o.node.expanded = false; + o.node.isLast = true; + o.node.plus_img = document.createElement("span"); + o.node.plus_img.className = 'arrow'; + o.node.plus_img.innerHTML = arrowRight; + + if (localStorageSupported()) { + var navSync = $('#nav-sync'); + if (cachedLink()) { + showSyncOff(navSync,relpath); + navSync.removeClass('sync'); + } else { + showSyncOn(navSync,relpath); + } + navSync.click(function(){ toggleSyncButton(relpath); }); + } + + if (loadTriggered) { // load before ready + navTo(o,toroot,hashUrl(),relpath); + showRoot(); + } else { // ready before load + loadObject = o; + loadToRoot = toroot; + loadUrl = hashUrl(); + loadRelPath = relpath; + readyTriggered=true; + } + + $(window).bind('hashchange', function(){ + if (window.location.hash && window.location.hash.length>1){ + var a; + if ($(location).attr('hash')){ + var clslink=stripPath(pathName())+':'+hashValue(); + a=$('.item a[class$="'+clslink.replace(/1|%O$WD@{VPM$7~Ar*{o?;hlAFyLXmaDC0y znK1_#cQqJWPES%4Uujug^TE?jMft$}Eq^WaR~)%f)vSNs&gek&x%A9X9sM + + + + + + +2 Dimensional Ising Model: Related Pages + + + + + + + + + + + + + + + + +
    +
    + + + + + + +
    +
    2 Dimensional Ising Model +
    +
    Simulate the change in energy and magnetization in a ferro magnet
    +
    +
    + + + + + + + +
    +
    + +
    +
    +
    + +
    + +
    +
    + + +
    +
    +
    +
    +
    +
    Loading...
    +
    Searching...
    +
    No Matches
    +
    +
    +
    +
    + +
    +
    Related Pages
    +
    +
    +
    Here is a list of all related documentation pages:
    + + +
     Bug List
    +
    +
    +
    + + + + diff --git a/docs/pd__estimate_8py_source.html b/docs/pd__estimate_8py_source.html new file mode 100644 index 0000000..0a3c3ac --- /dev/null +++ b/docs/pd__estimate_8py_source.html @@ -0,0 +1,141 @@ + + + + + + + +2 Dimensional Ising Model: src/scripts/pd_estimate.py Source File + + + + + + + + + + + + + + + + +
    +
    + + + + + + +
    +
    2 Dimensional Ising Model +
    +
    Simulate the change in energy and magnetization in a ferro magnet
    +
    +
    + + + + + + + +
    +
    + +
    +
    +
    + +
    + +
    +
    + + +
    +
    +
    +
    +
    +
    Loading...
    +
    Searching...
    +
    No Matches
    +
    +
    +
    +
    + +
    +
    pd_estimate.py
    +
    +
    +
    1import os
    +
    2from pathlib import Path
    +
    3
    +
    4import matplotlib.pyplot as plt
    +
    5import numpy as np
    +
    6
    +
    7
    +
    8def plot(infile, outfile):
    +
    9 if not (outdir := Path(outfile).parent).exists():
    +
    10 os.makedirs(outdir)
    +
    11
    +
    12 figure1, ax1 = plt.subplots()
    +
    13 arr = []
    +
    14 with open(infile) as f:
    +
    15 lines = f.readlines()
    +
    16 for line in lines:
    +
    17 vals = line.strip().split(",")
    +
    18 arr.append(float(vals[0]))
    +
    19
    +
    20 ax1.hist(arr, np.arange(min(arr), max(arr) + 0.02, 0.02), density=True, ec="black")
    +
    21
    +
    22 figure1.savefig(outfile)
    +
    23
    +
    24
    +
    25if __name__ == "__main__":
    +
    26 plot("output/pd_estimate/estimate_1_0.txt", "../latex/images/pd_estimate_1_0.pdf")
    +
    27 plot("output/pd_estimate/estimate_2_4.txt", "../latex/images/pd_estimate_2_4.pdf")
    +
    +
    + + + + diff --git a/docs/phase__transition_8py_source.html b/docs/phase__transition_8py_source.html new file mode 100644 index 0000000..e035b5c --- /dev/null +++ b/docs/phase__transition_8py_source.html @@ -0,0 +1,226 @@ + + + + + + + +2 Dimensional Ising Model: src/scripts/phase_transition.py Source File + + + + + + + + + + + + + + + + +
    +
    + + + + + + +
    +
    2 Dimensional Ising Model +
    +
    Simulate the change in energy and magnetization in a ferro magnet
    +
    +
    + + + + + + + +
    +
    + +
    +
    +
    + +
    + +
    +
    + + +
    +
    +
    +
    +
    +
    Loading...
    +
    Searching...
    +
    No Matches
    +
    +
    +
    +
    + +
    +
    phase_transition.py
    +
    +
    +
    1from pathlib import Path
    +
    2
    +
    3import matplotlib.pyplot as plt
    +
    4import numpy as np
    +
    5from scipy.stats import linregress
    +
    6
    +
    7
    +
    8def plot_phase_transition(indir, outdir):
    +
    9 files = [
    +
    10 "size_20.txt",
    +
    11 "size_40.txt",
    +
    12 "size_60.txt",
    +
    13 "size_80.txt",
    +
    14 "size_100.txt",
    +
    15 ]
    +
    16 labels = [
    +
    17 "L = 20",
    +
    18 "L = 40",
    +
    19 "L = 60",
    +
    20 "L = 80",
    +
    21 "L = 100",
    +
    22 ]
    +
    23
    +
    24 figure1, ax1 = plt.subplots()
    +
    25 figure2, ax2 = plt.subplots()
    +
    26 figure3, ax3 = plt.subplots()
    +
    27 figure4, ax4 = plt.subplots()
    +
    28 figure5, ax5 = plt.subplots()
    +
    29
    +
    30 # For linear regression
    +
    31 L = []
    +
    32 Tc = []
    +
    33 size = 20
    +
    34
    +
    35 for file, label in zip(files, labels):
    +
    36 t = []
    +
    37 e = []
    +
    38 m = []
    +
    39 CV = []
    +
    40 X = []
    +
    41
    +
    42 # Append the lattice size
    +
    43 L.append(size)
    +
    44 size += 20
    +
    45
    +
    46 with open(Path(indir, file)) as f:
    +
    47 lines = f.readlines()
    +
    48 for line in lines:
    +
    49 l = line.strip().split(",")
    +
    50 t.append(float(l[0]))
    +
    51 e.append(float(l[1]))
    +
    52 m.append(float(l[2]))
    +
    53 CV.append(float(l[3]))
    +
    54 X.append(float(l[4]))
    +
    55
    +
    56 # Append the critical temp for the current lattice size
    +
    57 Tc.append(t[X.index(max(X))])
    +
    58
    +
    59 ax1.plot(t, e, label=label)
    +
    60 ax2.plot(t, m, label=label)
    +
    61 ax3.plot(t, CV, label=label)
    +
    62 ax4.plot(t, X, label=label)
    +
    63
    +
    64 # Attempt linear regression
    +
    65 x = np.linspace(0, 100, 1001)
    +
    66 regression = linregress(L, Tc)
    +
    67 f = lambda x: regression[0] * x + regression[1]
    +
    68 ax5.scatter(L, Tc)
    +
    69 ax5.plot(x, f(x), label=f"m = {regression[0]}")
    +
    70
    +
    71 figure1.legend()
    +
    72 figure2.legend()
    +
    73 figure3.legend()
    +
    74 figure4.legend()
    +
    75 figure5.legend()
    +
    76
    +
    77 figure1.savefig(Path(outdir, "energy.pdf"))
    +
    78 figure2.savefig(Path(outdir, "magnetization.pdf"))
    +
    79 figure3.savefig(Path(outdir, "heat_capacity.pdf"))
    +
    80 figure4.savefig(Path(outdir, "susceptibility.pdf"))
    +
    81 figure5.savefig(Path(outdir, "linreg.pdf"))
    +
    82
    +
    83 plt.close(figure1)
    +
    84 plt.close(figure2)
    +
    85 plt.close(figure3)
    +
    86 plt.close(figure4)
    +
    87 plt.close(figure5)
    +
    88
    +
    89
    +
    90if __name__ == "__main__":
    +
    91 plot_phase_transition(
    +
    92 "fox_output/phase_transition/wide/10M/",
    +
    93 "../latex/images/phase_transition/fox/wide/10M/",
    +
    94 )
    +
    95 plot_phase_transition(
    +
    96 "fox_output/phase_transition/wide/1M/",
    +
    97 "../latex/images/phase_transition/fox/wide/1M/",
    +
    98 )
    +
    99 plot_phase_transition(
    +
    100 "fox_output/phase_transition/narrow/10M/",
    +
    101 "../latex/images/phase_transition/fox/narrow/10M/",
    +
    102 )
    +
    103 plot_phase_transition(
    +
    104 "output/phase_transition/", "../latex/images/phase_transition/hp/"
    +
    105 )
    +
    106 plot_phase_transition(
    +
    107 "output/phase_transition/", "../latex/images/phase_transition/hp/"
    +
    108 )
    +
    109 plot_phase_transition(
    +
    110 "output/phase_transition/",
    +
    111 "../latex/images/phase_transition/hp/",
    +
    112 )
    +
    +
    + + + + diff --git a/docs/phase__transition__mpi_8cpp.html b/docs/phase__transition__mpi_8cpp.html new file mode 100644 index 0000000..0e88ed6 --- /dev/null +++ b/docs/phase__transition__mpi_8cpp.html @@ -0,0 +1,179 @@ + + + + + + + +2 Dimensional Ising Model: src/phase_transition_mpi.cpp File Reference + + + + + + + + + + + + + + + + +
    +
    + + + + + + +
    +
    2 Dimensional Ising Model +
    +
    Simulate the change in energy and magnetization in a ferro magnet
    +
    +
    + + + + + + + +
    +
    + +
    +
    +
    + +
    + +
    +
    + + +
    +
    +
    +
    +
    +
    Loading...
    +
    Searching...
    +
    No Matches
    +
    +
    +
    +
    + +
    + +
    phase_transition_mpi.cpp File Reference
    +
    +
    + +

    Sweep over different temperatures and generate data. +More...

    +
    #include "data_type.hpp"
    +#include "monte_carlo.hpp"
    +#include "utils.hpp"
    +#include <algorithm>
    +#include <fstream>
    +#include <iostream>
    +#include <iterator>
    +#include <mpi.h>
    +#include <sstream>
    +
    +

    Go to the source code of this file.

    + + + + + +

    +Functions

    int main (int argc, char **argv)
     The main function.
     
    +

    Detailed Description

    +

    Sweep over different temperatures and generate data.

    +
    Author
    Cory Alexander Balaton (coryab)
    +
    +Janita Ovidie Sandtrøen Willumsen (janitaws)
    +
    Version
    1.0
    +
    Bug:
    No known bugs
    + +

    Definition in file phase_transition_mpi.cpp.

    +

    Function Documentation

    + +

    ◆ main()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    int main (int argc,
    char ** argv 
    )
    +
    + +

    The main function.

    + +

    Definition at line 24 of file phase_transition_mpi.cpp.

    + +
    +
    +
    +
    + + + + diff --git a/docs/phase__transition__mpi_8cpp.js b/docs/phase__transition__mpi_8cpp.js new file mode 100644 index 0000000..9cad85a --- /dev/null +++ b/docs/phase__transition__mpi_8cpp.js @@ -0,0 +1,4 @@ +var phase__transition__mpi_8cpp = +[ + [ "main", "phase__transition__mpi_8cpp.html#a3c04138a5bfe5d72780bb7e82a18e627", null ] +]; \ No newline at end of file diff --git a/docs/phase__transition__mpi_8cpp_source.html b/docs/phase__transition__mpi_8cpp_source.html new file mode 100644 index 0000000..0be9b13 --- /dev/null +++ b/docs/phase__transition__mpi_8cpp_source.html @@ -0,0 +1,237 @@ + + + + + + + +2 Dimensional Ising Model: src/phase_transition_mpi.cpp Source File + + + + + + + + + + + + + + + + +
    +
    + + + + + + +
    +
    2 Dimensional Ising Model +
    +
    Simulate the change in energy and magnetization in a ferro magnet
    +
    +
    + + + + + + + +
    +
    + +
    +
    +
    + +
    + +
    +
    + + +
    +
    +
    +
    +
    +
    Loading...
    +
    Searching...
    +
    No Matches
    +
    +
    +
    +
    + +
    +
    phase_transition_mpi.cpp
    +
    +
    +Go to the documentation of this file.
    1
    +
    12#include "data_type.hpp"
    +
    13#include "monte_carlo.hpp"
    +
    14#include "utils.hpp"
    +
    15
    +
    16#include <algorithm>
    +
    17#include <fstream>
    +
    18#include <iostream>
    +
    19#include <iterator>
    +
    20#include <mpi.h>
    +
    21#include <sstream>
    +
    22
    +
    24int main(int argc, char **argv)
    +
    25{
    +
    26 if (argc < 5) {
    +
    27 std::cout << "You need at least 4 arguments" << std::endl;
    +
    28 abort();
    +
    29 }
    +
    30 double t0, t1;
    +
    31 t0 = MPI_Wtime();
    +
    32 double start = atof(argv[1]), end = atof(argv[2]);
    +
    33 int points = atoi(argv[3]), N;
    +
    34 int lattice_sizes[] = {20, 40, 60, 80, 100};
    +
    35 double dt = (end - start) / points;
    +
    36 int cycles = atoi(argv[4]);
    +
    37 std::ofstream ofile;
    +
    38
    +
    39 data_t data[points];
    +
    40
    +
    41 // MPI stuff
    +
    42 int rank, cluster_size;
    +
    43
    +
    44 // Initialize MPI
    +
    45 MPI_Init(&argc, &argv);
    +
    46
    +
    47 // Get the cluster size and rank
    +
    48 MPI_Comm_size(MPI_COMM_WORLD, &cluster_size);
    +
    49 MPI_Comm_rank(MPI_COMM_WORLD, &rank);
    +
    50
    +
    51 int remainder = points % cluster_size;
    +
    52 double i_start;
    +
    53 int i_points;
    +
    54 // Distribute temperature points
    +
    55 if (rank < remainder) {
    +
    56 i_points = points / cluster_size + 1;
    +
    57 i_start = start + dt * i_points * rank;
    +
    58 }
    +
    59 else {
    +
    60 i_points = points / cluster_size;
    +
    61 i_start = start + dt * (i_points * rank + remainder);
    +
    62 }
    +
    63
    +
    64 data_t i_data[i_points];
    +
    65 std::cout << "Rank " << rank << ": " << i_points << ',' << i_start << '\n';
    +
    66
    +
    67 for (int L : lattice_sizes) {
    +
    68 N = L * L;
    +
    69 for (size_t i = 0; i < i_points; i++) {
    +
    70 i_data[i] = monte_carlo_parallel(L, i_start + dt * i, cycles);
    +
    71 }
    +
    72
    +
    73 if (rank == 0) {
    +
    74 std::copy_n(i_data, i_points, data);
    +
    75 for (size_t i = 1; i < cluster_size; i++) {
    +
    76 if (rank < remainder) {
    +
    77 MPI_Recv((void *)i_data,
    +
    78 sizeof(data_t) * (points / cluster_size + 1),
    +
    79 MPI_CHAR, i, MPI_ANY_TAG, MPI_COMM_WORLD,
    +
    80 MPI_STATUS_IGNORE);
    +
    81 std::copy_n(i_data, points / cluster_size + 1,
    +
    82 data + (points / cluster_size) * i);
    +
    83 }
    +
    84 else {
    +
    85 MPI_Recv((void *)i_data,
    +
    86 sizeof(data_t) * (points / cluster_size), MPI_CHAR,
    +
    87 i, MPI_ANY_TAG, MPI_COMM_WORLD, MPI_STATUS_IGNORE);
    +
    88 std::copy_n(i_data, points / cluster_size,
    +
    89 data + (points / cluster_size) * i + remainder);
    +
    90 }
    +
    91 }
    +
    92 std::stringstream outfile;
    +
    93 outfile << "output/phase_transition/size_" << L << ".txt";
    +
    94 utils::mkpath(utils::dirname(outfile.str()));
    +
    95 ofile.open(outfile.str());
    +
    96
    +
    97 double temp, CV, X;
    +
    98
    +
    99 using utils::scientific_format;
    +
    100 for (size_t i = 0; i < points; i++) {
    +
    101 temp = start + dt * i;
    +
    102 CV = (data[i].E2 - data[i].E * data[i].E)
    +
    103 / ((double)N * temp * temp);
    +
    104 X = (data[i].M2 - data[i].M_abs * data[i].M_abs)
    +
    105 / ((double)N * temp);
    +
    106
    +
    107 ofile << scientific_format(temp) << ','
    +
    108 << scientific_format(data[i].E / N) << ','
    +
    109 << scientific_format(data[i].M_abs / N) << ','
    +
    110 << scientific_format(CV) << ',' << scientific_format(X)
    +
    111 << '\n';
    +
    112 }
    +
    113 ofile.close();
    +
    114 }
    +
    115 else {
    +
    116 MPI_Send(i_data, i_points * sizeof(data_t), MPI_CHAR, 0, rank,
    +
    117 MPI_COMM_WORLD);
    +
    118 }
    +
    119 }
    +
    120
    +
    121 t1 = MPI_Wtime();
    +
    122
    +
    123 if (rank == 0) {
    +
    124 std::cout << "Time: " << t1 - t0 << " seconds\n";
    +
    125 }
    +
    126
    +
    127 MPI_Finalize();
    +
    128}
    + +
    Header for the data_t type.
    +
    Functions for monte carlo simulations.
    +
    data_t monte_carlo_parallel(int L, double T, int cycles)
    Execute the Metropolis algorithm for a certain amount of Monte Carlo cycles in parallel.
    +
    int main()
    The main function.
    Definition: test_suite.cpp:148
    +
    Function prototypes and macros that are useful.
    +
    +
    + + + + diff --git a/docs/resize.js b/docs/resize.js new file mode 100644 index 0000000..aaeb6fc --- /dev/null +++ b/docs/resize.js @@ -0,0 +1,155 @@ +/* + @licstart The following is the entire license notice for the JavaScript code in this file. + + The MIT License (MIT) + + Copyright (C) 1997-2020 by Dimitri van Heesch + + Permission is hereby granted, free of charge, to any person obtaining a copy of this software + and associated documentation files (the "Software"), to deal in the Software without restriction, + including without limitation the rights to use, copy, modify, merge, publish, distribute, + sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is + furnished to do so, subject to the following conditions: + + The above copyright notice and this permission notice shall be included in all copies or + substantial portions of the Software. + + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING + BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND + NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, + DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + + @licend The above is the entire license notice for the JavaScript code in this file + */ +var once=1; +function initResizable() +{ + var cookie_namespace = 'doxygen'; + var sidenav,navtree,content,header,barWidth=6,desktop_vp=768,titleHeight; + + function readSetting(cookie) + { + if (window.chrome) { + var val = localStorage.getItem(cookie_namespace+'_width'); + if (val) return val; + } else { + var myCookie = cookie_namespace+"_"+cookie+"="; + if (document.cookie) { + var index = document.cookie.indexOf(myCookie); + if (index != -1) { + var valStart = index + myCookie.length; + var valEnd = document.cookie.indexOf(";", valStart); + if (valEnd == -1) { + valEnd = document.cookie.length; + } + var val = document.cookie.substring(valStart, valEnd); + return val; + } + } + } + return 250; + } + + function writeSetting(cookie, val) + { + if (window.chrome) { + localStorage.setItem(cookie_namespace+"_width",val); + } else { + var date = new Date(); + date.setTime(date.getTime()+(10*365*24*60*60*1000)); // default expiration is one week + expiration = date.toGMTString(); + document.cookie = cookie_namespace + "_" + cookie + "=" + val + "; SameSite=Lax; expires=" + expiration+"; path=/"; + } + } + + function resizeWidth() + { + var windowWidth = $(window).width() + "px"; + var sidenavWidth = $(sidenav).outerWidth(); + content.css({marginLeft:parseInt(sidenavWidth)+"px"}); + if (typeof page_layout!=='undefined' && page_layout==1) { + footer.css({marginLeft:parseInt(sidenavWidth)+"px"}); + } + writeSetting('width',sidenavWidth-barWidth); + } + + function restoreWidth(navWidth) + { + var windowWidth = $(window).width() + "px"; + content.css({marginLeft:parseInt(navWidth)+barWidth+"px"}); + if (typeof page_layout!=='undefined' && page_layout==1) { + footer.css({marginLeft:parseInt(navWidth)+barWidth+"px"}); + } + sidenav.css({width:navWidth + "px"}); + } + + function resizeHeight() + { + var headerHeight = header.outerHeight(); + var footerHeight = footer.outerHeight(); + var windowHeight = $(window).height(); + var contentHeight,navtreeHeight,sideNavHeight; + if (typeof page_layout==='undefined' || page_layout==0) { /* DISABLE_INDEX=NO */ + contentHeight = windowHeight - headerHeight - footerHeight; + navtreeHeight = contentHeight; + sideNavHeight = contentHeight; + } else if (page_layout==1) { /* DISABLE_INDEX=YES */ + contentHeight = windowHeight - footerHeight; + navtreeHeight = windowHeight - headerHeight; + sideNavHeight = windowHeight; + } + content.css({height:contentHeight + "px"}); + navtree.css({height:navtreeHeight + "px"}); + sidenav.css({height:sideNavHeight + "px"}); + if (location.hash.slice(1)) { + (document.getElementById(location.hash.slice(1))||document.body).scrollIntoView(); + } + } + + function collapseExpand() + { + var newWidth; + if (sidenav.width()>0) { + newWidth=0; + } + else { + var width = readSetting('width'); + newWidth = (width>250 && width<$(window).width()) ? width : 250; + } + restoreWidth(newWidth); + var sidenavWidth = $(sidenav).outerWidth(); + writeSetting('width',sidenavWidth-barWidth); + } + + header = $("#top"); + sidenav = $("#side-nav"); + content = $("#doc-content"); + navtree = $("#nav-tree"); + footer = $("#nav-path"); + $(".side-nav-resizable").resizable({resize: function(e, ui) { resizeWidth(); } }); + $(sidenav).resizable({ minWidth: 0 }); + $(window).resize(function() { resizeHeight(); }); + var device = navigator.userAgent.toLowerCase(); + var touch_device = device.match(/(iphone|ipod|ipad|android)/); + if (touch_device) { /* wider split bar for touch only devices */ + $(sidenav).css({ paddingRight:'20px' }); + $('.ui-resizable-e').css({ width:'20px' }); + $('#nav-sync').css({ right:'34px' }); + barWidth=20; + } + var width = readSetting('width'); + if (width) { restoreWidth(width); } else { resizeWidth(); } + resizeHeight(); + var url = location.href; + var i=url.indexOf("#"); + if (i>=0) window.location.hash=url.substr(i); + var _preventDefault = function(evt) { evt.preventDefault(); }; + $("#splitbar").bind("dragstart", _preventDefault).bind("selectstart", _preventDefault); + if (once) { + $(".ui-resizable-handle").dblclick(collapseExpand); + once=0 + } + $(window).on('load',resizeHeight); +} +/* @license-end */ diff --git a/docs/search/all_0.js b/docs/search/all_0.js new file mode 100644 index 0000000..1e5c227 --- /dev/null +++ b/docs/search/all_0.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['_5f_5fmethod_5fname_5f_5f_0',['__METHOD_NAME__',['../utils_8hpp.html#a60dca3177fb9cb5256609adc7af55168',1,'utils.hpp']]] +]; diff --git a/docs/search/all_1.js b/docs/search/all_1.js new file mode 100644 index 0000000..e35967d --- /dev/null +++ b/docs/search/all_1.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['assert_0',['ASSERT',['../testlib_8hpp.html#a73d4f21ad937dbc50a0c0538c78fd4f9',1,'testlib.hpp']]] +]; diff --git a/docs/search/all_10.js b/docs/search/all_10.js new file mode 100644 index 0000000..cd921db --- /dev/null +++ b/docs/search/all_10.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['utils_2ecpp_0',['utils.cpp',['../utils_8cpp.html',1,'']]], + ['utils_2ehpp_1',['utils.hpp',['../utils_8hpp.html',1,'']]] +]; diff --git a/docs/search/all_2.js b/docs/search/all_2.js new file mode 100644 index 0000000..8a2ba60 --- /dev/null +++ b/docs/search/all_2.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['bug_20list_0',['Bug List',['../bug.html',1,'']]] +]; diff --git a/docs/search/all_3.js b/docs/search/all_3.js new file mode 100644 index 0000000..0648f09 --- /dev/null +++ b/docs/search/all_3.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['constants_2ehpp_0',['constants.hpp',['../constants_8hpp.html',1,'']]] +]; diff --git a/docs/search/all_4.js b/docs/search/all_4.js new file mode 100644 index 0000000..43c3415 --- /dev/null +++ b/docs/search/all_4.js @@ -0,0 +1,8 @@ +var searchData= +[ + ['data_5ft_0',['data_t',['../classdata__t.html',1,'']]], + ['data_5ftype_2ecpp_1',['data_type.cpp',['../data__type_8cpp.html',1,'']]], + ['data_5ftype_2ehpp_2',['data_type.hpp',['../data__type_8hpp.html',1,'']]], + ['debug_3',['DEBUG',['../utils_8hpp.html#aecc1f7a8a2493b9e021e5bff76a00a5b',1,'utils.hpp']]], + ['dirname_4',['dirname',['../utils_8hpp.html#aed026119193a9bbe076671809ff0f430',1,'utils']]] +]; diff --git a/docs/search/all_5.js b/docs/search/all_5.js new file mode 100644 index 0000000..3834eab --- /dev/null +++ b/docs/search/all_5.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['e_0',['E',['../classIsingModel.html#ae9f872ca2054992161d53306119979dd',1,'IsingModel']]], + ['energy_5fdiff_1',['energy_diff',['../classIsingModel.html#a1a4ceb1bb2593dbd20c51ed04100cbcd',1,'IsingModel']]] +]; diff --git a/docs/search/all_6.js b/docs/search/all_6.js new file mode 100644 index 0000000..45fb121 --- /dev/null +++ b/docs/search/all_6.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['get_5fe_0',['get_E',['../classIsingModel.html#aaa0787d964b004a17869811a5e947ff5',1,'IsingModel']]], + ['get_5fm_1',['get_M',['../classIsingModel.html#aa5701496e6483bc4668c486d6d3af625',1,'IsingModel']]] +]; diff --git a/docs/search/all_7.js b/docs/search/all_7.js new file mode 100644 index 0000000..a2ea4bf --- /dev/null +++ b/docs/search/all_7.js @@ -0,0 +1,13 @@ +var searchData= +[ + ['initialize_5fenergy_0',['initialize_energy',['../classIsingModel.html#a59fced38c695e2fa647f53be81b9d2a1',1,'IsingModel']]], + ['initialize_5fenergy_5fdiff_1',['initialize_energy_diff',['../classIsingModel.html#aff9a1201933fd5408845a1447e4895b4',1,'IsingModel']]], + ['initialize_5flattice_2',['initialize_lattice',['../classIsingModel.html#a34a4710949b4a70f3e37ca223aefcf8a',1,'IsingModel']]], + ['initialize_5fmagnetization_3',['initialize_magnetization',['../classIsingModel.html#a926cf4964d190d2ce23e5a17201787a4',1,'IsingModel']]], + ['initialize_5fneighbors_4',['initialize_neighbors',['../classIsingModel.html#a6776109105051597c275670dabd0054a',1,'IsingModel']]], + ['ising_20model_5',['Ising Model',['../index.html',1,'']]], + ['isingmodel_6',['IsingModel',['../classIsingModel.html',1,'IsingModel'],['../classIsingModel.html#acf281f6f5ed02911ca6ab07004449864',1,'IsingModel::IsingModel()'],['../classIsingModel.html#a4a39ee7fbfbbf566f75bc28900ca9ea5',1,'IsingModel::IsingModel(int L, double T)'],['../classIsingModel.html#a46c9446e94854452f715d307c77c1c15',1,'IsingModel::IsingModel(int L, double T, int val)']]], + ['isingmodel_2ecpp_7',['IsingModel.cpp',['../IsingModel_8cpp.html',1,'']]], + ['isingmodel_2ehpp_8',['IsingModel.hpp',['../IsingModel_8hpp.html',1,'']]], + ['isingmodeltest_9',['IsingModelTest',['../classIsingModelTest.html',1,'']]] +]; diff --git a/docs/search/all_8.js b/docs/search/all_8.js new file mode 100644 index 0000000..9d163ac --- /dev/null +++ b/docs/search/all_8.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['k_5fb_0',['k_B',['../constants_8hpp.html#abfa7d6668c777f9516606394bbc9c414',1,'constants.hpp']]] +]; diff --git a/docs/search/all_9.js b/docs/search/all_9.js new file mode 100644 index 0000000..d4681d4 --- /dev/null +++ b/docs/search/all_9.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['l_0',['L',['../classIsingModel.html#a2b8ac43baefeb386186266d5aa4de348',1,'IsingModel']]], + ['lattice_1',['lattice',['../classIsingModel.html#a2c3c76c79717c968d7c227c58b46df41',1,'IsingModel']]] +]; diff --git a/docs/search/all_a.js b/docs/search/all_a.js new file mode 100644 index 0000000..670bfbb --- /dev/null +++ b/docs/search/all_a.js @@ -0,0 +1,15 @@ +var searchData= +[ + ['m_0',['M',['../classIsingModel.html#a0d373a61baca6b0faa607bb12d82cc47',1,'IsingModel']]], + ['m_5fassert_1',['m_assert',['../testlib_8hpp.html#a39abb7cba0535176ed62aae136d2fcc7',1,'details']]], + ['main_2',['main',['../test__suite_8cpp.html#ae66f6b31b5ad750f1fe042a706a4e3d4',1,'main(): test_suite.cpp'],['../phase__transition__mpi_8cpp.html#a3c04138a5bfe5d72780bb7e82a18e627',1,'main(int argc, char **argv): phase_transition_mpi.cpp'],['../main_8cpp.html#a3c04138a5bfe5d72780bb7e82a18e627',1,'main(int argc, char **argv): main.cpp']]], + ['main_2ecpp_3',['main.cpp',['../main_8cpp.html',1,'']]], + ['methodname_4',['methodName',['../utils_8hpp.html#a178c4922157666a6e9c127c2ffd96346',1,'details']]], + ['metropolis_5',['Metropolis',['../classIsingModel.html#a56559d68dc9aaff1976d84b157f43488',1,'IsingModel']]], + ['mkpath_6',['mkpath',['../utils_8hpp.html#a2b45adc86b70f42021582994e83fa00d',1,'utils']]], + ['monte_5fcarlo_2ecpp_7',['monte_carlo.cpp',['../monte__carlo_8cpp.html',1,'']]], + ['monte_5fcarlo_2ehpp_8',['monte_carlo.hpp',['../monte__carlo_8hpp.html',1,'']]], + ['monte_5fcarlo_5fparallel_9',['monte_carlo_parallel',['../monte__carlo_8hpp.html#acc34e2049a5030874f6f548f3adab958',1,'monte_carlo_parallel(int L, double T, int cycles): monte_carlo.cpp'],['../monte__carlo_8cpp.html#acc34e2049a5030874f6f548f3adab958',1,'monte_carlo_parallel(int L, double T, int cycles): monte_carlo.cpp']]], + ['monte_5fcarlo_5fprogression_10',['monte_carlo_progression',['../monte__carlo_8hpp.html#ac97d0de27f2f0d50fc6ecf3a79f32826',1,'monte_carlo_progression(double T, int L, int cycles, const std::string filename): monte_carlo.cpp'],['../monte__carlo_8hpp.html#a89ddd777796c65eb2b289af11fc0ce09',1,'monte_carlo_progression(double T, int L, int cycles, int value, const std::string filename): monte_carlo.cpp'],['../monte__carlo_8cpp.html#ac97d0de27f2f0d50fc6ecf3a79f32826',1,'monte_carlo_progression(double T, int L, int cycles, const std::string filename): monte_carlo.cpp'],['../monte__carlo_8cpp.html#a89ddd777796c65eb2b289af11fc0ce09',1,'monte_carlo_progression(double T, int L, int cycles, int value, const std::string filename): monte_carlo.cpp']]], + ['monte_5fcarlo_5fserial_11',['monte_carlo_serial',['../monte__carlo_8hpp.html#a8f8d4c5e032ed8565a3ac518b32c6aed',1,'monte_carlo_serial(int L, double T, int cycles): monte_carlo.cpp'],['../monte__carlo_8cpp.html#a8f8d4c5e032ed8565a3ac518b32c6aed',1,'monte_carlo_serial(int L, double T, int cycles): monte_carlo.cpp']]] +]; diff --git a/docs/search/all_b.js b/docs/search/all_b.js new file mode 100644 index 0000000..9fae6f7 --- /dev/null +++ b/docs/search/all_b.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['neighbors_0',['neighbors',['../classIsingModel.html#a94093aaf30facca62737f2ac381fdbcd',1,'IsingModel']]] +]; diff --git a/docs/search/all_c.js b/docs/search/all_c.js new file mode 100644 index 0000000..fef9e21 --- /dev/null +++ b/docs/search/all_c.js @@ -0,0 +1,6 @@ +var searchData= +[ + ['pd_5festimate_0',['pd_estimate',['../monte__carlo_8hpp.html#a962f704ab35208bf6541eb3b707a9559',1,'pd_estimate(double T, int L, int cycles, const std::string filename): monte_carlo.cpp'],['../monte__carlo_8cpp.html#a962f704ab35208bf6541eb3b707a9559',1,'pd_estimate(double T, int L, int cycles, const std::string filename): monte_carlo.cpp']]], + ['phase_5ftransition_1',['phase_transition',['../monte__carlo_8hpp.html#a2dfe843fbb80e10a763f3260131a148e',1,'phase_transition(int L, double start_T, double end_T, int points_T, std::function< data_t(int, double, int)> monte_carlo, std::string outfile): monte_carlo.cpp'],['../monte__carlo_8cpp.html#a7df22ace588b4d229d1029ce766d0009',1,'phase_transition(int L, double start, double end, int points, std::function< data_t(int, double, int)> monte_carlo, std::string outfile): monte_carlo.cpp']]], + ['phase_5ftransition_5fmpi_2ecpp_2',['phase_transition_mpi.cpp',['../phase__transition__mpi_8cpp.html',1,'']]] +]; diff --git a/docs/search/all_d.js b/docs/search/all_d.js new file mode 100644 index 0000000..83e74c2 --- /dev/null +++ b/docs/search/all_d.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['scientific_5fformat_0',['scientific_format',['../utils_8hpp.html#a3529a74fd2a25d24de73d9d4e1c90835',1,'utils::scientific_format(double d, int width=20, int prec=10)'],['../utils_8hpp.html#ab3e89176433ddc9ba721b2eba3d08357',1,'utils::scientific_format(const std::vector< double > &v, int width=20, int prec=10)']]] +]; diff --git a/docs/search/all_e.js b/docs/search/all_e.js new file mode 100644 index 0000000..b656b4b --- /dev/null +++ b/docs/search/all_e.js @@ -0,0 +1,10 @@ +var searchData= +[ + ['t_0',['T',['../classIsingModel.html#a20fc4c0c99d8a119f70a1614784d4e5c',1,'IsingModel']]], + ['test_5f2x2_5flattice_1',['test_2x2_lattice',['../classIsingModelTest.html#a4ace7013fa2d257ad1747961da6bc4de',1,'IsingModelTest::test_2x2_lattice()'],['../monte__carlo_8hpp.html#aa8b4fc86b26f0e3e253ba5556d2d14dc',1,'test_2x2_lattice(): monte_carlo.hpp']]], + ['test_5finit_5ffunctions_2',['test_init_functions',['../classIsingModelTest.html#a717e5852ca51432a61fb6ed38da37931',1,'IsingModelTest']]], + ['test_5fsuite_2ecpp_3',['test_suite.cpp',['../test__suite_8cpp.html',1,'']]], + ['testlib_2ecpp_4',['testlib.cpp',['../testlib_8cpp.html',1,'']]], + ['testlib_2ehpp_5',['testlib.hpp',['../testlib_8hpp.html',1,'']]], + ['typedefs_2ehpp_6',['typedefs.hpp',['../typedefs_8hpp.html',1,'']]] +]; diff --git a/docs/search/all_f.js b/docs/search/all_f.js new file mode 100644 index 0000000..cd921db --- /dev/null +++ b/docs/search/all_f.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['utils_2ecpp_0',['utils.cpp',['../utils_8cpp.html',1,'']]], + ['utils_2ehpp_1',['utils.hpp',['../utils_8hpp.html',1,'']]] +]; diff --git a/docs/search/classes_0.js b/docs/search/classes_0.js new file mode 100644 index 0000000..05f5613 --- /dev/null +++ b/docs/search/classes_0.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['data_5ft_0',['data_t',['../classdata__t.html',1,'']]] +]; diff --git a/docs/search/classes_1.js b/docs/search/classes_1.js new file mode 100644 index 0000000..0ab648d --- /dev/null +++ b/docs/search/classes_1.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['isingmodel_0',['IsingModel',['../classIsingModel.html',1,'']]], + ['isingmodeltest_1',['IsingModelTest',['../classIsingModelTest.html',1,'']]] +]; diff --git a/docs/search/close.svg b/docs/search/close.svg new file mode 100644 index 0000000..a933eea --- /dev/null +++ b/docs/search/close.svg @@ -0,0 +1,31 @@ + + + + + + image/svg+xml + + + + + + + + diff --git a/docs/search/defines_0.js b/docs/search/defines_0.js new file mode 100644 index 0000000..1e5c227 --- /dev/null +++ b/docs/search/defines_0.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['_5f_5fmethod_5fname_5f_5f_0',['__METHOD_NAME__',['../utils_8hpp.html#a60dca3177fb9cb5256609adc7af55168',1,'utils.hpp']]] +]; diff --git a/docs/search/defines_1.js b/docs/search/defines_1.js new file mode 100644 index 0000000..e35967d --- /dev/null +++ b/docs/search/defines_1.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['assert_0',['ASSERT',['../testlib_8hpp.html#a73d4f21ad937dbc50a0c0538c78fd4f9',1,'testlib.hpp']]] +]; diff --git a/docs/search/defines_2.js b/docs/search/defines_2.js new file mode 100644 index 0000000..c6466cb --- /dev/null +++ b/docs/search/defines_2.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['debug_0',['DEBUG',['../utils_8hpp.html#aecc1f7a8a2493b9e021e5bff76a00a5b',1,'utils.hpp']]] +]; diff --git a/docs/search/defines_3.js b/docs/search/defines_3.js new file mode 100644 index 0000000..9d163ac --- /dev/null +++ b/docs/search/defines_3.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['k_5fb_0',['k_B',['../constants_8hpp.html#abfa7d6668c777f9516606394bbc9c414',1,'constants.hpp']]] +]; diff --git a/docs/search/files_0.js b/docs/search/files_0.js new file mode 100644 index 0000000..0648f09 --- /dev/null +++ b/docs/search/files_0.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['constants_2ehpp_0',['constants.hpp',['../constants_8hpp.html',1,'']]] +]; diff --git a/docs/search/files_1.js b/docs/search/files_1.js new file mode 100644 index 0000000..99d33f4 --- /dev/null +++ b/docs/search/files_1.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['data_5ftype_2ecpp_0',['data_type.cpp',['../data__type_8cpp.html',1,'']]], + ['data_5ftype_2ehpp_1',['data_type.hpp',['../data__type_8hpp.html',1,'']]] +]; diff --git a/docs/search/files_2.js b/docs/search/files_2.js new file mode 100644 index 0000000..172e9fd --- /dev/null +++ b/docs/search/files_2.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['isingmodel_2ecpp_0',['IsingModel.cpp',['../IsingModel_8cpp.html',1,'']]], + ['isingmodel_2ehpp_1',['IsingModel.hpp',['../IsingModel_8hpp.html',1,'']]] +]; diff --git a/docs/search/files_3.js b/docs/search/files_3.js new file mode 100644 index 0000000..4878898 --- /dev/null +++ b/docs/search/files_3.js @@ -0,0 +1,6 @@ +var searchData= +[ + ['main_2ecpp_0',['main.cpp',['../main_8cpp.html',1,'']]], + ['monte_5fcarlo_2ecpp_1',['monte_carlo.cpp',['../monte__carlo_8cpp.html',1,'']]], + ['monte_5fcarlo_2ehpp_2',['monte_carlo.hpp',['../monte__carlo_8hpp.html',1,'']]] +]; diff --git a/docs/search/files_4.js b/docs/search/files_4.js new file mode 100644 index 0000000..44579d3 --- /dev/null +++ b/docs/search/files_4.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['phase_5ftransition_5fmpi_2ecpp_0',['phase_transition_mpi.cpp',['../phase__transition__mpi_8cpp.html',1,'']]] +]; diff --git a/docs/search/files_5.js b/docs/search/files_5.js new file mode 100644 index 0000000..f687ddb --- /dev/null +++ b/docs/search/files_5.js @@ -0,0 +1,7 @@ +var searchData= +[ + ['test_5fsuite_2ecpp_0',['test_suite.cpp',['../test__suite_8cpp.html',1,'']]], + ['testlib_2ecpp_1',['testlib.cpp',['../testlib_8cpp.html',1,'']]], + ['testlib_2ehpp_2',['testlib.hpp',['../testlib_8hpp.html',1,'']]], + ['typedefs_2ehpp_3',['typedefs.hpp',['../typedefs_8hpp.html',1,'']]] +]; diff --git a/docs/search/files_6.js b/docs/search/files_6.js new file mode 100644 index 0000000..cd921db --- /dev/null +++ b/docs/search/files_6.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['utils_2ecpp_0',['utils.cpp',['../utils_8cpp.html',1,'']]], + ['utils_2ehpp_1',['utils.hpp',['../utils_8hpp.html',1,'']]] +]; diff --git a/docs/search/functions_0.js b/docs/search/functions_0.js new file mode 100644 index 0000000..4199254 --- /dev/null +++ b/docs/search/functions_0.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['dirname_0',['dirname',['../utils_8hpp.html#aed026119193a9bbe076671809ff0f430',1,'utils']]] +]; diff --git a/docs/search/functions_1.js b/docs/search/functions_1.js new file mode 100644 index 0000000..45fb121 --- /dev/null +++ b/docs/search/functions_1.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['get_5fe_0',['get_E',['../classIsingModel.html#aaa0787d964b004a17869811a5e947ff5',1,'IsingModel']]], + ['get_5fm_1',['get_M',['../classIsingModel.html#aa5701496e6483bc4668c486d6d3af625',1,'IsingModel']]] +]; diff --git a/docs/search/functions_2.js b/docs/search/functions_2.js new file mode 100644 index 0000000..7bbfb9b --- /dev/null +++ b/docs/search/functions_2.js @@ -0,0 +1,9 @@ +var searchData= +[ + ['initialize_5fenergy_0',['initialize_energy',['../classIsingModel.html#a59fced38c695e2fa647f53be81b9d2a1',1,'IsingModel']]], + ['initialize_5fenergy_5fdiff_1',['initialize_energy_diff',['../classIsingModel.html#aff9a1201933fd5408845a1447e4895b4',1,'IsingModel']]], + ['initialize_5flattice_2',['initialize_lattice',['../classIsingModel.html#a34a4710949b4a70f3e37ca223aefcf8a',1,'IsingModel']]], + ['initialize_5fmagnetization_3',['initialize_magnetization',['../classIsingModel.html#a926cf4964d190d2ce23e5a17201787a4',1,'IsingModel']]], + ['initialize_5fneighbors_4',['initialize_neighbors',['../classIsingModel.html#a6776109105051597c275670dabd0054a',1,'IsingModel']]], + ['isingmodel_5',['IsingModel',['../classIsingModel.html#acf281f6f5ed02911ca6ab07004449864',1,'IsingModel::IsingModel()'],['../classIsingModel.html#a4a39ee7fbfbbf566f75bc28900ca9ea5',1,'IsingModel::IsingModel(int L, double T)'],['../classIsingModel.html#a46c9446e94854452f715d307c77c1c15',1,'IsingModel::IsingModel(int L, double T, int val)']]] +]; diff --git a/docs/search/functions_3.js b/docs/search/functions_3.js new file mode 100644 index 0000000..de0435f --- /dev/null +++ b/docs/search/functions_3.js @@ -0,0 +1,11 @@ +var searchData= +[ + ['m_5fassert_0',['m_assert',['../testlib_8hpp.html#a39abb7cba0535176ed62aae136d2fcc7',1,'details']]], + ['main_1',['main',['../main_8cpp.html#a3c04138a5bfe5d72780bb7e82a18e627',1,'main(int argc, char **argv): main.cpp'],['../phase__transition__mpi_8cpp.html#a3c04138a5bfe5d72780bb7e82a18e627',1,'main(int argc, char **argv): phase_transition_mpi.cpp'],['../test__suite_8cpp.html#ae66f6b31b5ad750f1fe042a706a4e3d4',1,'main(): test_suite.cpp']]], + ['methodname_2',['methodName',['../utils_8hpp.html#a178c4922157666a6e9c127c2ffd96346',1,'details']]], + ['metropolis_3',['Metropolis',['../classIsingModel.html#a56559d68dc9aaff1976d84b157f43488',1,'IsingModel']]], + ['mkpath_4',['mkpath',['../utils_8hpp.html#a2b45adc86b70f42021582994e83fa00d',1,'utils']]], + ['monte_5fcarlo_5fparallel_5',['monte_carlo_parallel',['../monte__carlo_8hpp.html#acc34e2049a5030874f6f548f3adab958',1,'monte_carlo_parallel(int L, double T, int cycles): monte_carlo.cpp'],['../monte__carlo_8cpp.html#acc34e2049a5030874f6f548f3adab958',1,'monte_carlo_parallel(int L, double T, int cycles): monte_carlo.cpp']]], + ['monte_5fcarlo_5fprogression_6',['monte_carlo_progression',['../monte__carlo_8hpp.html#ac97d0de27f2f0d50fc6ecf3a79f32826',1,'monte_carlo_progression(double T, int L, int cycles, const std::string filename): monte_carlo.cpp'],['../monte__carlo_8hpp.html#a89ddd777796c65eb2b289af11fc0ce09',1,'monte_carlo_progression(double T, int L, int cycles, int value, const std::string filename): monte_carlo.cpp'],['../monte__carlo_8cpp.html#ac97d0de27f2f0d50fc6ecf3a79f32826',1,'monte_carlo_progression(double T, int L, int cycles, const std::string filename): monte_carlo.cpp'],['../monte__carlo_8cpp.html#a89ddd777796c65eb2b289af11fc0ce09',1,'monte_carlo_progression(double T, int L, int cycles, int value, const std::string filename): monte_carlo.cpp']]], + ['monte_5fcarlo_5fserial_7',['monte_carlo_serial',['../monte__carlo_8hpp.html#a8f8d4c5e032ed8565a3ac518b32c6aed',1,'monte_carlo_serial(int L, double T, int cycles): monte_carlo.cpp'],['../monte__carlo_8cpp.html#a8f8d4c5e032ed8565a3ac518b32c6aed',1,'monte_carlo_serial(int L, double T, int cycles): monte_carlo.cpp']]] +]; diff --git a/docs/search/functions_4.js b/docs/search/functions_4.js new file mode 100644 index 0000000..4577437 --- /dev/null +++ b/docs/search/functions_4.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['pd_5festimate_0',['pd_estimate',['../monte__carlo_8hpp.html#a962f704ab35208bf6541eb3b707a9559',1,'pd_estimate(double T, int L, int cycles, const std::string filename): monte_carlo.cpp'],['../monte__carlo_8cpp.html#a962f704ab35208bf6541eb3b707a9559',1,'pd_estimate(double T, int L, int cycles, const std::string filename): monte_carlo.cpp']]], + ['phase_5ftransition_1',['phase_transition',['../monte__carlo_8hpp.html#a2dfe843fbb80e10a763f3260131a148e',1,'phase_transition(int L, double start_T, double end_T, int points_T, std::function< data_t(int, double, int)> monte_carlo, std::string outfile): monte_carlo.cpp'],['../monte__carlo_8cpp.html#a7df22ace588b4d229d1029ce766d0009',1,'phase_transition(int L, double start, double end, int points, std::function< data_t(int, double, int)> monte_carlo, std::string outfile): monte_carlo.cpp']]] +]; diff --git a/docs/search/functions_5.js b/docs/search/functions_5.js new file mode 100644 index 0000000..83e74c2 --- /dev/null +++ b/docs/search/functions_5.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['scientific_5fformat_0',['scientific_format',['../utils_8hpp.html#a3529a74fd2a25d24de73d9d4e1c90835',1,'utils::scientific_format(double d, int width=20, int prec=10)'],['../utils_8hpp.html#ab3e89176433ddc9ba721b2eba3d08357',1,'utils::scientific_format(const std::vector< double > &v, int width=20, int prec=10)']]] +]; diff --git a/docs/search/functions_6.js b/docs/search/functions_6.js new file mode 100644 index 0000000..23c5afa --- /dev/null +++ b/docs/search/functions_6.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['test_5f2x2_5flattice_0',['test_2x2_lattice',['../classIsingModelTest.html#a4ace7013fa2d257ad1747961da6bc4de',1,'IsingModelTest::test_2x2_lattice()'],['../monte__carlo_8hpp.html#aa8b4fc86b26f0e3e253ba5556d2d14dc',1,'test_2x2_lattice(): monte_carlo.hpp']]], + ['test_5finit_5ffunctions_1',['test_init_functions',['../classIsingModelTest.html#a717e5852ca51432a61fb6ed38da37931',1,'IsingModelTest']]] +]; diff --git a/docs/search/functions_7.js b/docs/search/functions_7.js new file mode 100644 index 0000000..c18dff8 --- /dev/null +++ b/docs/search/functions_7.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['test_5f2x2_5flattice_0',['test_2x2_lattice',['../monte__carlo_8hpp.html#a64fd72aa1f6ff03e36c35f6265d0f874',1,'test_2x2_lattice(double tol, uint max_cycles): monte_carlo.cpp'],['../monte__carlo_8cpp.html#a64fd72aa1f6ff03e36c35f6265d0f874',1,'test_2x2_lattice(double tol, uint max_cycles): monte_carlo.cpp']]], + ['test_5finit_5ffunctions_1',['test_init_functions',['../classIsingModelTest.html#a717e5852ca51432a61fb6ed38da37931',1,'IsingModelTest']]] +]; diff --git a/docs/search/mag.svg b/docs/search/mag.svg new file mode 100644 index 0000000..9f46b30 --- /dev/null +++ b/docs/search/mag.svg @@ -0,0 +1,37 @@ + + + + + + image/svg+xml + + + + + + + + + diff --git a/docs/search/mag_d.svg b/docs/search/mag_d.svg new file mode 100644 index 0000000..b9a814c --- /dev/null +++ b/docs/search/mag_d.svg @@ -0,0 +1,37 @@ + + + + + + image/svg+xml + + + + + + + + + diff --git a/docs/search/mag_sel.svg b/docs/search/mag_sel.svg new file mode 100644 index 0000000..03626f6 --- /dev/null +++ b/docs/search/mag_sel.svg @@ -0,0 +1,74 @@ + + + + + + + + image/svg+xml + + + + + + + + + + + diff --git a/docs/search/mag_seld.svg b/docs/search/mag_seld.svg new file mode 100644 index 0000000..6e720dc --- /dev/null +++ b/docs/search/mag_seld.svg @@ -0,0 +1,74 @@ + + + + + + + + image/svg+xml + + + + + + + + + + + diff --git a/docs/search/pages_0.js b/docs/search/pages_0.js new file mode 100644 index 0000000..8a2ba60 --- /dev/null +++ b/docs/search/pages_0.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['bug_20list_0',['Bug List',['../bug.html',1,'']]] +]; diff --git a/docs/search/pages_1.js b/docs/search/pages_1.js new file mode 100644 index 0000000..ad9bb05 --- /dev/null +++ b/docs/search/pages_1.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['ising_20model_0',['Ising Model',['../index.html',1,'']]] +]; diff --git a/docs/search/search.css b/docs/search/search.css new file mode 100644 index 0000000..9d76291 --- /dev/null +++ b/docs/search/search.css @@ -0,0 +1,291 @@ +/*---------------- Search Box positioning */ + +#main-menu > li:last-child { + /* This
  • object is the parent of the search bar */ + display: flex; + justify-content: center; + align-items: center; + height: 36px; + margin-right: 1em; +} + +/*---------------- Search box styling */ + +.SRPage * { + font-weight: normal; + line-height: normal; +} + +dark-mode-toggle { + margin-left: 5px; + display: flex; + float: right; +} + +#MSearchBox { + display: inline-block; + white-space : nowrap; + background: white; + border-radius: 0.65em; + box-shadow: inset 0.5px 0.5px 3px 0px #555; + z-index: 102; +} + +#MSearchBox .left { + display: inline-block; + vertical-align: middle; + height: 1.4em; +} + +#MSearchSelect { + display: inline-block; + vertical-align: middle; + width: 20px; + height: 19px; + background-image: url('mag_sel.svg'); + margin: 0 0 0 0.3em; + padding: 0; +} + +#MSearchSelectExt { + display: inline-block; + vertical-align: middle; + width: 10px; + height: 19px; + background-image: url('mag.svg'); + margin: 0 0 0 0.5em; + padding: 0; +} + + +#MSearchField { + display: inline-block; + vertical-align: middle; + width: 7.5em; + height: 19px; + margin: 0 0.15em; + padding: 0; + line-height: 1em; + border:none; + color: #909090; + outline: none; + font-family: Arial,Verdana,sans-serif; + -webkit-border-radius: 0px; + border-radius: 0px; + background: none; +} + +@media(hover: none) { + /* to avoid zooming on iOS */ + #MSearchField { + font-size: 16px; + } +} + +#MSearchBox .right { + display: inline-block; + vertical-align: middle; + width: 1.4em; + height: 1.4em; +} + +#MSearchClose { + display: none; + font-size: inherit; + background : none; + border: none; + margin: 0; + padding: 0; + outline: none; + +} + +#MSearchCloseImg { + padding: 0.3em; + margin: 0; +} + +.MSearchBoxActive #MSearchField { + color: black; +} + + + +/*---------------- Search filter selection */ + +#MSearchSelectWindow { + display: none; + position: absolute; + left: 0; top: 0; + border: 1px solid #90A5CE; + background-color: #F9FAFC; + z-index: 10001; + padding-top: 4px; + padding-bottom: 4px; + -moz-border-radius: 4px; + -webkit-border-top-left-radius: 4px; + -webkit-border-top-right-radius: 4px; + -webkit-border-bottom-left-radius: 4px; + -webkit-border-bottom-right-radius: 4px; + -webkit-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); +} + +.SelectItem { + font: 8pt Arial,Verdana,sans-serif; + padding-left: 2px; + padding-right: 12px; + border: 0px; +} + +span.SelectionMark { + margin-right: 4px; + font-family: monospace,fixed; + outline-style: none; + text-decoration: none; +} + +a.SelectItem { + display: block; + outline-style: none; + color: black; + text-decoration: none; + padding-left: 6px; + padding-right: 12px; +} + +a.SelectItem:focus, +a.SelectItem:active { + color: black; + outline-style: none; + text-decoration: none; +} + +a.SelectItem:hover { + color: white; + background-color: #3D578C; + outline-style: none; + text-decoration: none; + cursor: pointer; + display: block; +} + +/*---------------- Search results window */ + +iframe#MSearchResults { + /*width: 60ex;*/ + height: 15em; +} + +#MSearchResultsWindow { + display: none; + position: absolute; + left: 0; top: 0; + border: 1px solid black; + background-color: #EEF1F7; + z-index:10000; + width: 300px; + height: 400px; + overflow: auto; +} + +/* ----------------------------------- */ + + +#SRIndex { + clear:both; +} + +.SREntry { + font-size: 10pt; + padding-left: 1ex; +} + +.SRPage .SREntry { + font-size: 8pt; + padding: 1px 5px; +} + +div.SRPage { + margin: 5px 2px; + background-color: #EEF1F7; +} + +.SRChildren { + padding-left: 3ex; padding-bottom: .5em +} + +.SRPage .SRChildren { + display: none; +} + +.SRSymbol { + font-weight: bold; + color: #425E97; + font-family: Arial,Verdana,sans-serif; + text-decoration: none; + outline: none; +} + +a.SRScope { + display: block; + color: #425E97; + font-family: Arial,Verdana,sans-serif; + font-size: 8pt; + text-decoration: none; + outline: none; +} + +a.SRSymbol:focus, a.SRSymbol:active, +a.SRScope:focus, a.SRScope:active { + text-decoration: underline; +} + +span.SRScope { + padding-left: 4px; + font-family: Arial,Verdana,sans-serif; +} + +.SRPage .SRStatus { + padding: 2px 5px; + font-size: 8pt; + font-style: italic; + font-family: Arial,Verdana,sans-serif; +} + +.SRResult { + display: none; +} + +div.searchresults { + margin-left: 10px; + margin-right: 10px; +} + +/*---------------- External search page results */ + +.pages b { + color: white; + padding: 5px 5px 3px 5px; + background-image: url("../tab_a.png"); + background-repeat: repeat-x; + text-shadow: 0 1px 1px #000000; +} + +.pages { + line-height: 17px; + margin-left: 4px; + text-decoration: none; +} + +.hl { + font-weight: bold; +} + +#searchresults { + margin-bottom: 20px; +} + +.searchpages { + margin-top: 10px; +} + diff --git a/docs/search/search.js b/docs/search/search.js new file mode 100644 index 0000000..e103a26 --- /dev/null +++ b/docs/search/search.js @@ -0,0 +1,816 @@ +/* + @licstart The following is the entire license notice for the JavaScript code in this file. + + The MIT License (MIT) + + Copyright (C) 1997-2020 by Dimitri van Heesch + + Permission is hereby granted, free of charge, to any person obtaining a copy of this software + and associated documentation files (the "Software"), to deal in the Software without restriction, + including without limitation the rights to use, copy, modify, merge, publish, distribute, + sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is + furnished to do so, subject to the following conditions: + + The above copyright notice and this permission notice shall be included in all copies or + substantial portions of the Software. + + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING + BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND + NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, + DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + + @licend The above is the entire license notice for the JavaScript code in this file + */ +function convertToId(search) +{ + var result = ''; + for (i=0;i do a search + { + this.Search(); + } + } + + this.OnSearchSelectKey = function(evt) + { + var e = (evt) ? evt : window.event; // for IE + if (e.keyCode==40 && this.searchIndex0) // Up + { + this.searchIndex--; + this.OnSelectItem(this.searchIndex); + } + else if (e.keyCode==13 || e.keyCode==27) + { + this.OnSelectItem(this.searchIndex); + this.CloseSelectionWindow(); + this.DOMSearchField().focus(); + } + return false; + } + + // --------- Actions + + // Closes the results window. + this.CloseResultsWindow = function() + { + this.DOMPopupSearchResultsWindow().style.display = 'none'; + this.DOMSearchClose().style.display = 'none'; + this.Activate(false); + } + + this.CloseSelectionWindow = function() + { + this.DOMSearchSelectWindow().style.display = 'none'; + } + + // Performs a search. + this.Search = function() + { + this.keyTimeout = 0; + + // strip leading whitespace + var searchValue = this.DOMSearchField().value.replace(/^ +/, ""); + + var code = searchValue.toLowerCase().charCodeAt(0); + var idxChar = searchValue.substr(0, 1).toLowerCase(); + if ( 0xD800 <= code && code <= 0xDBFF && searchValue > 1) // surrogate pair + { + idxChar = searchValue.substr(0, 2); + } + + var jsFile; + + var idx = indexSectionsWithContent[this.searchIndex].indexOf(idxChar); + if (idx!=-1) + { + var hexCode=idx.toString(16); + jsFile = this.resultsPath + indexSectionNames[this.searchIndex] + '_' + hexCode + '.js'; + } + + var loadJS = function(url, impl, loc){ + var scriptTag = document.createElement('script'); + scriptTag.src = url; + scriptTag.onload = impl; + scriptTag.onreadystatechange = impl; + loc.appendChild(scriptTag); + } + + var domPopupSearchResultsWindow = this.DOMPopupSearchResultsWindow(); + var domSearchBox = this.DOMSearchBox(); + var domPopupSearchResults = this.DOMPopupSearchResults(); + var domSearchClose = this.DOMSearchClose(); + var resultsPath = this.resultsPath; + + var handleResults = function() { + document.getElementById("Loading").style.display="none"; + if (typeof searchData !== 'undefined') { + createResults(resultsPath); + document.getElementById("NoMatches").style.display="none"; + } + + searchResults.Search(searchValue); + + if (domPopupSearchResultsWindow.style.display!='block') + { + domSearchClose.style.display = 'inline-block'; + var left = getXPos(domSearchBox) + 150; + var top = getYPos(domSearchBox) + 20; + domPopupSearchResultsWindow.style.display = 'block'; + left -= domPopupSearchResults.offsetWidth; + var maxWidth = document.body.clientWidth; + var maxHeight = document.body.clientHeight; + var width = 300; + if (left<10) left=10; + if (width+left+8>maxWidth) width=maxWidth-left-8; + var height = 400; + if (height+top+8>maxHeight) height=maxHeight-top-8; + domPopupSearchResultsWindow.style.top = top + 'px'; + domPopupSearchResultsWindow.style.left = left + 'px'; + domPopupSearchResultsWindow.style.width = width + 'px'; + domPopupSearchResultsWindow.style.height = height + 'px'; + } + } + + if (jsFile) { + loadJS(jsFile, handleResults, this.DOMPopupSearchResultsWindow()); + } else { + handleResults(); + } + + this.lastSearchValue = searchValue; + } + + // -------- Activation Functions + + // Activates or deactivates the search panel, resetting things to + // their default values if necessary. + this.Activate = function(isActive) + { + if (isActive || // open it + this.DOMPopupSearchResultsWindow().style.display == 'block' + ) + { + this.DOMSearchBox().className = 'MSearchBoxActive'; + this.searchActive = true; + } + else if (!isActive) // directly remove the panel + { + this.DOMSearchBox().className = 'MSearchBoxInactive'; + this.searchActive = false; + this.lastSearchValue = '' + this.lastResultsPage = ''; + this.DOMSearchField().value = ''; + } + } +} + +// ----------------------------------------------------------------------- + +// The class that handles everything on the search results page. +function SearchResults(name) +{ + // The number of matches from the last run of . + this.lastMatchCount = 0; + this.lastKey = 0; + this.repeatOn = false; + + // Toggles the visibility of the passed element ID. + this.FindChildElement = function(id) + { + var parentElement = document.getElementById(id); + var element = parentElement.firstChild; + + while (element && element!=parentElement) + { + if (element.nodeName.toLowerCase() == 'div' && element.className == 'SRChildren') + { + return element; + } + + if (element.nodeName.toLowerCase() == 'div' && element.hasChildNodes()) + { + element = element.firstChild; + } + else if (element.nextSibling) + { + element = element.nextSibling; + } + else + { + do + { + element = element.parentNode; + } + while (element && element!=parentElement && !element.nextSibling); + + if (element && element!=parentElement) + { + element = element.nextSibling; + } + } + } + } + + this.Toggle = function(id) + { + var element = this.FindChildElement(id); + if (element) + { + if (element.style.display == 'block') + { + element.style.display = 'none'; + } + else + { + element.style.display = 'block'; + } + } + } + + // Searches for the passed string. If there is no parameter, + // it takes it from the URL query. + // + // Always returns true, since other documents may try to call it + // and that may or may not be possible. + this.Search = function(search) + { + if (!search) // get search word from URL + { + search = window.location.search; + search = search.substring(1); // Remove the leading '?' + search = unescape(search); + } + + search = search.replace(/^ +/, ""); // strip leading spaces + search = search.replace(/ +$/, ""); // strip trailing spaces + search = search.toLowerCase(); + search = convertToId(search); + + var resultRows = document.getElementsByTagName("div"); + var matches = 0; + + var i = 0; + while (i < resultRows.length) + { + var row = resultRows.item(i); + if (row.className == "SRResult") + { + var rowMatchName = row.id.toLowerCase(); + rowMatchName = rowMatchName.replace(/^sr\d*_/, ''); // strip 'sr123_' + + if (search.length<=rowMatchName.length && + rowMatchName.substr(0, search.length)==search) + { + row.style.display = 'block'; + matches++; + } + else + { + row.style.display = 'none'; + } + } + i++; + } + document.getElementById("Searching").style.display='none'; + if (matches == 0) // no results + { + document.getElementById("NoMatches").style.display='block'; + } + else // at least one result + { + document.getElementById("NoMatches").style.display='none'; + } + this.lastMatchCount = matches; + return true; + } + + // return the first item with index index or higher that is visible + this.NavNext = function(index) + { + var focusItem; + while (1) + { + var focusName = 'Item'+index; + focusItem = document.getElementById(focusName); + if (focusItem && focusItem.parentNode.parentNode.style.display=='block') + { + break; + } + else if (!focusItem) // last element + { + break; + } + focusItem=null; + index++; + } + return focusItem; + } + + this.NavPrev = function(index) + { + var focusItem; + while (1) + { + var focusName = 'Item'+index; + focusItem = document.getElementById(focusName); + if (focusItem && focusItem.parentNode.parentNode.style.display=='block') + { + break; + } + else if (!focusItem) // last element + { + break; + } + focusItem=null; + index--; + } + return focusItem; + } + + this.ProcessKeys = function(e) + { + if (e.type == "keydown") + { + this.repeatOn = false; + this.lastKey = e.keyCode; + } + else if (e.type == "keypress") + { + if (!this.repeatOn) + { + if (this.lastKey) this.repeatOn = true; + return false; // ignore first keypress after keydown + } + } + else if (e.type == "keyup") + { + this.lastKey = 0; + this.repeatOn = false; + } + return this.lastKey!=0; + } + + this.Nav = function(evt,itemIndex) + { + var e = (evt) ? evt : window.event; // for IE + if (e.keyCode==13) return true; + if (!this.ProcessKeys(e)) return false; + + if (this.lastKey==38) // Up + { + var newIndex = itemIndex-1; + var focusItem = this.NavPrev(newIndex); + if (focusItem) + { + var child = this.FindChildElement(focusItem.parentNode.parentNode.id); + if (child && child.style.display == 'block') // children visible + { + var n=0; + var tmpElem; + while (1) // search for last child + { + tmpElem = document.getElementById('Item'+newIndex+'_c'+n); + if (tmpElem) + { + focusItem = tmpElem; + } + else // found it! + { + break; + } + n++; + } + } + } + if (focusItem) + { + focusItem.focus(); + } + else // return focus to search field + { + document.getElementById("MSearchField").focus(); + } + } + else if (this.lastKey==40) // Down + { + var newIndex = itemIndex+1; + var focusItem; + var item = document.getElementById('Item'+itemIndex); + var elem = this.FindChildElement(item.parentNode.parentNode.id); + if (elem && elem.style.display == 'block') // children visible + { + focusItem = document.getElementById('Item'+itemIndex+'_c0'); + } + if (!focusItem) focusItem = this.NavNext(newIndex); + if (focusItem) focusItem.focus(); + } + else if (this.lastKey==39) // Right + { + var item = document.getElementById('Item'+itemIndex); + var elem = this.FindChildElement(item.parentNode.parentNode.id); + if (elem) elem.style.display = 'block'; + } + else if (this.lastKey==37) // Left + { + var item = document.getElementById('Item'+itemIndex); + var elem = this.FindChildElement(item.parentNode.parentNode.id); + if (elem) elem.style.display = 'none'; + } + else if (this.lastKey==27) // Escape + { + searchBox.CloseResultsWindow(); + document.getElementById("MSearchField").focus(); + } + else if (this.lastKey==13) // Enter + { + return true; + } + return false; + } + + this.NavChild = function(evt,itemIndex,childIndex) + { + var e = (evt) ? evt : window.event; // for IE + if (e.keyCode==13) return true; + if (!this.ProcessKeys(e)) return false; + + if (this.lastKey==38) // Up + { + if (childIndex>0) + { + var newIndex = childIndex-1; + document.getElementById('Item'+itemIndex+'_c'+newIndex).focus(); + } + else // already at first child, jump to parent + { + document.getElementById('Item'+itemIndex).focus(); + } + } + else if (this.lastKey==40) // Down + { + var newIndex = childIndex+1; + var elem = document.getElementById('Item'+itemIndex+'_c'+newIndex); + if (!elem) // last child, jump to parent next parent + { + elem = this.NavNext(itemIndex+1); + } + if (elem) + { + elem.focus(); + } + } + else if (this.lastKey==27) // Escape + { + searchBox.CloseResultsWindow(); + document.getElementById("MSearchField").focus(); + } + else if (this.lastKey==13) // Enter + { + return true; + } + return false; + } +} + +function setKeyActions(elem,action) +{ + elem.setAttribute('onkeydown',action); + elem.setAttribute('onkeypress',action); + elem.setAttribute('onkeyup',action); +} + +function setClassAttr(elem,attr) +{ + elem.setAttribute('class',attr); + elem.setAttribute('className',attr); +} + +function createResults(resultsPath) +{ + var results = document.getElementById("SRResults"); + results.innerHTML = ''; + for (var e=0; e-{AmhX=Jf(#6djGiuzAr*{o?=JLmPLyc> z_*`QK&+BH@jWrYJ7>r6%keRM@)Qyv8R=enp0jiI>aWlGyB58O zFVR20d+y`K7vDw(hJF3;>dD*3-?v=<8M)@x|EEGLnJsniYK!2U1 Y!`|5biEc?d1`HDhPgg&ebxsLQ02F6;9RL6T literal 0 HcmV?d00001 diff --git a/docs/splitbard.png b/docs/splitbard.png new file mode 100644 index 0000000000000000000000000000000000000000..8367416d757fd7b6dc4272b6432dc75a75abd068 GIT binary patch literal 282 zcmeAS@N?(olHy`uVBq!ia0vp^Yzz!63>-{AmhX=Jf@VhhFKy35^fiT zT~&lUj3=cDh^%3HDY9k5CEku}PHXNoNC(_$U3XPb&Q*ME25pT;2(*BOgAf<+R$lzakPG`kF31()Fx{L5Wrac|GQzjeE= zueY1`Ze{#x<8=S|`~MgGetGce)#vN&|J{Cd^tS%;tBYTo?+^d68<#n_Y_xx`J||4O V@QB{^CqU0Kc)I$ztaD0e0svEzbJzd? literal 0 HcmV?d00001 diff --git a/docs/structdata__t-members.html b/docs/structdata__t-members.html new file mode 100644 index 0000000..b5b2dc2 --- /dev/null +++ b/docs/structdata__t-members.html @@ -0,0 +1,121 @@ + + + + + + + +2 Dimensional Ising Model: Member List + + + + + + + + + + + + + + + + +
    +
    + + + + + + +
    +
    2 Dimensional Ising Model +
    +
    Simulate the change in energy and magnetization in a ferro magnet
    +
    +
    + + + + + + + +
    +
    + +
    +
    +
    + +
    + +
    +
    + + +
    +
    +
    +
    +
    +
    Loading...
    +
    Searching...
    +
    No Matches
    +
    +
    +
    +
    + +
    +
    data_t Member List
    +
    +
    + +

    This is the complete list of members for data_t, including all inherited members.

    + + + + + + +
    Edata_t
    E2data_t
    Mdata_t
    M2data_t
    M_absdata_t
    +
    + + + + diff --git a/docs/structdata__t.html b/docs/structdata__t.html new file mode 100644 index 0000000..2e81fdf --- /dev/null +++ b/docs/structdata__t.html @@ -0,0 +1,239 @@ + + + + + + + +2 Dimensional Ising Model: data_t Struct Reference + + + + + + + + + + + + + + + + +
    +
    + + + + + + +
    +
    2 Dimensional Ising Model +
    +
    Simulate the change in energy and magnetization in a ferro magnet
    +
    +
    + + + + + + + +
    +
    + +
    +
    +
    + +
    + +
    +
    + + +
    +
    +
    +
    +
    +
    Loading...
    +
    Searching...
    +
    No Matches
    +
    +
    +
    +
    + +
    + +
    data_t Struct Reference
    +
    +
    + +

    Data structure that contains the data needed for the project. + More...

    + +

    #include <data_type.hpp>

    + + + + + + + + + + + + + + + + + +

    +Public Attributes

    double E = 0.
     The expected energy.
     
    double M = 0.
     The expected magnetization.
     
    double E2 = 0.
     The expected variance of the energy.
     
    double M2 = 0.
     The expected variance of magnetization.
     
    double M_abs = 0.
     The expected absolute magnetization.
     
    +

    Detailed Description

    +

    Data structure that contains the data needed for the project.

    + +

    Definition at line 19 of file data_type.hpp.

    +

    Member Data Documentation

    + +

    ◆ E

    + +
    +
    + + + + +
    double data_t::E = 0.
    +
    + +

    The expected energy.

    + +

    Definition at line 20 of file data_type.hpp.

    + +
    +
    + +

    ◆ E2

    + +
    +
    + + + + +
    double data_t::E2 = 0.
    +
    + +

    The expected variance of the energy.

    + +

    Definition at line 22 of file data_type.hpp.

    + +
    +
    + +

    ◆ M

    + +
    +
    + + + + +
    double data_t::M = 0.
    +
    + +

    The expected magnetization.

    + +

    Definition at line 21 of file data_type.hpp.

    + +
    +
    + +

    ◆ M2

    + +
    +
    + + + + +
    double data_t::M2 = 0.
    +
    + +

    The expected variance of magnetization.

    + +

    Definition at line 23 of file data_type.hpp.

    + +
    +
    + +

    ◆ M_abs

    + +
    +
    + + + + +
    double data_t::M_abs = 0.
    +
    + +

    The expected absolute magnetization.

    + +

    Definition at line 24 of file data_type.hpp.

    + +
    +
    +
    The documentation for this struct was generated from the following file: +
    +
    + + + + diff --git a/docs/structdata__t.js b/docs/structdata__t.js new file mode 100644 index 0000000..d433970 --- /dev/null +++ b/docs/structdata__t.js @@ -0,0 +1,8 @@ +var structdata__t = +[ + [ "E", "structdata__t.html#a6c1a196d96e177b11ca98c61fae35a2e", null ], + [ "E2", "structdata__t.html#abb622f9c6cc5ffb9dddb151d2e202f72", null ], + [ "M", "structdata__t.html#ad08d2488bf913c626157471cf6e8a46a", null ], + [ "M2", "structdata__t.html#a71ae3cd4460f2c66239500c11804e70b", null ], + [ "M_abs", "structdata__t.html#a586475e0f71322dffda2e75f228ab24b", null ] +]; \ No newline at end of file diff --git a/docs/sync_off.png b/docs/sync_off.png new file mode 100644 index 0000000000000000000000000000000000000000..3b443fc62892114406e3d399421b2a881b897acc GIT binary patch literal 853 zcmV-b1FHOqP)oT|#XixUYy%lpuf3i8{fX!o zUyDD0jOrAiT^tq>fLSOOABs-#u{dV^F$b{L9&!2=9&RmV;;8s^x&UqB$PCj4FdKbh zoB1WTskPUPu05XzFbA}=KZ-GP1fPpAfSs>6AHb12UlR%-i&uOlTpFNS7{jm@mkU1V zh`nrXr~+^lsV-s1dkZOaI|kYyVj3WBpPCY{n~yd%u%e+d=f%`N0FItMPtdgBb@py; zq@v6NVArhyTC7)ULw-Jy8y42S1~4n(3LkrW8mW(F-4oXUP3E`e#g**YyqI7h-J2zK zK{m9##m4ri!7N>CqQqCcnI3hqo1I;Yh&QLNY4T`*ptiQGozK>FF$!$+84Z`xwmeMh zJ0WT+OH$WYFALEaGj2_l+#DC3t7_S`vHpSivNeFbP6+r50cO8iu)`7i%Z4BTPh@_m3Tk!nAm^)5Bqnr%Ov|Baunj#&RPtRuK& z4RGz|D5HNrW83-#ydk}tVKJrNmyYt-sTxLGlJY5nc&Re zU4SgHNPx8~Yxwr$bsju?4q&%T1874xxzq+_%?h8_ofw~(bld=o3iC)LUNR*BY%c0y zWd_jX{Y8`l%z+ol1$@Qa?Cy!(0CVIEeYpKZ`(9{z>3$CIe;pJDQk$m3p}$>xBm4lb zKo{4S)`wdU9Ba9jJbVJ0C=SOefZe%d$8=2r={nu<_^a3~>c#t_U6dye5)JrR(_a^E f@}b6j1K9lwFJq@>o)+Ry00000NkvXXu0mjfWa5j* literal 0 HcmV?d00001 diff --git a/docs/sync_on.png b/docs/sync_on.png new file mode 100644 index 0000000000000000000000000000000000000000..e08320fb64e6fa33b573005ed6d8fe294e19db76 GIT binary patch literal 845 zcmV-T1G4;yP)Y;xxyHF2B5Wzm| zOOGupOTn@c(JmBOl)e;XMNnZuiTJP>rM8<|Q`7I_))aP?*T)ow&n59{}X4$3Goat zgjs?*aasfbrokzG5cT4K=uG`E14xZl@z)F={P0Y^?$4t z>v!teRnNZym<6h{7sLyF1V0HsfEl+l6TrZpsfr1}luH~F7L}ktXu|*uVX^RG$L0`K zWs3j|0tIvVe(N%_?2{(iCPFGf#B6Hjy6o&}D$A%W%jfO8_W%ZO#-mh}EM$LMn7joJ z05dHr!5Y92g+31l<%i1(=L1a1pXX+OYnalY>31V4K}BjyRe3)9n#;-cCVRD_IG1fT zOKGeNY8q;TL@K{dj@D^scf&VCs*-Jb>8b>|`b*osv52-!A?BpbYtTQBns5EAU**$m zSnVSm(teh>tQi*S*A>#ySc=n;`BHz`DuG4&g4Kf8lLhca+zvZ7t7RflD6-i-mcK=M z!=^P$*u2)bkY5asG4gsss!Hn%u~>}kIW`vMs%lJLH+u*9<4PaV_c6U`KqWXQH%+Nu zTv41O(^ZVi@qhjQdG!fbZw&y+2o!iYymO^?ud3{P*HdoX83YV*Uu_HB=?U&W9%AU# z80}k1SS-CXTU7dcQlsm<^oYLxVSseqY6NO}dc`Nj?8vrhNuCdm@^{a3AQ_>6myOj+ z`1RsLUXF|dm|3k7s2jD(B{rzE>WI2scH8i1;=O5Cc9xB3^aJk%fQjqsu+kH#0=_5a z0nCE8@dbQa-|YIuUVvG0L_IwHMEhOj$Mj4Uq05 X8=0q~qBNan00000NkvXXu0mjfptF>5 literal 0 HcmV?d00001 diff --git a/docs/tab_a.png b/docs/tab_a.png new file mode 100644 index 0000000000000000000000000000000000000000..3b725c41c5a527a3a3e40097077d0e206a681247 GIT binary patch literal 142 zcmeAS@N?(olHy`uVBq!ia0vp^j6kfy!2~3aiye;!QlXwMjv*C{Z|8b*H5dputLHD# z=<0|*y7z(Vor?d;H&?EG&cXR}?!j-Lm&u1OOI7AIF5&c)RFE;&p0MYK>*Kl@eiymD r@|NpwKX@^z+;{u_Z~trSBfrMKa%3`zocFjEXaR$#tDnm{r-UW|TZ1%4 literal 0 HcmV?d00001 diff --git a/docs/tab_ad.png b/docs/tab_ad.png new file mode 100644 index 0000000000000000000000000000000000000000..e34850acfc24be58da6d2fd1ccc6b29cc84fe34d GIT binary patch literal 135 zcmeAS@N?(olHy`uVBq!ia0vp^j6kfy!2~3aiye;!QhuH;jv*C{Z|5d*H3V=pKi{In zd2jxLclDRPylmD}^l7{QOtL{vUjO{-WqItb5sQp2h-99b8^^Scr-=2mblCdZuUm?4 jzOJvgvt3{(cjKLW5(A@0qPS@<&}0TrS3j3^P6y&q2{!U5bk+Tso_B!YCpDh>v z{CM*1U8YvQRyBUHt^Ju0W_sq-?;9@_4equ-bavTs=gk796zopr0EBT&m;e9( literal 0 HcmV?d00001 diff --git a/docs/tab_s.png b/docs/tab_s.png new file mode 100644 index 0000000000000000000000000000000000000000..ab478c95b67371d700a20869f7de1ddd73522d50 GIT binary patch literal 184 zcmeAS@N?(olHy`uVBq!ia0vp^j6kfy!2~3aiye;!QuUrLjv*C{Z|^p8HaRdjTwH7) zC?wLlL}}I{)n%R&r+1}IGmDnq;&J#%V6)9VsYhS`O^BVBQlxOUep0c$RENLq#g8A$ z)z7%K_bI&n@J+X_=x}fJoEKed-$<>=ZI-;YrdjIl`U`uzuDWSP?o#Dmo{%SgM#oan kX~E1%D-|#H#QbHoIja2U-MgvsK&LQxy85}Sb4q9e0Efg%P5=M^ literal 0 HcmV?d00001 diff --git a/docs/tab_sd.png b/docs/tab_sd.png new file mode 100644 index 0000000000000000000000000000000000000000..757a565ced4730f85c833fb2547d8e199ae68f19 GIT binary patch literal 188 zcmeAS@N?(olHy`uVBq!ia0vp^j6kfy!2~3aiye;!Qq7(&jv*C{Z|_!fH5o7*c=%9% zcILh!EA=pAQKdx-Cdiev=v{eg{8Ht<{e8_NAN~b=)%W>-WDCE0PyDHGemi$BoXwcK z{>e9^za6*c1ilttWw&V+U;WCPlV9{LdC~Ey%_H(qj`xgfES(4Yz5jSTZfCt`4E$0YRsR*S^mTCR^;V&sxC8{l_Cp7w8-YPgg&ebxsLQ00$vXK>z>% literal 0 HcmV?d00001 diff --git a/docs/tabs.css b/docs/tabs.css new file mode 100644 index 0000000..8920117 --- /dev/null +++ b/docs/tabs.css @@ -0,0 +1 @@ +.sm{position:relative;z-index:9999}.sm,.sm ul,.sm li{display:block;list-style:none;margin:0;padding:0;line-height:normal;direction:ltr;text-align:left;-webkit-tap-highlight-color:rgba(0,0,0,0)}.sm-rtl,.sm-rtl ul,.sm-rtl li{direction:rtl;text-align:right}.sm>li>h1,.sm>li>h2,.sm>li>h3,.sm>li>h4,.sm>li>h5,.sm>li>h6{margin:0;padding:0}.sm ul{display:none}.sm li,.sm a{position:relative}.sm a{display:block}.sm a.disabled{cursor:not-allowed}.sm:after{content:"\00a0";display:block;height:0;font:0/0 serif;clear:both;visibility:hidden;overflow:hidden}.sm,.sm *,.sm *:before,.sm *:after{-moz-box-sizing:border-box;-webkit-box-sizing:border-box;box-sizing:border-box}.main-menu-btn{position:relative;display:inline-block;width:36px;height:36px;text-indent:36px;margin-left:8px;white-space:nowrap;overflow:hidden;cursor:pointer;-webkit-tap-highlight-color:rgba(0,0,0,0)}.main-menu-btn-icon,.main-menu-btn-icon:before,.main-menu-btn-icon:after{position:absolute;top:50%;left:2px;height:2px;width:24px;background:#364D7C;-webkit-transition:all .25s;transition:all .25s}.main-menu-btn-icon:before{content:'';top:-7px;left:0}.main-menu-btn-icon:after{content:'';top:7px;left:0}#main-menu-state:checked ~ .main-menu-btn .main-menu-btn-icon{height:0}#main-menu-state:checked ~ .main-menu-btn .main-menu-btn-icon:before{top:0;-webkit-transform:rotate(-45deg);transform:rotate(-45deg)}#main-menu-state:checked ~ .main-menu-btn .main-menu-btn-icon:after{top:0;-webkit-transform:rotate(45deg);transform:rotate(45deg)}#main-menu-state{position:absolute;width:1px;height:1px;margin:-1px;border:0;padding:0;overflow:hidden;clip:rect(1px,1px,1px,1px)}#main-menu-state:not(:checked) ~ #main-menu{display:none}#main-menu-state:checked ~ #main-menu{display:block}@media(min-width:768px){.main-menu-btn{position:absolute;top:-99999px}#main-menu-state:not(:checked) ~ #main-menu{display:block}}.sm-dox{background-image:url('tab_b.png')}.sm-dox a,.sm-dox a:focus,.sm-dox a:hover,.sm-dox a:active{padding:0 12px;padding-right:43px;font-family:'Lucida Grande',Geneva,Helvetica,Arial,sans-serif;font-size:13px;font-weight:bold;line-height:36px;text-decoration:none;text-shadow:0px 1px 1px rgba(255, 255, 255, 0.9);color:#283A5D;outline:0}.sm-dox a:hover{background-image:url('tab_a.png');background-repeat:repeat-x;color:white;text-shadow:0px 1px 1px rgba(0, 0, 0, 1.0)}.sm-dox a.current{color:#d23600}.sm-dox a.disabled{color:#bbb}.sm-dox a span.sub-arrow{position:absolute;top:50%;margin-top:-14px;left:auto;right:3px;width:28px;height:28px;overflow:hidden;font:bold 12px/28px monospace !important;text-align:center;text-shadow:none;background:rgba(255, 255, 255, 0.5);-moz-border-radius:5px;-webkit-border-radius:5px;border-radius:5px}.sm-dox a span.sub-arrow:before{display:block;content:'+'}.sm-dox a.highlighted span.sub-arrow:before{display:block;content:'-'}.sm-dox>li:first-child>a,.sm-dox>li:first-child>:not(ul) a{-moz-border-radius:5px 5px 0 0;-webkit-border-radius:5px;border-radius:5px 5px 0 0}.sm-dox>li:last-child>a,.sm-dox>li:last-child>*:not(ul) a,.sm-dox>li:last-child>ul,.sm-dox>li:last-child>ul>li:last-child>a,.sm-dox>li:last-child>ul>li:last-child>*:not(ul) a,.sm-dox>li:last-child>ul>li:last-child>ul,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul{-moz-border-radius:0 0 5px 5px;-webkit-border-radius:0;border-radius:0 0 5px 5px}.sm-dox>li:last-child>a.highlighted,.sm-dox>li:last-child>*:not(ul) a.highlighted,.sm-dox>li:last-child>ul>li:last-child>a.highlighted,.sm-dox>li:last-child>ul>li:last-child>*:not(ul) a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a.highlighted{-moz-border-radius:0;-webkit-border-radius:0;border-radius:0}.sm-dox ul{background:white}.sm-dox ul a,.sm-dox ul a:focus,.sm-dox ul a:hover,.sm-dox ul a:active{font-size:12px;border-left:8px solid transparent;line-height:36px;text-shadow:none;background-color:white;background-image:none}.sm-dox ul a:hover{background-image:url('tab_a.png');background-repeat:repeat-x;color:white;text-shadow:0 1px 1px black}.sm-dox ul ul a,.sm-dox ul ul a:hover,.sm-dox ul ul a:focus,.sm-dox ul ul a:active{border-left:16px solid transparent}.sm-dox ul ul ul a,.sm-dox ul ul ul a:hover,.sm-dox ul ul ul a:focus,.sm-dox ul ul ul a:active{border-left:24px solid transparent}.sm-dox ul ul ul ul a,.sm-dox ul ul ul ul a:hover,.sm-dox ul ul ul ul a:focus,.sm-dox ul ul ul ul a:active{border-left:32px solid transparent}.sm-dox ul ul ul ul ul a,.sm-dox ul ul ul ul ul a:hover,.sm-dox ul ul ul ul ul a:focus,.sm-dox ul ul ul ul ul a:active{border-left:40px solid transparent}@media(min-width:768px){.sm-dox ul{position:absolute;width:12em}.sm-dox li{float:left}.sm-dox.sm-rtl li{float:right}.sm-dox ul li,.sm-dox.sm-rtl ul li,.sm-dox.sm-vertical li{float:none}.sm-dox a{white-space:nowrap}.sm-dox ul a,.sm-dox.sm-vertical a{white-space:normal}.sm-dox .sm-nowrap>li>a,.sm-dox .sm-nowrap>li>:not(ul) a{white-space:nowrap}.sm-dox{padding:0 10px;background-image:url('tab_b.png');line-height:36px}.sm-dox a span.sub-arrow{top:50%;margin-top:-2px;right:12px;width:0;height:0;border-width:4px;border-style:solid dashed dashed dashed;border-color:#283A5D transparent transparent transparent;background:transparent;-moz-border-radius:0;-webkit-border-radius:0;border-radius:0}.sm-dox a,.sm-dox a:focus,.sm-dox a:active,.sm-dox a:hover,.sm-dox a.highlighted{padding:0 12px;background-image:url('tab_s.png');background-repeat:no-repeat;background-position:right;-moz-border-radius:0 !important;-webkit-border-radius:0;border-radius:0 !important}.sm-dox a:hover{background-image:url('tab_a.png');background-repeat:repeat-x;color:white;text-shadow:0px 1px 1px rgba(0, 0, 0, 1.0)}.sm-dox a:hover span.sub-arrow{border-color:white transparent transparent transparent}.sm-dox a.has-submenu{padding-right:24px}.sm-dox li{border-top:0}.sm-dox>li>ul:before,.sm-dox>li>ul:after{content:'';position:absolute;top:-18px;left:30px;width:0;height:0;overflow:hidden;border-width:9px;border-style:dashed dashed solid dashed;border-color:transparent transparent #bbb transparent}.sm-dox>li>ul:after{top:-16px;left:31px;border-width:8px;border-color:transparent transparent white transparent}.sm-dox ul{border:1px solid #bbb;padding:5px 0;background:white;-moz-border-radius:5px !important;-webkit-border-radius:5px;border-radius:5px !important;-moz-box-shadow:0 5px 9px rgba(0,0,0,0.2);-webkit-box-shadow:0 5px 9px rgba(0,0,0,0.2);box-shadow:0 5px 9px rgba(0,0,0,0.2)}.sm-dox ul a span.sub-arrow{right:8px;top:50%;margin-top:-5px;border-width:5px;border-color:transparent transparent transparent #555555;border-style:dashed dashed dashed solid}.sm-dox ul a,.sm-dox ul a:hover,.sm-dox ul a:focus,.sm-dox ul a:active,.sm-dox ul a.highlighted{color:#555555;background-image:none;border:0 !important;color:#555555;background-image:none}.sm-dox ul a:hover{background-image:url('tab_a.png');background-repeat:repeat-x;color:white;text-shadow:0px 1px 1px rgba(0, 0, 0, 1.0)}.sm-dox ul a:hover span.sub-arrow{border-color:transparent transparent transparent white}.sm-dox span.scroll-up,.sm-dox span.scroll-down{position:absolute;display:none;visibility:hidden;overflow:hidden;background:white;height:36px}.sm-dox span.scroll-up:hover,.sm-dox span.scroll-down:hover{background:#eee}.sm-dox span.scroll-up:hover span.scroll-up-arrow,.sm-dox span.scroll-up:hover span.scroll-down-arrow{border-color:transparent transparent #d23600 transparent}.sm-dox span.scroll-down:hover span.scroll-down-arrow{border-color:#d23600 transparent transparent transparent}.sm-dox span.scroll-up-arrow,.sm-dox span.scroll-down-arrow{position:absolute;top:0;left:50%;margin-left:-6px;width:0;height:0;overflow:hidden;border-width:6px;border-style:dashed dashed solid dashed;border-color:transparent transparent #555555 transparent}.sm-dox span.scroll-down-arrow{top:8px;border-style:solid dashed dashed dashed;border-color:#555555 transparent transparent transparent}.sm-dox.sm-rtl a.has-submenu{padding-right:12px;padding-left:24px}.sm-dox.sm-rtl a span.sub-arrow{right:auto;left:12px}.sm-dox.sm-rtl.sm-vertical a.has-submenu{padding:10px 20px}.sm-dox.sm-rtl.sm-vertical a span.sub-arrow{right:auto;left:8px;border-style:dashed solid dashed dashed;border-color:transparent #555 transparent transparent}.sm-dox.sm-rtl>li>ul:before{left:auto;right:30px}.sm-dox.sm-rtl>li>ul:after{left:auto;right:31px}.sm-dox.sm-rtl ul a.has-submenu{padding:10px 20px !important}.sm-dox.sm-rtl ul a span.sub-arrow{right:auto;left:8px;border-style:dashed solid dashed dashed;border-color:transparent #555 transparent transparent}.sm-dox.sm-vertical{padding:10px 0;-moz-border-radius:5px;-webkit-border-radius:5px;border-radius:5px}.sm-dox.sm-vertical a{padding:10px 20px}.sm-dox.sm-vertical a:hover,.sm-dox.sm-vertical a:focus,.sm-dox.sm-vertical a:active,.sm-dox.sm-vertical a.highlighted{background:#fff}.sm-dox.sm-vertical a.disabled{background-image:url('tab_b.png')}.sm-dox.sm-vertical a span.sub-arrow{right:8px;top:50%;margin-top:-5px;border-width:5px;border-style:dashed dashed dashed solid;border-color:transparent transparent transparent #555}.sm-dox.sm-vertical>li>ul:before,.sm-dox.sm-vertical>li>ul:after{display:none}.sm-dox.sm-vertical ul a{padding:10px 20px}.sm-dox.sm-vertical ul a:hover,.sm-dox.sm-vertical ul a:focus,.sm-dox.sm-vertical ul a:active,.sm-dox.sm-vertical ul a.highlighted{background:#eee}.sm-dox.sm-vertical ul a.disabled{background:white}} \ No newline at end of file diff --git a/docs/test__suite_8cpp.html b/docs/test__suite_8cpp.html new file mode 100644 index 0000000..ff4138e --- /dev/null +++ b/docs/test__suite_8cpp.html @@ -0,0 +1,248 @@ + + + + + + + +2 Dimensional Ising Model: src/test_suite.cpp File Reference + + + + + + + + + + + + + + + + +
    +
    + + + + + + +
    +
    2 Dimensional Ising Model +
    +
    Simulate the change in energy and magnetization in a ferro magnet
    +
    +
    + + + + + + + +
    +
    + +
    +
    +
    + +
    + +
    +
    + + +
    +
    +
    +
    +
    +
    Loading...
    +
    Searching...
    +
    No Matches
    +
    +
    +
    +
    + +
    + +
    test_suite.cpp File Reference
    +
    +
    + +

    Sweep over different temperatures and generate data. +More...

    +
    #include "IsingModel.hpp"
    +#include "testlib.hpp"
    +#include <fstream>
    +
    +

    Go to the source code of this file.

    + + + + + +

    +Classes

    class  IsingModelTest
     Test class for the Ising model. More...
     
    + + + + + + + + + +

    +Macros

    #define EPS_2   (-2 * std::sinh(8.)) / (std::cosh(8.) + 3)
     
    #define MAG_2   (std::exp(8.) + 1) / (2 * (cosh(8.) + 3))
     
    #define CV_2    16 * (3 * std::cosh(8.) + 1) / ((std::cosh(8.) + 3) * (std::cosh(8.) + 3))
     
    #define X_2
     
    + + + + +

    +Functions

    int main ()
     The main function.
     
    +

    Detailed Description

    +

    Sweep over different temperatures and generate data.

    +
    Author
    Cory Alexander Balaton (coryab)
    +
    +Janita Ovidie Sandtrøen Willumsen (janitaws)
    +
    Version
    1.0
    +
    Bug:
    No known bugs
    + +

    Definition in file test_suite.cpp.

    +

    Macro Definition Documentation

    + +

    ◆ CV_2

    + +
    +
    + + + + +
    #define CV_2    16 * (3 * std::cosh(8.) + 1) / ((std::cosh(8.) + 3) * (std::cosh(8.) + 3))
    +
    + +

    Definition at line 21 of file test_suite.cpp.

    + +
    +
    + +

    ◆ EPS_2

    + +
    +
    + + + + +
    #define EPS_2   (-2 * std::sinh(8.)) / (std::cosh(8.) + 3)
    +
    + +

    Definition at line 17 of file test_suite.cpp.

    + +
    +
    + +

    ◆ MAG_2

    + +
    +
    + + + + +
    #define MAG_2   (std::exp(8.) + 1) / (2 * (cosh(8.) + 3))
    +
    + +

    Definition at line 19 of file test_suite.cpp.

    + +
    +
    + +

    ◆ X_2

    + +
    +
    + + + + +
    #define X_2
    +
    +Value:
    (3 * std::exp(8.) + std::exp(-8.) + 3) \
    +
    / ((std::cosh(8.) + 3) * (std::cosh(8.) + 3))
    +
    +

    Definition at line 24 of file test_suite.cpp.

    + +
    +
    +

    Function Documentation

    + +

    ◆ main()

    + +
    +
    + + + + + + + +
    int main ()
    +
    + +

    The main function.

    + +

    Definition at line 148 of file test_suite.cpp.

    + +
    +
    +
    +
    + + + + diff --git a/docs/test__suite_8cpp.js b/docs/test__suite_8cpp.js new file mode 100644 index 0000000..f9b584a --- /dev/null +++ b/docs/test__suite_8cpp.js @@ -0,0 +1,5 @@ +var test__suite_8cpp = +[ + [ "IsingModelTest", "classIsingModelTest.html", "classIsingModelTest" ], + [ "main", "test__suite_8cpp.html#ae66f6b31b5ad750f1fe042a706a4e3d4", null ] +]; \ No newline at end of file diff --git a/docs/test__suite_8cpp_source.html b/docs/test__suite_8cpp_source.html new file mode 100644 index 0000000..7ab3051 --- /dev/null +++ b/docs/test__suite_8cpp_source.html @@ -0,0 +1,279 @@ + + + + + + + +2 Dimensional Ising Model: src/test_suite.cpp Source File + + + + + + + + + + + + + + + + +
    +
    + + + + + + +
    +
    2 Dimensional Ising Model +
    +
    Simulate the change in energy and magnetization in a ferro magnet
    +
    +
    + + + + + + + +
    +
    + +
    +
    +
    + +
    + +
    +
    + + +
    +
    +
    +
    +
    +
    Loading...
    +
    Searching...
    +
    No Matches
    +
    +
    +
    +
    + +
    +
    test_suite.cpp
    +
    +
    +Go to the documentation of this file.
    1
    +
    12#include "IsingModel.hpp"
    +
    13#include "testlib.hpp"
    +
    14
    +
    15#include <fstream>
    +
    16
    +
    17#define EPS_2 (-2 * std::sinh(8.)) / (std::cosh(8.) + 3)
    +
    18
    +
    19#define MAG_2 (std::exp(8.) + 1) / (2 * (cosh(8.) + 3))
    +
    20
    +
    21#define CV_2 \
    +
    22 16 * (3 * std::cosh(8.) + 1) / ((std::cosh(8.) + 3) * (std::cosh(8.) + 3))
    +
    23
    +
    24#define X_2 \
    +
    25 (3 * std::exp(8.) + std::exp(-8.) + 3) \
    +
    26 / ((std::cosh(8.) + 3) * (std::cosh(8.) + 3))
    +
    27
    + +
    31public:
    + +
    35 {
    +
    36 IsingModel test;
    +
    37 test.L = 3;
    +
    38 test.T = 1.;
    +
    39
    +
    40 // Test that initializing the lattice only yields 1s and -1s.
    +
    41 test.initialize_lattice();
    +
    42 std::function<bool(int)> f = [](int x) { return x == 1 || x == -1; };
    +
    43 ASSERT(testlib::assert_each(f, test.lattice),
    +
    44 "Test lattice initialization.");
    +
    45
    + +
    47 arma::Mat<int> neighbor_matrix("2, 1 ; 0, 2 ; 1, 0");
    +
    48 ASSERT(testlib::is_equal(neighbor_matrix, test.neighbors),
    +
    49 "Test neighbor matrix.");
    +
    50
    +
    51 // Fill the lattice with 1s to be able to test the next functions.
    +
    52 test.lattice.fill(1);
    +
    53
    +
    54 // Test the initial magnetization.
    + +
    56 ASSERT(std::fabs(test.M - 9.) < 1e-8, "Test intial magnetization");
    +
    57
    +
    58 // Test that the initial energy is correct
    +
    59 test.initialize_energy();
    +
    60 ASSERT(std::fabs(test.E - (-18)) < 1e-8, "Test initial energy.");
    +
    61 }
    +
    62
    +
    70 int test_2x2_lattice(double tol, int max_cycles)
    +
    71 {
    +
    72 data_t data, tmp;
    +
    73 size_t L = 2;
    +
    74 size_t n_spins = L * L;
    +
    75 double T = 1.;
    +
    76 size_t cycles = 0;
    +
    77
    +
    78 // Create random engine using the mersenne twister
    +
    79 std::random_device rd;
    +
    80 std::mt19937 engine(rd());
    +
    81
    +
    82 IsingModel test(L, T);
    +
    83
    +
    84 int arr[]{0, 0, 0, 0};
    +
    85
    +
    86 // Loop through cycles
    +
    87 //std::ofstream ofile;
    +
    88 //ofile.open("output/test_2x2.txt");
    +
    89 while (cycles++ < max_cycles) {
    +
    90 data += test.Metropolis();
    +
    91 tmp = data / cycles;
    +
    92 //ofile << cycles << ',' << tmp.E / n_spins << ','
    +
    93 //<< tmp.M_abs / n_spins << ','
    +
    94 //<< (tmp.E2 - tmp.E * tmp.E) / (T * T) / n_spins << ','
    +
    95 //<< (tmp.M2 - tmp.M_abs * tmp.M_abs) / T / n_spins << '\n';
    +
    96 if (testlib::close_to(EPS_2, tmp.E / n_spins, tol)
    +
    97 && testlib::close_to(MAG_2, tmp.M_abs / n_spins, tol)
    +
    98 && testlib::close_to(CV_2, (tmp.E2 - tmp.E * tmp.E) / (T * T)
    +
    99 / n_spins, tol)
    +
    100 && testlib::close_to(X_2, (tmp.M2 - tmp.M_abs * tmp.M_abs) / T
    +
    101 / n_spins, tol)) {
    +
    102 return cycles;
    +
    103 }
    +
    104 }
    +
    105 //std::cout << EPS_2 << ',' << MAG_2 << ',' << CV_2 << ',' << X_2
    +
    106 //<< std::endl;
    +
    107 //ofile.close();
    +
    108 // cycles = 0;
    +
    109 // data = 0;
    +
    110 // IsingModel test_mag(L, T);
    +
    111 // while (cycles++ < max_cycles) {
    +
    112 // data += test.Metropolis();
    +
    113 // tmp = data / (cycles * n_spins);
    +
    114 // if (testlib::close_to(MAG_2, tmp.M, tol)) {
    +
    115 // arr[1] = cycles;
    +
    116 // break;
    +
    117 //}
    +
    118 //}
    +
    119 // cycles = 0;
    +
    120 // data = 0;
    +
    121 // IsingModel test_CV(L, T);
    +
    122 // while (cycles++ < max_cycles) {
    +
    123 // data += test.Metropolis();
    +
    124 // tmp = data / (cycles * n_spins);
    +
    125 // if (testlib::close_to(CV_2, (tmp.E2 - tmp.E * tmp.E) / (T * T),
    +
    126 // tol)) {
    +
    127 // arr[2] = cycles;
    +
    128 // break;
    +
    129 //}
    +
    130 //}
    +
    131 // cycles = 0;
    +
    132 // data = 0;
    +
    133 // IsingModel test_X(L, T);
    +
    134 // while (cycles++ < max_cycles) {
    +
    135 // data += test.Metropolis();
    +
    136 // tmp = data / (cycles * n_spins);
    +
    137 // if (testlib::close_to(X_2, (tmp.M2 - tmp.M_abs * tmp.M_abs) / T,
    +
    138 // tol)) {
    +
    139 // arr[3] = cycles;
    +
    140 // break;
    +
    141 //}
    +
    142 //}
    +
    143 return 0;
    +
    144 }
    +
    145};
    +
    146
    +
    148int main()
    +
    149{
    +
    150 IsingModelTest test;
    +
    151
    +
    152 test.test_init_functions();
    +
    153 int res = 0;
    +
    154 int tmp;
    +
    155 for (size_t i=0; i < 1000; i++) {
    +
    156 tmp = test.test_2x2_lattice(1e-2, 1e5);
    +
    157 if (tmp == 0) {
    +
    158 std::cout << "not enough cycles\n";
    +
    159 break;
    +
    160 }
    +
    161 res += tmp;
    +
    162 }
    +
    163
    +
    164 std::cout << "Res: " << res / 1000 << std::endl;
    +
    165
    +
    166 return 0;
    +
    167}
    +
    The definition of the Ising model.
    +
    Test class for the Ising model.
    Definition: test_suite.cpp:30
    +
    int test_2x2_lattice(double tol, int max_cycles)
    Test numerical data with analytical data.
    Definition: test_suite.cpp:70
    +
    void test_init_functions()
    Test That initializing works as intended.
    Definition: test_suite.cpp:34
    +
    The Ising model in 2 dimensions.
    Definition: IsingModel.hpp:37
    +
    int M
    The current magnetic strength. unit: Unitless.
    Definition: IsingModel.hpp:72
    +
    double T
    The temperature of the model.
    Definition: IsingModel.hpp:60
    +
    int L
    Size of the lattice.
    Definition: IsingModel.hpp:64
    +
    arma::Mat< int > lattice
    matrix where element .
    Definition: IsingModel.hpp:42
    +
    void initialize_lattice()
    Initialize the lattice with a random distribution of 1s and -1s.
    Definition: IsingModel.cpp:44
    +
    data_t Metropolis()
    The Metropolis algorithm.
    Definition: IsingModel.cpp:96
    +
    void initialize_energy()
    Initialize the energy.
    Definition: IsingModel.cpp:82
    +
    void initialize_neighbors()
    initialize the neighbors matrix.
    Definition: IsingModel.cpp:56
    +
    void initialize_magnetization()
    Initialize the magnetization.
    Definition: IsingModel.cpp:74
    +
    arma::Mat< int > neighbors
    matrix with the neighbors of each element .
    Definition: IsingModel.hpp:52
    +
    int E
    The current energy state. unit: .
    Definition: IsingModel.hpp:68
    + +
    int main()
    The main function.
    Definition: test_suite.cpp:148
    +
    A small test library.
    +
    #define ASSERT(expr, msg)
    A prettier assertion function.
    Definition: testlib.hpp:31
    +
    +
    + + + + diff --git a/docs/testlib_8cpp.html b/docs/testlib_8cpp.html new file mode 100644 index 0000000..759935c --- /dev/null +++ b/docs/testlib_8cpp.html @@ -0,0 +1,207 @@ + + + + + + + +2 Dimensional Ising Model: src/testlib.cpp File Reference + + + + + + + + + + + + + + + + +
    +
    + + + + + + +
    +
    2 Dimensional Ising Model +
    +
    Simulate the change in energy and magnetization in a ferro magnet
    +
    +
    + + + + + + + +
    +
    + +
    +
    +
    + +
    + +
    +
    + + +
    +
    +
    +
    +
    +
    Loading...
    +
    Searching...
    +
    No Matches
    +
    +
    +
    +
    + +
    + +
    testlib.cpp File Reference
    +
    +
    + +

    Implementation of the testing library. +More...

    +
    #include "testlib.hpp"
    +
    +

    Go to the source code of this file.

    + + + + + +

    +Functions

    void details::m_assert (bool expr, std::string expr_str, std::string func, std::string file, int line, std::string msg)
     Test an expression, confirm that test is ok, or abort execution.
     
    +

    Detailed Description

    +

    Implementation of the testing library.

    +
    Author
    Cory Alexander Balaton (coryab)
    +
    +Janita Ovidie Sandtrøen Willumsen (janitaws)
    +
    Version
    1.0
    +
    Bug:
    No known bugs
    + +

    Definition in file testlib.cpp.

    +

    Function Documentation

    + +

    ◆ m_assert()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    void details::m_assert (bool expr,
    std::string expr_str,
    std::string func,
    std::string file,
    int line,
    std::string msg 
    )
    +
    + +

    Test an expression, confirm that test is ok, or abort execution.

    +

    This function takes in an expression and prints an OK message if it's true, or it prints a fail message and aborts execution if it fails.

    +
    Parameters
    + + + + + + + +
    exprThe expression to be evaluated
    expr_strThe stringified version of the expression
    funcThe function name of the caller
    fileThe file of the caller
    lineThe line number where this function is called from
    msgThe message to be displayed
    +
    +
    + +

    Definition at line 15 of file testlib.cpp.

    + +
    +
    +
    +
    + + + + diff --git a/docs/testlib_8cpp.js b/docs/testlib_8cpp.js new file mode 100644 index 0000000..298acd6 --- /dev/null +++ b/docs/testlib_8cpp.js @@ -0,0 +1,4 @@ +var testlib_8cpp = +[ + [ "m_assert", "testlib_8cpp.html#a39abb7cba0535176ed62aae136d2fcc7", null ] +]; \ No newline at end of file diff --git a/docs/testlib_8cpp_source.html b/docs/testlib_8cpp_source.html new file mode 100644 index 0000000..1b8d3f7 --- /dev/null +++ b/docs/testlib_8cpp_source.html @@ -0,0 +1,148 @@ + + + + + + + +2 Dimensional Ising Model: src/testlib.cpp Source File + + + + + + + + + + + + + + + + +
    +
    + + + + + + +
    +
    2 Dimensional Ising Model +
    +
    Simulate the change in energy and magnetization in a ferro magnet
    +
    +
    + + + + + + + +
    +
    + +
    +
    +
    + +
    + +
    +
    + + +
    +
    +
    +
    +
    +
    Loading...
    +
    Searching...
    +
    No Matches
    +
    +
    +
    +
    + +
    +
    testlib.cpp
    +
    +
    +Go to the documentation of this file.
    1
    +
    12#include "testlib.hpp"
    +
    13
    +
    14namespace details {
    +
    15void m_assert(bool expr, std::string expr_str, std::string f, std::string file,
    +
    16 int line, std::string msg)
    +
    17{
    +
    18 std::function<void(const std::string &)> print_message =
    +
    19 [](const std::string &msg) {
    +
    20 if (msg.size() > 0) {
    +
    21 std::cout << "message: " << msg << "\n\n";
    +
    22 }
    +
    23 else {
    +
    24 std::cout << "\n";
    +
    25 }
    +
    26 };
    +
    27 std::string new_assert(f.size() + (expr ? 4 : 6), '-');
    +
    28 std::cout << "\x1B[36m" << new_assert << "\033[0m\n";
    +
    29 std::cout << f << ": ";
    +
    30 if (expr) {
    +
    31 std::cout << "\x1B[32mOK\033[0m\n";
    +
    32 print_message(msg);
    +
    33 }
    +
    34 else {
    +
    35 std::cout << "\x1B[31mFAIL\033[0m\n";
    +
    36 print_message(msg);
    +
    37 std::cout << file << " " << line << ": Assertion \"" << expr_str
    +
    38 << "\" Failed\n\n";
    +
    39 abort();
    +
    40 }
    +
    41}
    +
    42} // namespace details
    +
    A small test library.
    +
    void m_assert(bool expr, std::string expr_str, std::string func, std::string file, int line, std::string msg)
    Test an expression, confirm that test is ok, or abort execution.
    Definition: testlib.cpp:15
    +
    +
    + + + + diff --git a/docs/testlib_8hpp.html b/docs/testlib_8hpp.html new file mode 100644 index 0000000..60ec200 --- /dev/null +++ b/docs/testlib_8hpp.html @@ -0,0 +1,252 @@ + + + + + + + +2 Dimensional Ising Model: include/testlib.hpp File Reference + + + + + + + + + + + + + + + + +
    +
    + + + + + + +
    +
    2 Dimensional Ising Model +
    +
    Simulate the change in energy and magnetization in a ferro magnet
    +
    +
    + + + + + + + +
    +
    + +
    +
    +
    + +
    + +
    +
    + + +
    +
    +
    +
    +
    +
    Loading...
    +
    Searching...
    +
    No Matches
    +
    +
    +
    +
    + +
    + +
    testlib.hpp File Reference
    +
    +
    + +

    A small test library. +More...

    +
    #include "utils.hpp"
    +#include <armadillo>
    +#include <string>
    +#include <type_traits>
    +
    +

    Go to the source code of this file.

    + + + + + +

    +Macros

    #define ASSERT(expr, msg)    details::m_assert(expr, #expr, __METHOD_NAME__, __FILE__, __LINE__, msg)
     A prettier assertion function.
     
    + + + + +

    +Functions

    void details::m_assert (bool expr, std::string expr_str, std::string func, std::string file, int line, std::string msg)
     Test an expression, confirm that test is ok, or abort execution.
     
    +

    Detailed Description

    +

    A small test library.

    +
    Author
    Cory Alexander Balaton (coryab)
    +
    +Janita Ovidie Sandtrøen Willumsen (janitaws)
    +
    Version
    1.0
    +

    This a small testing library that is tailored for the needs of the project. Anything that is in the details namespace should not be used directly, or else it might cause undefined behavior if not used correctly.

    +
    Bug:
    No known bugs
    + +

    Definition in file testlib.hpp.

    +

    Macro Definition Documentation

    + +

    ◆ ASSERT

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    #define ASSERT( expr,
     msg 
    )    details::m_assert(expr, #expr, __METHOD_NAME__, __FILE__, __LINE__, msg)
    +
    + +

    A prettier assertion function.

    +

    This macro calls the m_assert function which is a more informative assertion function than the regular assert function from cassert.

    + +

    Definition at line 31 of file testlib.hpp.

    + +
    +
    +

    Function Documentation

    + +

    ◆ m_assert()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    void details::m_assert (bool expr,
    std::string expr_str,
    std::string func,
    std::string file,
    int line,
    std::string msg 
    )
    +
    + +

    Test an expression, confirm that test is ok, or abort execution.

    +

    This function takes in an expression and prints an OK message if it's true, or it prints a fail message and aborts execution if it fails.

    +
    Parameters
    + + + + + + + +
    exprThe expression to be evaluated
    expr_strThe stringified version of the expression
    funcThe function name of the caller
    fileThe file of the caller
    lineThe line number where this function is called from
    msgThe message to be displayed
    +
    +
    + +

    Definition at line 15 of file testlib.cpp.

    + +
    +
    +
    +
    + + + + diff --git a/docs/testlib_8hpp.js b/docs/testlib_8hpp.js new file mode 100644 index 0000000..9b491a8 --- /dev/null +++ b/docs/testlib_8hpp.js @@ -0,0 +1,5 @@ +var testlib_8hpp = +[ + [ "ASSERT", "testlib_8hpp.html#a73d4f21ad937dbc50a0c0538c78fd4f9", null ], + [ "m_assert", "testlib_8hpp.html#a39abb7cba0535176ed62aae136d2fcc7", null ] +]; \ No newline at end of file diff --git a/docs/testlib_8hpp_source.html b/docs/testlib_8hpp_source.html new file mode 100644 index 0000000..bfd14a2 --- /dev/null +++ b/docs/testlib_8hpp_source.html @@ -0,0 +1,182 @@ + + + + + + + +2 Dimensional Ising Model: include/testlib.hpp Source File + + + + + + + + + + + + + + + + +
    +
    + + + + + + +
    +
    2 Dimensional Ising Model +
    +
    Simulate the change in energy and magnetization in a ferro magnet
    +
    +
    + + + + + + + +
    +
    + +
    +
    +
    + +
    + +
    +
    + + +
    +
    +
    +
    +
    +
    Loading...
    +
    Searching...
    +
    No Matches
    +
    +
    +
    +
    + +
    +
    testlib.hpp
    +
    +
    +Go to the documentation of this file.
    1
    +
    16#ifndef __TESTLIB__
    +
    17#define __TESTLIB__
    +
    18
    +
    19#include "utils.hpp"
    +
    20
    +
    21#include <armadillo>
    +
    22#include <string>
    +
    23#include <type_traits>
    +
    24
    +
    31#define ASSERT(expr, msg) \
    +
    32 details::m_assert(expr, #expr, __METHOD_NAME__, __FILE__, __LINE__, msg)
    +
    33
    +
    34namespace details {
    +
    47void m_assert(bool expr, std::string expr_str, std::string func,
    +
    48 std::string file, int line, std::string msg);
    +
    49} // namespace details
    +
    50
    +
    51namespace testlib {
    +
    63template <class T,
    +
    64 class = typename std::enable_if<std::is_arithmetic<T>::value>::type>
    +
    65static bool close_to(arma::Mat<T> &a, arma::Mat<T> &b, double tol = 1e-8)
    +
    66{
    +
    67 if (a.n_elem != b.n_elem) {
    +
    68 return false;
    +
    69 }
    +
    70
    +
    71 for (size_t i = 0; i < a.n_elem; i++) {
    +
    72 if (!close_to(a(i), b(i))) {
    +
    73 return false;
    +
    74 }
    +
    75 }
    +
    76 return true;
    +
    77}
    +
    78
    +
    90template <class T,
    +
    91 class = typename std::enable_if<std::is_arithmetic<T>::value>::type>
    +
    92static bool close_to(T a, T b, double tol = 1e-8)
    +
    93{
    +
    94 return std::fabs(a - b) < tol;
    +
    95}
    +
    96
    +
    107template <class T,
    +
    108 class = typename std::enable_if<std::is_integral<T>::value>::type>
    +
    109static bool is_equal(arma::Mat<T> &a, arma::Mat<T> &b)
    +
    110{
    +
    111 for (size_t i = 0; i < a.n_elem; i++) {
    +
    112 if (!(a(i) == b(i))) {
    +
    113 return false;
    +
    114 }
    +
    115 }
    +
    116 return true;
    +
    117}
    +
    118
    +
    126template <class T,
    +
    127 class = typename std::enable_if<std::is_arithmetic<T>::value>::type>
    +
    128static bool assert_each(std::function<bool(T)> expr, arma::Mat<T> &M)
    +
    129{
    +
    130 for (size_t i = 0; i < M.n_elem; i++) {
    +
    131 if (!expr(M(i))) {
    +
    132 return false;
    +
    133 }
    +
    134 }
    +
    135 return true;
    +
    136}
    +
    137} // namespace testlib
    +
    138#endif
    +
    Function prototypes and macros that are useful.
    +
    +
    + + + + diff --git a/docs/typedefs_8hpp.html b/docs/typedefs_8hpp.html new file mode 100644 index 0000000..1f2efc5 --- /dev/null +++ b/docs/typedefs_8hpp.html @@ -0,0 +1,129 @@ + + + + + + + +2 Dimensional Ising Model: include/typedefs.hpp File Reference + + + + + + + + + + + + + + + + +
    +
    + + + + + + +
    +
    2 Dimensional Ising Model +
    +
    Simulate the change in energy and magnetization in a ferro magnet
    +
    +
    + + + + + + + +
    +
    + +
    +
    +
    + +
    + +
    +
    + + +
    +
    +
    +
    +
    +
    Loading...
    +
    Searching...
    +
    No Matches
    +
    +
    +
    +
    + +
    +
    typedefs.hpp File Reference
    +
    +
    + +

    Useful typedefs for cleaner code. +More...

    + +

    Go to the source code of this file.

    +

    Detailed Description

    +

    Useful typedefs for cleaner code.

    +
    Author
    Cory Alexander Balaton (coryab)
    +
    +Janita Ovidie Sandtrøen Willumsen (janitaws)
    +
    Version
    1.0
    +

    These typedefs make the code more readable and easy to follow along.

    +
    Bug:
    No known bugs
    + +

    Definition in file typedefs.hpp.

    +
    +
    + + + + diff --git a/docs/typedefs_8hpp_source.html b/docs/typedefs_8hpp_source.html new file mode 100644 index 0000000..74be59e --- /dev/null +++ b/docs/typedefs_8hpp_source.html @@ -0,0 +1,119 @@ + + + + + + + +2 Dimensional Ising Model: include/typedefs.hpp Source File + + + + + + + + + + + + + + + + +
    +
    + + + + + + +
    +
    2 Dimensional Ising Model +
    +
    Simulate the change in energy and magnetization in a ferro magnet
    +
    +
    + + + + + + + +
    +
    + +
    +
    +
    + +
    + +
    +
    + + +
    +
    +
    +
    +
    +
    Loading...
    +
    Searching...
    +
    No Matches
    +
    +
    +
    +
    + +
    +
    typedefs.hpp
    +
    +
    +Go to the documentation of this file.
    1
    +
    15#ifndef __TYPEDEFS__
    +
    16#define __TYPEDEFS__
    +
    17
    +
    18#endif
    +
    +
    + + + + diff --git a/docs/utils_8cpp.html b/docs/utils_8cpp.html new file mode 100644 index 0000000..fdff28a --- /dev/null +++ b/docs/utils_8cpp.html @@ -0,0 +1,314 @@ + + + + + + + +2 Dimensional Ising Model: src/utils.cpp File Reference + + + + + + + + + + + + + + + + +
    +
    + + + + + + +
    +
    2 Dimensional Ising Model +
    +
    Simulate the change in energy and magnetization in a ferro magnet
    +
    +
    + + + + + + + +
    +
    + +
    +
    +
    + +
    + +
    +
    + + +
    +
    +
    +
    +
    +
    Loading...
    +
    Searching...
    +
    No Matches
    +
    +
    +
    +
    + +
    + +
    utils.cpp File Reference
    +
    +
    + +

    Implementation of the utils. +More...

    +
    #include "utils.hpp"
    +
    +

    Go to the source code of this file.

    + + + + + + + + + + + + + + +

    +Functions

    std::string utils::scientific_format (double d, int width=20, int prec=10)
     Turns a double into a string written in scientific format.
     
    std::string utils::scientific_format (const std::vector< double > &v, int width=20, int prec=10)
     Turns a vector of doubles into a string written in scientific format.
     
    bool utils::mkpath (std::string path, int mode=0777)
     Make path given.
     
    std::string utils::dirname (const std::string &path)
     Get the directory name of the path.
     
    +

    Detailed Description

    +

    Implementation of the utils.

    +
    Author
    Cory Alexander Balaton (coryab)
    +
    +Janita Ovidie Sandtrøen Willumsen (janitaws)
    +
    Version
    1.0
    +
    Bug:
    No known bugs
    + +

    Definition in file utils.cpp.

    +

    Function Documentation

    + +

    ◆ dirname()

    + +
    +
    + + + + + + + + +
    std::string utils::dirname (const std::string & path)
    +
    + +

    Get the directory name of the path.

    +
    Parameters
    + + +
    pathThe path to use.
    +
    +
    +
    Returns
    string
    + +

    Definition at line 58 of file utils.cpp.

    + +
    +
    + +

    ◆ mkpath()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    bool utils::mkpath (std::string path,
    int mode = 0777 
    )
    +
    + +

    Make path given.

    +

    This tries to be the equivalent to "mkdir -p" and creates a new directory whenever it needs to.

    +
    Parameters
    + + + +
    pathThe path to be created
    modeThe mode/permissions for all the new directories
    +
    +
    +
    Returns
    bool Success/Fail
    + +

    Definition at line 32 of file utils.cpp.

    + +
    +
    + +

    ◆ scientific_format() [1/2]

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    std::string utils::scientific_format (const std::vector< double > & v,
    int width = 20,
    int prec = 10 
    )
    +
    + +

    Turns a vector of doubles into a string written in scientific format.

    +

    The code is stolen from https://github.com/anderkve/FYS3150.

    +
    Parameters
    + + + + +
    vThe vector to stringify
    widthThe reserved width of the string
    precThe precision of the stringified number
    +
    +
    +
    Returns
    std::string
    + +

    Definition at line 23 of file utils.cpp.

    + +
    +
    + +

    ◆ scientific_format() [2/2]

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    std::string utils::scientific_format (double d,
    int width = 20,
    int prec = 10 
    )
    +
    + +

    Turns a double into a string written in scientific format.

    +

    The code is stolen from https://github.com/anderkve/FYS3150.

    +
    Parameters
    + + + + +
    dThe number to stringify
    widthThe reserved width of the string
    precThe precision of the stringified number
    +
    +
    +
    Returns
    std::string
    + +

    Definition at line 16 of file utils.cpp.

    + +
    +
    +
    +
    + + + + diff --git a/docs/utils_8cpp.js b/docs/utils_8cpp.js new file mode 100644 index 0000000..edb7fe6 --- /dev/null +++ b/docs/utils_8cpp.js @@ -0,0 +1,7 @@ +var utils_8cpp = +[ + [ "dirname", "utils_8cpp.html#aed026119193a9bbe076671809ff0f430", null ], + [ "mkpath", "utils_8cpp.html#a2b45adc86b70f42021582994e83fa00d", null ], + [ "scientific_format", "utils_8cpp.html#ab3e89176433ddc9ba721b2eba3d08357", null ], + [ "scientific_format", "utils_8cpp.html#a3529a74fd2a25d24de73d9d4e1c90835", null ] +]; \ No newline at end of file diff --git a/docs/utils_8cpp_source.html b/docs/utils_8cpp_source.html new file mode 100644 index 0000000..ab3a676 --- /dev/null +++ b/docs/utils_8cpp_source.html @@ -0,0 +1,171 @@ + + + + + + + +2 Dimensional Ising Model: src/utils.cpp Source File + + + + + + + + + + + + + + + + +
    +
    + + + + + + +
    +
    2 Dimensional Ising Model +
    +
    Simulate the change in energy and magnetization in a ferro magnet
    +
    +
    + + + + + + + +
    +
    + +
    +
    +
    + +
    + +
    +
    + + +
    +
    +
    +
    +
    +
    Loading...
    +
    Searching...
    +
    No Matches
    +
    +
    +
    +
    + +
    +
    utils.cpp
    +
    +
    +Go to the documentation of this file.
    1
    +
    12#include "utils.hpp"
    +
    13
    +
    14namespace utils {
    +
    15
    +
    16std::string scientific_format(double d, int width, int prec)
    +
    17{
    +
    18 std::stringstream ss;
    +
    19 ss << std::setw(width) << std::setprecision(prec) << std::scientific << d;
    +
    20 return ss.str();
    +
    21}
    +
    22
    +
    23std::string scientific_format(const std::vector<double> &v, int width, int prec)
    +
    24{
    +
    25 std::stringstream ss;
    +
    26 for (double elem : v) {
    +
    27 ss << scientific_format(elem, width, prec);
    +
    28 }
    +
    29 return ss.str();
    +
    30}
    +
    31
    +
    32bool mkpath(std::string path, int mode)
    +
    33{
    +
    34 std::string cur_dir;
    +
    35 std::string::size_type pos = -1;
    +
    36 struct stat buf;
    +
    37
    +
    38 if (path.back() != '/') {
    +
    39 path += '/';
    +
    40 }
    +
    41 while (true) {
    +
    42 pos++;
    +
    43 pos = path.find('/', pos);
    +
    44 if (pos != std::string::npos) {
    +
    45 cur_dir = path.substr(0, pos);
    +
    46 if (mkdir(cur_dir.c_str(), mode) != 0
    +
    47 && stat(cur_dir.c_str(), &buf) != 0) {
    +
    48 return -1;
    +
    49 }
    +
    50 }
    +
    51 else {
    +
    52 break;
    +
    53 }
    +
    54 }
    +
    55 return 0;
    +
    56}
    +
    57
    +
    58std::string dirname(const std::string &path)
    +
    59{
    +
    60 return path.substr(0, path.find_last_of("/"));
    +
    61}
    +
    62
    +
    63} // namespace utils
    +
    Function prototypes and macros that are useful.
    +
    bool mkpath(std::string path, int mode=0777)
    Make path given.
    Definition: utils.cpp:32
    +
    std::string scientific_format(double d, int width=20, int prec=10)
    Turns a double into a string written in scientific format.
    Definition: utils.cpp:16
    +
    std::string dirname(const std::string &path)
    Get the directory name of the path.
    Definition: utils.cpp:58
    +
    +
    + + + + diff --git a/docs/utils_8hpp.html b/docs/utils_8hpp.html new file mode 100644 index 0000000..44140c6 --- /dev/null +++ b/docs/utils_8hpp.html @@ -0,0 +1,413 @@ + + + + + + + +2 Dimensional Ising Model: include/utils.hpp File Reference + + + + + + + + + + + + + + + + +
    +
    + + + + + + +
    +
    2 Dimensional Ising Model +
    +
    Simulate the change in energy and magnetization in a ferro magnet
    +
    +
    + + + + + + + +
    +
    + +
    +
    +
    + +
    + +
    +
    + + +
    +
    +
    +
    +
    +
    Loading...
    +
    Searching...
    +
    No Matches
    +
    +
    +
    +
    + +
    + +
    utils.hpp File Reference
    +
    +
    + +

    Function prototypes and macros that are useful. +More...

    +
    #include <armadillo>
    +#include <iomanip>
    +#include <sstream>
    +#include <string>
    +#include <sys/stat.h>
    +#include <vector>
    +
    +

    Go to the source code of this file.

    + + + + + + + + +

    +Macros

    #define DEBUG(msg)
     Writes a debug message.
     
    #define __METHOD_NAME__   details::methodName(__PRETTY_FUNCTION__)
     Get the name of the current method/function without the return type.
     
    + + + + + + + + + + + + + + + + +

    +Functions

    std::string details::methodName (const std::string &pretty_function)
     Takes in the PRETTY_FUNCTION string and removes the return type.
     
    std::string utils::scientific_format (double d, int width=20, int prec=10)
     Turns a double into a string written in scientific format.
     
    std::string utils::scientific_format (const std::vector< double > &v, int width=20, int prec=10)
     Turns a vector of doubles into a string written in scientific format.
     
    bool utils::mkpath (std::string path, int mode=0777)
     Make path given.
     
    std::string utils::dirname (const std::string &path)
     Get the directory name of the path.
     
    +

    Detailed Description

    +

    Function prototypes and macros that are useful.

    +
    Author
    Cory Alexander Balaton (coryab)
    +
    +Janita Ovidie Sandtrøen Willumsen (janitaws)
    +
    Version
    1.0
    +

    These utility function are mainly for convenience and aren't directly related to the project. Anything that is in the details namespace should not be used directly, or else it might cause undefined behavior if not used correctly.

    +
    Bug:
    No known bugs
    + +

    Definition in file utils.hpp.

    +

    Macro Definition Documentation

    + +

    ◆ __METHOD_NAME__

    + +
    +
    + + + + +
    #define __METHOD_NAME__   details::methodName(__PRETTY_FUNCTION__)
    +
    + +

    Get the name of the current method/function without the return type.

    + +

    Definition at line 45 of file utils.hpp.

    + +
    +
    + +

    ◆ DEBUG

    + +
    +
    + + + + + + + + +
    #define DEBUG( msg)
    +
    + +

    Writes a debug message.

    +

    This macro writes a debug message that includes the filename, line number, and a custom message. The function is wrapped in an ifdef that checks if DBG is defined, so one can choose to display the debug messages by adding the -DDBG flag when compiling.

    + +

    Definition at line 39 of file utils.hpp.

    + +
    +
    +

    Function Documentation

    + +

    ◆ dirname()

    + +
    +
    + + + + + + + + +
    std::string utils::dirname (const std::string & path)
    +
    + +

    Get the directory name of the path.

    +
    Parameters
    + + +
    pathThe path to use.
    +
    +
    +
    Returns
    string
    + +

    Definition at line 58 of file utils.cpp.

    + +
    +
    + +

    ◆ methodName()

    + +
    +
    + + + + + +
    + + + + + + + + +
    std::string details::methodName (const std::string & pretty_function)
    +
    +inline
    +
    + +

    Takes in the PRETTY_FUNCTION string and removes the return type.

    +

    This function should only be used for the METHOD_NAME macro, since it takes the output from PRETTY_FUNCTION and strips the return type.

    +
    Parameters
    + + +
    pretty_functionThe string from PRETTY_FUNCTION
    +
    +
    +
    Returns
    std::string
    + +

    Definition at line 58 of file utils.hpp.

    + +
    +
    + +

    ◆ mkpath()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    bool utils::mkpath (std::string path,
    int mode = 0777 
    )
    +
    + +

    Make path given.

    +

    This tries to be the equivalent to "mkdir -p" and creates a new directory whenever it needs to.

    +
    Parameters
    + + + +
    pathThe path to be created
    modeThe mode/permissions for all the new directories
    +
    +
    +
    Returns
    bool Success/Fail
    + +

    Definition at line 32 of file utils.cpp.

    + +
    +
    + +

    ◆ scientific_format() [1/2]

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    std::string utils::scientific_format (const std::vector< double > & v,
    int width = 20,
    int prec = 10 
    )
    +
    + +

    Turns a vector of doubles into a string written in scientific format.

    +

    The code is stolen from https://github.com/anderkve/FYS3150.

    +
    Parameters
    + + + + +
    vThe vector to stringify
    widthThe reserved width of the string
    precThe precision of the stringified number
    +
    +
    +
    Returns
    std::string
    + +

    Definition at line 23 of file utils.cpp.

    + +
    +
    + +

    ◆ scientific_format() [2/2]

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    std::string utils::scientific_format (double d,
    int width = 20,
    int prec = 10 
    )
    +
    + +

    Turns a double into a string written in scientific format.

    +

    The code is stolen from https://github.com/anderkve/FYS3150.

    +
    Parameters
    + + + + +
    dThe number to stringify
    widthThe reserved width of the string
    precThe precision of the stringified number
    +
    +
    +
    Returns
    std::string
    + +

    Definition at line 16 of file utils.cpp.

    + +
    +
    +
    +
    + + + + diff --git a/docs/utils_8hpp.js b/docs/utils_8hpp.js new file mode 100644 index 0000000..9c9e4b4 --- /dev/null +++ b/docs/utils_8hpp.js @@ -0,0 +1,10 @@ +var utils_8hpp = +[ + [ "__METHOD_NAME__", "utils_8hpp.html#a60dca3177fb9cb5256609adc7af55168", null ], + [ "DEBUG", "utils_8hpp.html#aecc1f7a8a2493b9e021e5bff76a00a5b", null ], + [ "dirname", "utils_8hpp.html#aed026119193a9bbe076671809ff0f430", null ], + [ "methodName", "utils_8hpp.html#a178c4922157666a6e9c127c2ffd96346", null ], + [ "mkpath", "utils_8hpp.html#a2b45adc86b70f42021582994e83fa00d", null ], + [ "scientific_format", "utils_8hpp.html#ab3e89176433ddc9ba721b2eba3d08357", null ], + [ "scientific_format", "utils_8hpp.html#a3529a74fd2a25d24de73d9d4e1c90835", null ] +]; \ No newline at end of file diff --git a/docs/utils_8hpp_source.html b/docs/utils_8hpp_source.html new file mode 100644 index 0000000..2d2a1bd --- /dev/null +++ b/docs/utils_8hpp_source.html @@ -0,0 +1,164 @@ + + + + + + + +2 Dimensional Ising Model: include/utils.hpp Source File + + + + + + + + + + + + + + + + +
    +
    + + + + + + +
    +
    2 Dimensional Ising Model +
    +
    Simulate the change in energy and magnetization in a ferro magnet
    +
    +
    + + + + + + + +
    +
    + +
    +
    +
    + +
    + +
    +
    + + +
    +
    +
    +
    +
    +
    Loading...
    +
    Searching...
    +
    No Matches
    +
    +
    +
    +
    + +
    +
    utils.hpp
    +
    +
    +Go to the documentation of this file.
    1
    +
    17#ifndef __UTILS__
    +
    18#define __UTILS__
    +
    19
    +
    20#include <armadillo>
    +
    21#include <iomanip>
    +
    22#include <sstream>
    +
    23#include <string>
    +
    24#include <sys/stat.h>
    +
    25#include <vector>
    +
    26
    +
    35#ifdef DBG
    +
    36#define DEBUG(msg) \
    +
    37 std::cout << __FILE__ << " " << __LINE__ << ": " << msg << std::endl
    +
    38#else
    +
    39#define DEBUG(msg)
    +
    40#endif
    +
    41
    +
    45#define __METHOD_NAME__ details::methodName(__PRETTY_FUNCTION__)
    +
    46
    +
    47namespace details {
    +
    58inline std::string methodName(const std::string &pretty_function)
    +
    59{
    +
    60 size_t colons = pretty_function.find("::");
    +
    61 size_t begin = pretty_function.substr(0, colons).rfind(" ") + 1;
    +
    62 size_t end = pretty_function.rfind("(") - begin;
    +
    63
    +
    64 return pretty_function.substr(begin, end) + "()";
    +
    65}
    +
    66
    +
    67} // namespace details
    +
    68
    +
    69namespace utils {
    +
    70
    +
    81std::string scientific_format(double d, int width = 20, int prec = 10);
    +
    82
    +
    94std::string scientific_format(const std::vector<double> &v, int width = 20,
    +
    95 int prec = 10);
    +
    96
    +
    107bool mkpath(std::string path, int mode = 0777);
    +
    108
    +
    115std::string dirname(const std::string &path);
    +
    116
    +
    117} // namespace utils
    +
    118
    +
    119#endif
    +
    std::string methodName(const std::string &pretty_function)
    Takes in the PRETTY_FUNCTION string and removes the return type.
    Definition: utils.hpp:58
    +
    bool mkpath(std::string path, int mode=0777)
    Make path given.
    Definition: utils.cpp:32
    +
    std::string scientific_format(double d, int width=20, int prec=10)
    Turns a double into a string written in scientific format.
    Definition: utils.cpp:16
    +
    std::string dirname(const std::string &path)
    Get the directory name of the path.
    Definition: utils.cpp:58
    +
    +
    + + + +