Compare commits
171 Commits
coryab/imp
...
janitaws/l
| Author | SHA1 | Date | |
|---|---|---|---|
| 09d81d5917 | |||
|
|
ccf492d726 | ||
|
|
82cdbaced5 | ||
| 61d9ca8a25 | |||
| 91f079fc71 | |||
|
|
30f2cda100 | ||
|
|
a9365ec35e | ||
| 7df2e46f89 | |||
|
|
ecf9aae916 | ||
|
|
d887601c7c | ||
|
|
baf780dfbb | ||
| 978616f7d9 | |||
| f06bfc0f59 | |||
| 4e09128483 | |||
| b08d6babf0 | |||
| 2b83889039 | |||
| 6f34b25e5c | |||
| bdda8a12fc | |||
| 4ee5d397e6 | |||
| 9bc6038af0 | |||
|
|
9e01ad8351 | ||
|
|
bd7f911ec5 | ||
|
|
87d13194f3 | ||
|
|
8a9152a1c1 | ||
| 5c44103471 | |||
| 82bbd1c2f4 | |||
| 6b6231fcf3 | |||
| 7257e40c4e | |||
|
|
4bfc98791c | ||
|
|
914261cf55 | ||
| c93e442d99 | |||
| 6847938827 | |||
| 16d7622283 | |||
| f7eee8dc61 | |||
| cd90d29970 | |||
| 3eb652be83 | |||
| f767cdc99b | |||
| 684b38abba | |||
| 0dfcdd5e2a | |||
| 9cacf7bbc2 | |||
| 1eb386237a | |||
| f1ca42fcf5 | |||
| 9c4e99a327 | |||
| d2824d7c1d | |||
| 1ae665e7e7 | |||
| 0dfb102cef | |||
| 79da936956 | |||
| d08a4a046c | |||
| 8f315a0955 | |||
| 8fc0bf8c13 | |||
|
|
346a800428 | ||
| bbb0203d35 | |||
|
|
937e681195 | ||
| 2b69094ff4 | |||
| bd9600b6d1 | |||
|
|
1224700312 | ||
| b985a2c25f | |||
|
|
4e14915b04 | ||
|
|
872b84d0d1 | ||
|
|
493bac88c3 | ||
| 8373deea81 | |||
| e42c108d20 | |||
| 0dfda79fda | |||
| f37385dc87 | |||
| eab84f52e9 | |||
|
|
1918dfb3f7 | ||
|
|
b8f32f1fd9 | ||
| 944c52d22f | |||
| a99eeab8b5 | |||
| eb2a985b3b | |||
| 19e35f25ec | |||
|
|
405493a888 | ||
|
|
f52892c1a6 | ||
| 2348d06070 | |||
| 335907d435 | |||
| b6a3024613 | |||
| 7269429a37 | |||
| 4551b233e9 | |||
| c2f089ee0f | |||
| 14a6d4ba15 | |||
| 76dd30df23 | |||
| 9c17608066 | |||
| 520728a9c2 | |||
| 8412e2f643 | |||
| 1741b107f7 | |||
| 6d002cf564 | |||
| d9f9940451 | |||
| 763a34ea8c | |||
| af2712cccd | |||
| 555c397d76 | |||
|
|
10a565eb24 | ||
| 58db1d9928 | |||
|
|
f359789767 | ||
| e636bf17a2 | |||
| 8783e15e9e | |||
| eb55d9b3c9 | |||
| 7714f80f8c | |||
| d8059a92e1 | |||
| 4f38357db7 | |||
|
|
d07e5a9eff | ||
|
|
4d2c24e92b | ||
|
|
0163bc3d21 | ||
| d7246b05b1 | |||
| 5ed7cedfae | |||
| f29424f96e | |||
| 95432102ea | |||
| 0fc1ec1e33 | |||
| 03344c3298 | |||
| 56080de561 | |||
| 655bf6aceb | |||
| 58e5ed5c69 | |||
| 7c76c2f08c | |||
| 3431e09aeb | |||
| 58c9212e5c | |||
| 22c8b9707d | |||
| c4aa6f2179 | |||
| 69491d1c02 | |||
| 11757e5e28 | |||
| ae7b437ac3 | |||
| 720f1815d2 | |||
| 13c662c148 | |||
| 8df35f90f5 | |||
| d2047e43e0 | |||
| bb0bd8f6a0 | |||
| 2fd0ab9875 | |||
| 0b52008d4d | |||
| 51a381e672 | |||
| 5173a9e6f8 | |||
| a624173870 | |||
| 65a5700bf7 | |||
| ff1fe59268 | |||
| e9c2db5d73 | |||
| f3a8963f15 | |||
| e17da401ec | |||
| b5acec572f | |||
| aef5c4ee45 | |||
| 8b3ef4dfbb | |||
| 9ff96544d4 | |||
| ad2865c3a2 | |||
| 0e82f8cac1 | |||
| 8a2100a334 | |||
| a24635ede0 | |||
| 709d0c5411 | |||
| b1b7c1fdd0 | |||
| 21b94acbd8 | |||
| 6307256edc | |||
| 07197c1902 | |||
| 6112e36c22 | |||
| 0b8b5f88a6 | |||
|
|
1841de0693 | ||
|
|
1e12f8d0f1 | ||
|
|
b699ca4dee | ||
|
|
89e50a32a4 | ||
|
|
ef3af22876 | ||
| 9bf313ef02 | |||
| d759c6c8e4 | |||
| b9d39559ab | |||
| dfb287e0b2 | |||
| b5c5020506 | |||
| 5509efc301 | |||
| 25f018f35f | |||
| b26137ea33 | |||
| 8d193cf469 | |||
| eb989e0293 | |||
| c611fa70a2 | |||
| ad10bf1948 | |||
| 8e9f3db316 | |||
| f2e9004f96 | |||
| f1f1eecf07 | |||
| bd53af7829 | |||
| b856834adc |
44
.clang-format
Normal file
44
.clang-format
Normal file
@@ -0,0 +1,44 @@
|
||||
# Set the language to C++
|
||||
Language: Cpp
|
||||
|
||||
# Set the language standard to C++11
|
||||
Standard: Cpp11
|
||||
|
||||
# Never use tab for indentation
|
||||
UseTab: Never
|
||||
|
||||
# Set the indent width to be 4 columns
|
||||
IndentWidth: 4
|
||||
|
||||
# Set tab width to be 4 columns
|
||||
TabWidth: 4
|
||||
|
||||
# Set access modifier (public, private, protected) offset to indent left
|
||||
AccessModifierOffset: -4
|
||||
|
||||
# Stop indentation of access modifiers
|
||||
IndentAccessModifiers: false
|
||||
|
||||
# Don't allow a function to be defined on a single line
|
||||
AllowShortFunctionsOnASingleLine: false
|
||||
|
||||
# Set the column limit to 80 characters
|
||||
ColumnLimit: 80
|
||||
|
||||
# If an expression has to be split, then split before binary operators unless
|
||||
# it's an assignment operator.
|
||||
BreakBeforeBinaryOperators: NonAssignment
|
||||
|
||||
# Use a Linux style brace break.
|
||||
# Break before braces on function, namespace and class definitions.
|
||||
BreakBeforeBraces: Linux
|
||||
|
||||
|
||||
# If true, spaces will be inserted after ( and before ).
|
||||
SpacesInParentheses: false
|
||||
|
||||
# If true, spaces will be inserted after [ and before ].
|
||||
SpacesInSquareBrackets: false
|
||||
|
||||
# Separate definition blocks (classes, functions, structs, enums)
|
||||
SeparateDefinitionBlocks: Always
|
||||
8
.gitignore
vendored
8
.gitignore
vendored
@@ -35,9 +35,11 @@
|
||||
*.aux
|
||||
*.log
|
||||
*.out
|
||||
*.bib
|
||||
*.synctex.gz
|
||||
*.bbl
|
||||
*.blg
|
||||
latex/mainNotes.bib
|
||||
|
||||
|
||||
# C++ specifics
|
||||
src/*
|
||||
@@ -46,3 +48,7 @@ src/*
|
||||
!src/*.hpp
|
||||
!src/*.py
|
||||
!src/Doxyfile
|
||||
!src/scripts
|
||||
|
||||
# Job
|
||||
!src/job.script
|
||||
|
||||
6
Doxyfile
6
Doxyfile
@@ -917,7 +917,7 @@ WARN_LOGFILE =
|
||||
# spaces. See also FILE_PATTERNS and EXTENSION_MAPPING
|
||||
# Note: If this tag is empty the current directory is searched.
|
||||
|
||||
INPUT = include src README.md
|
||||
INPUT = include src src/scripts README.md
|
||||
|
||||
# This tag can be used to specify the character encoding of the source files
|
||||
# that doxygen parses. Internally doxygen uses the UTF-8 encoding. Doxygen uses
|
||||
@@ -1070,7 +1070,7 @@ EXAMPLE_RECURSIVE = NO
|
||||
# that contain images that are to be included in the documentation (see the
|
||||
# \image command).
|
||||
|
||||
IMAGE_PATH =
|
||||
IMAGE_PATH = ./images
|
||||
|
||||
# The INPUT_FILTER tag can be used to specify a program that doxygen should
|
||||
# invoke to filter for each input file. Doxygen will invoke the filter program
|
||||
@@ -2174,7 +2174,7 @@ RTF_EXTENSIONS_FILE =
|
||||
# classes and files.
|
||||
# The default value is: NO.
|
||||
|
||||
GENERATE_MAN = YES
|
||||
GENERATE_MAN = NO
|
||||
|
||||
# The MAN_OUTPUT tag is used to specify where the man pages will be put. If a
|
||||
# relative path is entered the value of OUTPUT_DIRECTORY will be put in front of
|
||||
|
||||
114
README.md
114
README.md
@@ -1,5 +1,119 @@
|
||||
# Penning trap simulation
|
||||
|
||||

|
||||
|
||||
[Repo](https://github.uio.no/FYS3150-G2-2023/Project-3)
|
||||
|
||||
[Documentation](https://pages.github.uio.no/FYS3150-G2-2023/Project-3/)
|
||||
|
||||
## Requirements
|
||||
|
||||
### Operating systems
|
||||
|
||||
- Linux
|
||||
- Has been tested on [Fedora 38](https://fedoraproject.org/)
|
||||
- Will most likely work on other Linux distributions
|
||||
- MacOS
|
||||
- Might work, but hasn't been tested
|
||||
- Windows
|
||||
- Will most likely not work
|
||||
|
||||
### Tools
|
||||
|
||||
- Profiling
|
||||
- [gprof](https://ftp.gnu.org/old-gnu/Manuals/gprof-2.9.1/html_mono/gprof.html)
|
||||
- [scalasca](https://www.scalasca.org/)
|
||||
- [score-p](https://www.vi-hps.org/projects/score-p)
|
||||
|
||||
### Libraries
|
||||
|
||||
- Python
|
||||
- [matplotlib](https://matplotlib.org/)
|
||||
- [numpy](https://numpy.org/)
|
||||
|
||||
- C++
|
||||
- [openmp](https://www.openmp.org/)
|
||||
- [armadillo](https://arma.sourceforge.net/)
|
||||
|
||||
|
||||
## Compiling
|
||||
|
||||
Compiling is as easy as running this command while being inside the src directory:
|
||||
|
||||
```shell
|
||||
make
|
||||
```
|
||||
|
||||
## Running programs
|
||||
|
||||
### C++ binaries
|
||||
|
||||
To run **main** or **test_suite**, just run this command while being inside src:
|
||||
|
||||
```shell
|
||||
./<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:
|
||||
|
||||
```shell
|
||||
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:
|
||||
|
||||
```shell
|
||||
python scripts/<script-name>
|
||||
```
|
||||
|
||||
If you have any problems running the scripts, you might have to run this instead:
|
||||
|
||||
```shell
|
||||
python3 scripts/<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
|
||||
|
||||
All times mentioned use the **evolve_RK4** method.
|
||||
|
||||
Running a simulation with 100 particles without particle interactions over
|
||||
40000 steps takes around 1.8 seconds. With particle interactions, it takes
|
||||
around 4.8 seconds.
|
||||
|
||||
**potential_resonance_wide_sweep** takes around 56 seconds to complete.
|
||||
|
||||
**potential_resonance_narrow_sweep** takes around 172 seconds to complete.
|
||||
|
||||
**potential_resonance_narrow_sweep_interaction** takes around 936 seconds to
|
||||
complete.
|
||||
|
||||
## Credits
|
||||
|
||||
The Doxygen theme used here is
|
||||
|
||||
BIN
docs/100_particles.gif
Normal file
BIN
docs/100_particles.gif
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.5 MiB |
@@ -112,8 +112,8 @@ $(document).ready(function(){initNavTree('Particle_8cpp.html',''); initResizable
|
||||
<dl class="section author"><dt>Author</dt><dd>Cory Alexander Balaton (coryab) </dd>
|
||||
<dd>
|
||||
Janita Ovidie Sandtrøen Willumsen (janitaws)</dd></dl>
|
||||
<dl class="section version"><dt>Version</dt><dd>0.1</dd></dl>
|
||||
<dl class="bug"><dt><b><a class="el" href="bug.html#_bug000006">Bug:</a></b></dt><dd>No known bugs</dd></dl>
|
||||
<dl class="section version"><dt>Version</dt><dd>1.0</dd></dl>
|
||||
<dl class="bug"><dt><b><a class="el" href="bug.html#_bug000007">Bug:</a></b></dt><dd>No known bugs </dd></dl>
|
||||
|
||||
<p class="definition">Definition in file <a class="el" href="Particle_8cpp_source.html">Particle.cpp</a>.</p>
|
||||
</div></div><!-- contents -->
|
||||
|
||||
@@ -102,24 +102,23 @@ $(document).ready(function(){initNavTree('Particle_8cpp_source.html',''); initRe
|
||||
</div><!--header-->
|
||||
<div class="contents">
|
||||
<a href="Particle_8cpp.html">Go to the documentation of this file.</a><div class="fragment"><div class="line"><a id="l00001" name="l00001"></a><span class="lineno"> 1</span> </div>
|
||||
<div class="line"><a id="l00014" name="l00014"></a><span class="lineno"> 14</span><span class="preprocessor">#include "<a class="code" href="Particle_8hpp.html">Particle.hpp</a>"</span></div>
|
||||
<div class="line"><a id="l00015" name="l00015"></a><span class="lineno"> 15</span> </div>
|
||||
<div class="line"><a id="l00016" name="l00016"></a><span class="lineno"><a class="line" href="classParticle.html#a00e108823877a25513ccae7cac011b4c"> 16</a></span><a class="code hl_function" href="classParticle.html#a00e108823877a25513ccae7cac011b4c">Particle::Particle</a>(<span class="keywordtype">double</span> q, <span class="keywordtype">double</span> m,</div>
|
||||
<div class="line"><a id="l00017" name="l00017"></a><span class="lineno"> 17</span> arma::vec::fixed<3> r_vec,</div>
|
||||
<div class="line"><a id="l00018" name="l00018"></a><span class="lineno"> 18</span> arma::vec::fixed<3> v_vec)</div>
|
||||
<div class="line"><a id="l00019" name="l00019"></a><span class="lineno"> 19</span>{</div>
|
||||
<div class="line"><a id="l00020" name="l00020"></a><span class="lineno"> 20</span> <span class="comment">// Giving the particle its properties</span></div>
|
||||
<div class="line"><a id="l00021" name="l00021"></a><span class="lineno"> 21</span> this->q = <a class="code hl_variable" href="classParticle.html#a566dcc1de4bdc01251776948798ea8e1">q</a>;</div>
|
||||
<div class="line"><a id="l00022" name="l00022"></a><span class="lineno"> 22</span> this->m = <a class="code hl_variable" href="classParticle.html#aedcc7e1bc53b0e2b1a4a07c9a1b47563">m</a>;</div>
|
||||
<div class="line"><a id="l00023" name="l00023"></a><span class="lineno"> 23</span> this->r_vec = <a class="code hl_variable" href="classParticle.html#acf1a0f3c978b06d76df5bb4279594467">r_vec</a>;</div>
|
||||
<div class="line"><a id="l00024" name="l00024"></a><span class="lineno"> 24</span> this->v_vec = <a class="code hl_variable" href="classParticle.html#a4a5d22c7aeca66f67d083f270cba25df">v_vec</a>;</div>
|
||||
<div class="line"><a id="l00025" name="l00025"></a><span class="lineno"> 25</span>}</div>
|
||||
<div class="line"><a id="l00013" name="l00013"></a><span class="lineno"> 13</span><span class="preprocessor">#include "<a class="code" href="Particle_8hpp.html">Particle.hpp</a>"</span></div>
|
||||
<div class="line"><a id="l00014" name="l00014"></a><span class="lineno"> 14</span> </div>
|
||||
<div class="line"><a id="l00015" name="l00015"></a><span class="lineno"><a class="line" href="classParticle.html#af1d7535fb8311eaa77d2b7b345882ec4"> 15</a></span><a class="code hl_function" href="classParticle.html#af1d7535fb8311eaa77d2b7b345882ec4">Particle::Particle</a>(<a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> r_vec, <a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> v_vec, <span class="keywordtype">double</span> q, <span class="keywordtype">double</span> m)</div>
|
||||
<div class="line"><a id="l00016" name="l00016"></a><span class="lineno"> 16</span>{</div>
|
||||
<div class="line"><a id="l00017" name="l00017"></a><span class="lineno"> 17</span> <span class="comment">// Giving the particle its properties</span></div>
|
||||
<div class="line"><a id="l00018" name="l00018"></a><span class="lineno"> 18</span> this->r_vec = <a class="code hl_variable" href="classParticle.html#a1c59101411db43624828b766f87ad460">r_vec</a>;</div>
|
||||
<div class="line"><a id="l00019" name="l00019"></a><span class="lineno"> 19</span> this->v_vec = <a class="code hl_variable" href="classParticle.html#a3a10400add8dd22b8031330c2aafb6fe">v_vec</a>;</div>
|
||||
<div class="line"><a id="l00020" name="l00020"></a><span class="lineno"> 20</span> this->q = <a class="code hl_variable" href="classParticle.html#a566dcc1de4bdc01251776948798ea8e1">q</a>;</div>
|
||||
<div class="line"><a id="l00021" name="l00021"></a><span class="lineno"> 21</span> this->m = <a class="code hl_variable" href="classParticle.html#aedcc7e1bc53b0e2b1a4a07c9a1b47563">m</a>;</div>
|
||||
<div class="line"><a id="l00022" name="l00022"></a><span class="lineno"> 22</span>}</div>
|
||||
<div class="ttc" id="aParticle_8hpp_html"><div class="ttname"><a href="Particle_8hpp.html">Particle.hpp</a></div><div class="ttdoc">A class that holds the properties of a particle.</div></div>
|
||||
<div class="ttc" id="aclassParticle_html_a00e108823877a25513ccae7cac011b4c"><div class="ttname"><a href="classParticle.html#a00e108823877a25513ccae7cac011b4c">Particle::Particle</a></div><div class="ttdeci">Particle(double q, double m, arma::vec::fixed< 3 > r_vec, arma::vec::fixed< 3 > v_vec)</div><div class="ttdoc">Initialize the particle.</div><div class="ttdef"><b>Definition:</b> <a href="Particle_8cpp_source.html#l00016">Particle.cpp:16</a></div></div>
|
||||
<div class="ttc" id="aclassParticle_html_a4a5d22c7aeca66f67d083f270cba25df"><div class="ttname"><a href="classParticle.html#a4a5d22c7aeca66f67d083f270cba25df">Particle::v_vec</a></div><div class="ttdeci">arma::vec::fixed< 3 > v_vec</div><div class="ttdoc">velocity</div><div class="ttdef"><b>Definition:</b> <a href="Particle_8hpp_source.html#l00024">Particle.hpp:24</a></div></div>
|
||||
<div class="ttc" id="aclassParticle_html_a566dcc1de4bdc01251776948798ea8e1"><div class="ttname"><a href="classParticle.html#a566dcc1de4bdc01251776948798ea8e1">Particle::q</a></div><div class="ttdeci">double q</div><div class="ttdoc">Charge.</div><div class="ttdef"><b>Definition:</b> <a href="Particle_8hpp_source.html#l00021">Particle.hpp:21</a></div></div>
|
||||
<div class="ttc" id="aclassParticle_html_acf1a0f3c978b06d76df5bb4279594467"><div class="ttname"><a href="classParticle.html#acf1a0f3c978b06d76df5bb4279594467">Particle::r_vec</a></div><div class="ttdeci">arma::vec::fixed< 3 > r_vec</div><div class="ttdoc">position</div><div class="ttdef"><b>Definition:</b> <a href="Particle_8hpp_source.html#l00023">Particle.hpp:23</a></div></div>
|
||||
<div class="ttc" id="aclassParticle_html_aedcc7e1bc53b0e2b1a4a07c9a1b47563"><div class="ttname"><a href="classParticle.html#aedcc7e1bc53b0e2b1a4a07c9a1b47563">Particle::m</a></div><div class="ttdeci">double m</div><div class="ttdoc">Mass.</div><div class="ttdef"><b>Definition:</b> <a href="Particle_8hpp_source.html#l00022">Particle.hpp:22</a></div></div>
|
||||
<div class="ttc" id="aclassParticle_html_a1c59101411db43624828b766f87ad460"><div class="ttname"><a href="classParticle.html#a1c59101411db43624828b766f87ad460">Particle::r_vec</a></div><div class="ttdeci">vec3 r_vec</div><div class="ttdoc">position</div><div class="ttdef"><b>Definition:</b> <a href="Particle_8hpp_source.html#l00025">Particle.hpp:25</a></div></div>
|
||||
<div class="ttc" id="aclassParticle_html_a3a10400add8dd22b8031330c2aafb6fe"><div class="ttname"><a href="classParticle.html#a3a10400add8dd22b8031330c2aafb6fe">Particle::v_vec</a></div><div class="ttdeci">vec3 v_vec</div><div class="ttdoc">velocity</div><div class="ttdef"><b>Definition:</b> <a href="Particle_8hpp_source.html#l00026">Particle.hpp:26</a></div></div>
|
||||
<div class="ttc" id="aclassParticle_html_a566dcc1de4bdc01251776948798ea8e1"><div class="ttname"><a href="classParticle.html#a566dcc1de4bdc01251776948798ea8e1">Particle::q</a></div><div class="ttdeci">double q</div><div class="ttdoc">Charge.</div><div class="ttdef"><b>Definition:</b> <a href="Particle_8hpp_source.html#l00027">Particle.hpp:27</a></div></div>
|
||||
<div class="ttc" id="aclassParticle_html_aedcc7e1bc53b0e2b1a4a07c9a1b47563"><div class="ttname"><a href="classParticle.html#aedcc7e1bc53b0e2b1a4a07c9a1b47563">Particle::m</a></div><div class="ttdeci">double m</div><div class="ttdoc">Mass.</div><div class="ttdef"><b>Definition:</b> <a href="Particle_8hpp_source.html#l00028">Particle.hpp:28</a></div></div>
|
||||
<div class="ttc" id="aclassParticle_html_af1d7535fb8311eaa77d2b7b345882ec4"><div class="ttname"><a href="classParticle.html#af1d7535fb8311eaa77d2b7b345882ec4">Particle::Particle</a></div><div class="ttdeci">Particle(vec3 r_vec, vec3 v_vec, double q=CA_CHARGE, double m=CA_MASS)</div><div class="ttdoc">Initialize the particle.</div><div class="ttdef"><b>Definition:</b> <a href="Particle_8cpp_source.html#l00015">Particle.cpp:15</a></div></div>
|
||||
<div class="ttc" id="atypedefs_8hpp_html_a3bdfb73a02f88ae32b6128ef747c4aea"><div class="ttname"><a href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a></div><div class="ttdeci">arma::vec::fixed< 3 > vec3</div><div class="ttdoc">Typedef for a fixed 3d arma vector.</div><div class="ttdef"><b>Definition:</b> <a href="typedefs_8hpp_source.html#l00023">typedefs.hpp:23</a></div></div>
|
||||
</div><!-- fragment --></div><!-- contents -->
|
||||
</div><!-- doc-content -->
|
||||
<!-- start footer part -->
|
||||
|
||||
@@ -107,6 +107,8 @@ $(document).ready(function(){initNavTree('Particle_8hpp.html',''); initResizable
|
||||
<p>A class that holds the properties of a particle.
|
||||
<a href="#details">More...</a></p>
|
||||
<div class="textblock"><code>#include <armadillo></code><br />
|
||||
<code>#include "<a class="el" href="constants_8hpp_source.html">constants.hpp</a>"</code><br />
|
||||
<code>#include "<a class="el" href="typedefs_8hpp_source.html">typedefs.hpp</a>"</code><br />
|
||||
</div>
|
||||
<p><a href="Particle_8hpp_source.html">Go to the source code of this file.</a></p>
|
||||
<table class="memberdecls">
|
||||
@@ -121,7 +123,7 @@ Classes</h2></td></tr>
|
||||
<dl class="section author"><dt>Author</dt><dd>Cory Alexander Balaton (coryab) </dd>
|
||||
<dd>
|
||||
Janita Ovidie Sandtrøen Willumsen (janitaws)</dd></dl>
|
||||
<dl class="section version"><dt>Version</dt><dd>0.1</dd></dl>
|
||||
<dl class="section version"><dt>Version</dt><dd>1.0</dd></dl>
|
||||
<dl class="bug"><dt><b><a class="el" href="bug.html#_bug000002">Bug:</a></b></dt><dd>No known bugs </dd></dl>
|
||||
|
||||
<p class="definition">Definition in file <a class="el" href="Particle_8hpp_source.html">Particle.hpp</a>.</p>
|
||||
|
||||
@@ -107,28 +107,35 @@ $(document).ready(function(){initNavTree('Particle_8hpp_source.html',''); initRe
|
||||
<div class="line"><a id="l00014" name="l00014"></a><span class="lineno"> 14</span> </div>
|
||||
<div class="line"><a id="l00015" name="l00015"></a><span class="lineno"> 15</span><span class="preprocessor">#include <armadillo></span></div>
|
||||
<div class="line"><a id="l00016" name="l00016"></a><span class="lineno"> 16</span> </div>
|
||||
<div class="line"><a id="l00019" name="l00019"></a><span class="lineno"><a class="line" href="classParticle.html"> 19</a></span><span class="keyword">class </span><a class="code hl_class" href="classParticle.html">Particle</a> {</div>
|
||||
<div class="line"><a id="l00020" name="l00020"></a><span class="lineno"> 20</span><span class="keyword">private</span>:</div>
|
||||
<div class="line"><a id="l00021" name="l00021"></a><span class="lineno"><a class="line" href="classParticle.html#a566dcc1de4bdc01251776948798ea8e1"> 21</a></span> <span class="keywordtype">double</span> <a class="code hl_variable" href="classParticle.html#a566dcc1de4bdc01251776948798ea8e1">q</a>; </div>
|
||||
<div class="line"><a id="l00022" name="l00022"></a><span class="lineno"><a class="line" href="classParticle.html#aedcc7e1bc53b0e2b1a4a07c9a1b47563"> 22</a></span> <span class="keywordtype">double</span> <a class="code hl_variable" href="classParticle.html#aedcc7e1bc53b0e2b1a4a07c9a1b47563">m</a>; </div>
|
||||
<div class="line"><a id="l00023" name="l00023"></a><span class="lineno"><a class="line" href="classParticle.html#acf1a0f3c978b06d76df5bb4279594467"> 23</a></span> arma::vec::fixed<3> <a class="code hl_variable" href="classParticle.html#acf1a0f3c978b06d76df5bb4279594467">r_vec</a>; </div>
|
||||
<div class="line"><a id="l00024" name="l00024"></a><span class="lineno"><a class="line" href="classParticle.html#a4a5d22c7aeca66f67d083f270cba25df"> 24</a></span> arma::vec::fixed<3> <a class="code hl_variable" href="classParticle.html#a4a5d22c7aeca66f67d083f270cba25df">v_vec</a>; </div>
|
||||
<div class="line"><a id="l00025" name="l00025"></a><span class="lineno"> 25</span> </div>
|
||||
<div class="line"><a id="l00026" name="l00026"></a><span class="lineno"> 26</span><span class="keyword">public</span>:</div>
|
||||
<div class="line"><a id="l00032" name="l00032"></a><span class="lineno"> 32</span> <a class="code hl_class" href="classParticle.html">Particle</a>(<span class="keywordtype">double</span> <a class="code hl_variable" href="classParticle.html#a566dcc1de4bdc01251776948798ea8e1">q</a>, <span class="keywordtype">double</span> <a class="code hl_variable" href="classParticle.html#aedcc7e1bc53b0e2b1a4a07c9a1b47563">m</a>, </div>
|
||||
<div class="line"><a id="l00033" name="l00033"></a><span class="lineno"> 33</span> arma::vec::fixed<3> <a class="code hl_variable" href="classParticle.html#acf1a0f3c978b06d76df5bb4279594467">r_vec</a>, </div>
|
||||
<div class="line"><a id="l00034" name="l00034"></a><span class="lineno"> 34</span> arma::vec::fixed<3> <a class="code hl_variable" href="classParticle.html#a4a5d22c7aeca66f67d083f270cba25df">v_vec</a>);</div>
|
||||
<div class="line"><a id="l00035" name="l00035"></a><span class="lineno"> 35</span> </div>
|
||||
<div class="line"><a id="l00038" name="l00038"></a><span class="lineno"><a class="line" href="classParticle.html#aa797d319549dc2a0beb06cdbfd430232"> 38</a></span> <span class="keyword">friend</span> <span class="keyword">class </span><a class="code hl_class" href="classPenningTrap.html">PenningTrap</a>;</div>
|
||||
<div class="line"><a id="l00039" name="l00039"></a><span class="lineno"> 39</span>};</div>
|
||||
<div class="line"><a id="l00040" name="l00040"></a><span class="lineno"> 40</span> </div>
|
||||
<div class="line"><a id="l00041" name="l00041"></a><span class="lineno"> 41</span><span class="preprocessor">#endif</span></div>
|
||||
<div class="ttc" id="aclassParticle_html"><div class="ttname"><a href="classParticle.html">Particle</a></div><div class="ttdoc">A class that holds attributes of a particle.</div><div class="ttdef"><b>Definition:</b> <a href="Particle_8hpp_source.html#l00019">Particle.hpp:19</a></div></div>
|
||||
<div class="ttc" id="aclassParticle_html_a4a5d22c7aeca66f67d083f270cba25df"><div class="ttname"><a href="classParticle.html#a4a5d22c7aeca66f67d083f270cba25df">Particle::v_vec</a></div><div class="ttdeci">arma::vec::fixed< 3 > v_vec</div><div class="ttdoc">velocity</div><div class="ttdef"><b>Definition:</b> <a href="Particle_8hpp_source.html#l00024">Particle.hpp:24</a></div></div>
|
||||
<div class="ttc" id="aclassParticle_html_a566dcc1de4bdc01251776948798ea8e1"><div class="ttname"><a href="classParticle.html#a566dcc1de4bdc01251776948798ea8e1">Particle::q</a></div><div class="ttdeci">double q</div><div class="ttdoc">Charge.</div><div class="ttdef"><b>Definition:</b> <a href="Particle_8hpp_source.html#l00021">Particle.hpp:21</a></div></div>
|
||||
<div class="ttc" id="aclassParticle_html_acf1a0f3c978b06d76df5bb4279594467"><div class="ttname"><a href="classParticle.html#acf1a0f3c978b06d76df5bb4279594467">Particle::r_vec</a></div><div class="ttdeci">arma::vec::fixed< 3 > r_vec</div><div class="ttdoc">position</div><div class="ttdef"><b>Definition:</b> <a href="Particle_8hpp_source.html#l00023">Particle.hpp:23</a></div></div>
|
||||
<div class="ttc" id="aclassParticle_html_aedcc7e1bc53b0e2b1a4a07c9a1b47563"><div class="ttname"><a href="classParticle.html#aedcc7e1bc53b0e2b1a4a07c9a1b47563">Particle::m</a></div><div class="ttdeci">double m</div><div class="ttdoc">Mass.</div><div class="ttdef"><b>Definition:</b> <a href="Particle_8hpp_source.html#l00022">Particle.hpp:22</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html"><div class="ttname"><a href="classPenningTrap.html">PenningTrap</a></div><div class="ttdoc">A class that simulates a Penning trap.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8hpp_source.html#l00025">PenningTrap.hpp:25</a></div></div>
|
||||
<div class="line"><a id="l00017" name="l00017"></a><span class="lineno"> 17</span><span class="preprocessor">#include "<a class="code" href="constants_8hpp.html">constants.hpp</a>"</span></div>
|
||||
<div class="line"><a id="l00018" name="l00018"></a><span class="lineno"> 18</span><span class="preprocessor">#include "<a class="code" href="typedefs_8hpp.html">typedefs.hpp</a>"</span></div>
|
||||
<div class="line"><a id="l00019" name="l00019"></a><span class="lineno"> 19</span> </div>
|
||||
<div class="line"><a id="l00022" name="l00022"></a><span class="lineno"><a class="line" href="classParticle.html"> 22</a></span><span class="keyword">class </span><a class="code hl_class" href="classParticle.html">Particle</a></div>
|
||||
<div class="line"><a id="l00023" name="l00023"></a><span class="lineno"> 23</span>{</div>
|
||||
<div class="line"><a id="l00024" name="l00024"></a><span class="lineno"> 24</span><span class="keyword">private</span>:</div>
|
||||
<div class="line"><a id="l00025" name="l00025"></a><span class="lineno"><a class="line" href="classParticle.html#a1c59101411db43624828b766f87ad460"> 25</a></span> <a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> <a class="code hl_variable" href="classParticle.html#a1c59101411db43624828b766f87ad460">r_vec</a>; </div>
|
||||
<div class="line"><a id="l00026" name="l00026"></a><span class="lineno"><a class="line" href="classParticle.html#a3a10400add8dd22b8031330c2aafb6fe"> 26</a></span> <a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> <a class="code hl_variable" href="classParticle.html#a3a10400add8dd22b8031330c2aafb6fe">v_vec</a>; </div>
|
||||
<div class="line"><a id="l00027" name="l00027"></a><span class="lineno"><a class="line" href="classParticle.html#a566dcc1de4bdc01251776948798ea8e1"> 27</a></span> <span class="keywordtype">double</span> <a class="code hl_variable" href="classParticle.html#a566dcc1de4bdc01251776948798ea8e1">q</a>; </div>
|
||||
<div class="line"><a id="l00028" name="l00028"></a><span class="lineno"><a class="line" href="classParticle.html#aedcc7e1bc53b0e2b1a4a07c9a1b47563"> 28</a></span> <span class="keywordtype">double</span> <a class="code hl_variable" href="classParticle.html#aedcc7e1bc53b0e2b1a4a07c9a1b47563">m</a>; </div>
|
||||
<div class="line"><a id="l00029" name="l00029"></a><span class="lineno"> 29</span> </div>
|
||||
<div class="line"><a id="l00030" name="l00030"></a><span class="lineno"> 30</span><span class="keyword">public</span>:</div>
|
||||
<div class="line"><a id="l00041" name="l00041"></a><span class="lineno"> 41</span> <a class="code hl_class" href="classParticle.html">Particle</a>(<a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> <a class="code hl_variable" href="classParticle.html#a1c59101411db43624828b766f87ad460">r_vec</a>, <a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> <a class="code hl_variable" href="classParticle.html#a3a10400add8dd22b8031330c2aafb6fe">v_vec</a>, <span class="keywordtype">double</span> <a class="code hl_variable" href="classParticle.html#a566dcc1de4bdc01251776948798ea8e1">q</a> = <a class="code hl_define" href="constants_8hpp.html#af7602a3a314957137ad1cd719aa23789">CA_CHARGE</a>, <span class="keywordtype">double</span> <a class="code hl_variable" href="classParticle.html#aedcc7e1bc53b0e2b1a4a07c9a1b47563">m</a> = <a class="code hl_define" href="constants_8hpp.html#a2ff491cc7958ffd5e749c518a4a60ec8">CA_MASS</a>);</div>
|
||||
<div class="line"><a id="l00042" name="l00042"></a><span class="lineno"> 42</span> </div>
|
||||
<div class="line"><a id="l00045" name="l00045"></a><span class="lineno"><a class="line" href="classParticle.html#aa797d319549dc2a0beb06cdbfd430232"> 45</a></span> <span class="keyword">friend</span> <span class="keyword">class </span><a class="code hl_class" href="classPenningTrap.html">PenningTrap</a>;</div>
|
||||
<div class="line"><a id="l00046" name="l00046"></a><span class="lineno"> 46</span>};</div>
|
||||
<div class="line"><a id="l00047" name="l00047"></a><span class="lineno"> 47</span> </div>
|
||||
<div class="line"><a id="l00048" name="l00048"></a><span class="lineno"> 48</span><span class="preprocessor">#endif</span></div>
|
||||
<div class="ttc" id="aclassParticle_html"><div class="ttname"><a href="classParticle.html">Particle</a></div><div class="ttdoc">A class that holds attributes of a particle.</div><div class="ttdef"><b>Definition:</b> <a href="Particle_8hpp_source.html#l00022">Particle.hpp:23</a></div></div>
|
||||
<div class="ttc" id="aclassParticle_html_a1c59101411db43624828b766f87ad460"><div class="ttname"><a href="classParticle.html#a1c59101411db43624828b766f87ad460">Particle::r_vec</a></div><div class="ttdeci">vec3 r_vec</div><div class="ttdoc">position</div><div class="ttdef"><b>Definition:</b> <a href="Particle_8hpp_source.html#l00025">Particle.hpp:25</a></div></div>
|
||||
<div class="ttc" id="aclassParticle_html_a3a10400add8dd22b8031330c2aafb6fe"><div class="ttname"><a href="classParticle.html#a3a10400add8dd22b8031330c2aafb6fe">Particle::v_vec</a></div><div class="ttdeci">vec3 v_vec</div><div class="ttdoc">velocity</div><div class="ttdef"><b>Definition:</b> <a href="Particle_8hpp_source.html#l00026">Particle.hpp:26</a></div></div>
|
||||
<div class="ttc" id="aclassParticle_html_a566dcc1de4bdc01251776948798ea8e1"><div class="ttname"><a href="classParticle.html#a566dcc1de4bdc01251776948798ea8e1">Particle::q</a></div><div class="ttdeci">double q</div><div class="ttdoc">Charge.</div><div class="ttdef"><b>Definition:</b> <a href="Particle_8hpp_source.html#l00027">Particle.hpp:27</a></div></div>
|
||||
<div class="ttc" id="aclassParticle_html_aedcc7e1bc53b0e2b1a4a07c9a1b47563"><div class="ttname"><a href="classParticle.html#aedcc7e1bc53b0e2b1a4a07c9a1b47563">Particle::m</a></div><div class="ttdeci">double m</div><div class="ttdoc">Mass.</div><div class="ttdef"><b>Definition:</b> <a href="Particle_8hpp_source.html#l00028">Particle.hpp:28</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html"><div class="ttname"><a href="classPenningTrap.html">PenningTrap</a></div><div class="ttdoc">A class that simulates a Penning trap.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8hpp_source.html#l00031">PenningTrap.hpp:32</a></div></div>
|
||||
<div class="ttc" id="aconstants_8hpp_html"><div class="ttname"><a href="constants_8hpp.html">constants.hpp</a></div><div class="ttdoc">Library of constants.</div></div>
|
||||
<div class="ttc" id="aconstants_8hpp_html_a2ff491cc7958ffd5e749c518a4a60ec8"><div class="ttname"><a href="constants_8hpp.html#a2ff491cc7958ffd5e749c518a4a60ec8">CA_MASS</a></div><div class="ttdeci">#define CA_MASS</div><div class="ttdoc">Mass of a single calcium ion. unit: amu.</div><div class="ttdef"><b>Definition:</b> <a href="constants_8hpp_source.html#l00029">constants.hpp:29</a></div></div>
|
||||
<div class="ttc" id="aconstants_8hpp_html_af7602a3a314957137ad1cd719aa23789"><div class="ttname"><a href="constants_8hpp.html#af7602a3a314957137ad1cd719aa23789">CA_CHARGE</a></div><div class="ttdeci">#define CA_CHARGE</div><div class="ttdoc">Charge of a singly charged calcium ion. unit: e.</div><div class="ttdef"><b>Definition:</b> <a href="constants_8hpp_source.html#l00033">constants.hpp:33</a></div></div>
|
||||
<div class="ttc" id="atypedefs_8hpp_html"><div class="ttname"><a href="typedefs_8hpp.html">typedefs.hpp</a></div><div class="ttdoc">Useful typedefs for cleaner code.</div></div>
|
||||
<div class="ttc" id="atypedefs_8hpp_html_a3bdfb73a02f88ae32b6128ef747c4aea"><div class="ttname"><a href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a></div><div class="ttdeci">arma::vec::fixed< 3 > vec3</div><div class="ttdoc">Typedef for a fixed 3d arma vector.</div><div class="ttdef"><b>Definition:</b> <a href="typedefs_8hpp_source.html#l00023">typedefs.hpp:23</a></div></div>
|
||||
</div><!-- fragment --></div><!-- contents -->
|
||||
</div><!-- doc-content -->
|
||||
<!-- start footer part -->
|
||||
|
||||
@@ -105,6 +105,11 @@ $(document).ready(function(){initNavTree('PenningTrap_8cpp.html',''); initResiza
|
||||
<p>The implementation of the <a class="el" href="classPenningTrap.html" title="A class that simulates a Penning trap.">PenningTrap</a> class.
|
||||
<a href="#details">More...</a></p>
|
||||
<div class="textblock"><code>#include "<a class="el" href="PenningTrap_8hpp_source.html">PenningTrap.hpp</a>"</code><br />
|
||||
<code>#include "<a class="el" href="typedefs_8hpp_source.html">typedefs.hpp</a>"</code><br />
|
||||
<code>#include <algorithm></code><br />
|
||||
<code>#include <functional></code><br />
|
||||
<code>#include <sys/types.h></code><br />
|
||||
<code>#include <vector></code><br />
|
||||
</div>
|
||||
<p><a href="PenningTrap_8cpp_source.html">Go to the source code of this file.</a></p>
|
||||
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
|
||||
@@ -112,19 +117,8 @@ $(document).ready(function(){initNavTree('PenningTrap_8cpp.html',''); initResiza
|
||||
<dl class="section author"><dt>Author</dt><dd>Cory Alexander Balaton (coryab) </dd>
|
||||
<dd>
|
||||
Janita Ovidie Sandtrøen Willumsen (janitaws)</dd></dl>
|
||||
<dl class="section version"><dt>Version</dt><dd>0.1</dd></dl>
|
||||
<dl class="bug"><dt><b><a class="el" href="bug.html#_bug000007">Bug:</a></b></dt><dd>No known bugs</dd></dl>
|
||||
<dl class="todo"><dt><b><a class="el" href="todo.html#_todo000001">Todo:</a></b></dt><dd><p class="startdd">Implement constructor </p>
|
||||
<p class="interdd">Implement add_particle </p>
|
||||
<p class="interdd">Implement external_E_field </p>
|
||||
<p class="interdd">Implement external_B_field </p>
|
||||
<p class="interdd">Implement force_on_particle </p>
|
||||
<p class="interdd">Implement total_force_external </p>
|
||||
<p class="interdd">Implement total_force_particles </p>
|
||||
<p class="interdd">Implement total_force </p>
|
||||
<p class="interdd">Implement evolve_RK4 </p>
|
||||
<p class="enddd">Implement evolve_forward_euler </p>
|
||||
</dd></dl>
|
||||
<dl class="section version"><dt>Version</dt><dd>1.0</dd></dl>
|
||||
<dl class="bug"><dt><b><a class="el" href="bug.html#_bug000008">Bug:</a></b></dt><dd>No known bugs </dd></dl>
|
||||
|
||||
<p class="definition">Definition in file <a class="el" href="PenningTrap_8cpp_source.html">PenningTrap.cpp</a>.</p>
|
||||
</div></div><!-- contents -->
|
||||
|
||||
@@ -102,69 +102,361 @@ $(document).ready(function(){initNavTree('PenningTrap_8cpp_source.html',''); ini
|
||||
</div><!--header-->
|
||||
<div class="contents">
|
||||
<a href="PenningTrap_8cpp.html">Go to the documentation of this file.</a><div class="fragment"><div class="line"><a id="l00001" name="l00001"></a><span class="lineno"> 1</span> </div>
|
||||
<div class="line"><a id="l00024" name="l00024"></a><span class="lineno"> 24</span><span class="preprocessor">#include "<a class="code" href="PenningTrap_8hpp.html">PenningTrap.hpp</a>"</span></div>
|
||||
<div class="line"><a id="l00025" name="l00025"></a><span class="lineno"> 25</span> </div>
|
||||
<div class="line"><a id="l00026" name="l00026"></a><span class="lineno"><a class="line" href="classPenningTrap.html#a81add5063bd5f29d77f0b5c299c6c560"> 26</a></span><a class="code hl_function" href="classPenningTrap.html#a81add5063bd5f29d77f0b5c299c6c560">PenningTrap::PenningTrap</a>(<span class="keywordtype">double</span> B_0, <span class="keywordtype">double</span> V_0, <span class="keywordtype">double</span> d)</div>
|
||||
<div class="line"><a id="l00027" name="l00027"></a><span class="lineno"> 27</span>{</div>
|
||||
<div class="line"><a id="l00028" name="l00028"></a><span class="lineno"> 28</span> </div>
|
||||
<div class="line"><a id="l00029" name="l00029"></a><span class="lineno"> 29</span>}</div>
|
||||
<div class="line"><a id="l00030" name="l00030"></a><span class="lineno"> 30</span> </div>
|
||||
<div class="line"><a id="l00031" name="l00031"></a><span class="lineno"><a class="line" href="classPenningTrap.html#a6e9776ff5b149f01080800716455d7c8"> 31</a></span><span class="keywordtype">void</span> <a class="code hl_function" href="classPenningTrap.html#a6e9776ff5b149f01080800716455d7c8">PenningTrap::add_particle</a>(<a class="code hl_class" href="classParticle.html">Particle</a> particle)</div>
|
||||
<div class="line"><a id="l00032" name="l00032"></a><span class="lineno"> 32</span>{</div>
|
||||
<div class="line"><a id="l00033" name="l00033"></a><span class="lineno"> 33</span> </div>
|
||||
<div class="line"><a id="l00034" name="l00034"></a><span class="lineno"> 34</span>}</div>
|
||||
<div class="line"><a id="l00035" name="l00035"></a><span class="lineno"> 35</span> </div>
|
||||
<div class="line"><a id="l00036" name="l00036"></a><span class="lineno"><a class="line" href="classPenningTrap.html#a978a2e2026a4b5308d5184712f81704b"> 36</a></span>arma::vec <a class="code hl_function" href="classPenningTrap.html#a978a2e2026a4b5308d5184712f81704b">PenningTrap::external_E_field</a>(arma::vec r)</div>
|
||||
<div class="line"><a id="l00037" name="l00037"></a><span class="lineno"> 37</span>{</div>
|
||||
<div class="line"><a id="l00013" name="l00013"></a><span class="lineno"> 13</span><span class="preprocessor">#include "<a class="code" href="PenningTrap_8hpp.html">PenningTrap.hpp</a>"</span></div>
|
||||
<div class="line"><a id="l00014" name="l00014"></a><span class="lineno"> 14</span><span class="preprocessor">#include "<a class="code" href="typedefs_8hpp.html">typedefs.hpp</a>"</span></div>
|
||||
<div class="line"><a id="l00015" name="l00015"></a><span class="lineno"> 15</span><span class="preprocessor">#include <algorithm></span></div>
|
||||
<div class="line"><a id="l00016" name="l00016"></a><span class="lineno"> 16</span><span class="preprocessor">#include <functional></span></div>
|
||||
<div class="line"><a id="l00017" name="l00017"></a><span class="lineno"> 17</span><span class="preprocessor">#include <sys/types.h></span></div>
|
||||
<div class="line"><a id="l00018" name="l00018"></a><span class="lineno"> 18</span><span class="preprocessor">#include <vector></span></div>
|
||||
<div class="line"><a id="l00019" name="l00019"></a><span class="lineno"> 19</span> </div>
|
||||
<div class="line"><a id="l00020" name="l00020"></a><span class="lineno"><a class="line" href="classPenningTrap.html#a3c0a44e4e0a94366ff609e81fe463fa2"> 20</a></span><a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> <a class="code hl_function" href="classPenningTrap.html#a3c0a44e4e0a94366ff609e81fe463fa2">PenningTrap::v_func</a>(uint i, uint j, <span class="keywordtype">double</span> dt)</div>
|
||||
<div class="line"><a id="l00021" name="l00021"></a><span class="lineno"> 21</span>{</div>
|
||||
<div class="line"><a id="l00022" name="l00022"></a><span class="lineno"> 22</span> <span class="keywordflow">switch</span> (i) {</div>
|
||||
<div class="line"><a id="l00023" name="l00023"></a><span class="lineno"> 23</span> <span class="keywordflow">case</span> 0:</div>
|
||||
<div class="line"><a id="l00024" name="l00024"></a><span class="lineno"> 24</span> <span class="keywordflow">return</span> .5 * dt * this-><a class="code hl_variable" href="classPenningTrap.html#ae9b5afdaa5cd366e94bd294452a1eed4">k_v</a>[0][j];</div>
|
||||
<div class="line"><a id="l00025" name="l00025"></a><span class="lineno"> 25</span> <span class="keywordflow">case</span> 1:</div>
|
||||
<div class="line"><a id="l00026" name="l00026"></a><span class="lineno"> 26</span> <span class="keywordflow">return</span> .5 * dt * this->k_v[1][j];</div>
|
||||
<div class="line"><a id="l00027" name="l00027"></a><span class="lineno"> 27</span> <span class="keywordflow">case</span> 2:</div>
|
||||
<div class="line"><a id="l00028" name="l00028"></a><span class="lineno"> 28</span> <span class="keywordflow">return</span> dt * this->k_v[2][j];</div>
|
||||
<div class="line"><a id="l00029" name="l00029"></a><span class="lineno"> 29</span> <span class="keywordflow">case</span> 3:</div>
|
||||
<div class="line"><a id="l00030" name="l00030"></a><span class="lineno"> 30</span> <span class="keywordflow">return</span> <a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a>((dt / 6.)</div>
|
||||
<div class="line"><a id="l00031" name="l00031"></a><span class="lineno"> 31</span> * (this->k_v[0][j] + 2. * this->k_v[1][j]</div>
|
||||
<div class="line"><a id="l00032" name="l00032"></a><span class="lineno"> 32</span> + 2. * this->k_v[2][j] + this->k_v[3][j]));</div>
|
||||
<div class="line"><a id="l00033" name="l00033"></a><span class="lineno"> 33</span> <span class="keywordflow">default</span>:</div>
|
||||
<div class="line"><a id="l00034" name="l00034"></a><span class="lineno"> 34</span> std::cout << <span class="stringliteral">"Not valid!"</span> << std::endl;</div>
|
||||
<div class="line"><a id="l00035" name="l00035"></a><span class="lineno"> 35</span> abort();</div>
|
||||
<div class="line"><a id="l00036" name="l00036"></a><span class="lineno"> 36</span> }</div>
|
||||
<div class="line"><a id="l00037" name="l00037"></a><span class="lineno"> 37</span>}</div>
|
||||
<div class="line"><a id="l00038" name="l00038"></a><span class="lineno"> 38</span> </div>
|
||||
<div class="line"><a id="l00039" name="l00039"></a><span class="lineno"> 39</span>}</div>
|
||||
<div class="line"><a id="l00040" name="l00040"></a><span class="lineno"> 40</span> </div>
|
||||
<div class="line"><a id="l00041" name="l00041"></a><span class="lineno"><a class="line" href="classPenningTrap.html#a2a3e7f480ba52e9f24d4c50c3981a784"> 41</a></span>arma::vec <a class="code hl_function" href="classPenningTrap.html#a2a3e7f480ba52e9f24d4c50c3981a784">PenningTrap::external_B_field</a>(arma::vec r)</div>
|
||||
<div class="line"><a id="l00042" name="l00042"></a><span class="lineno"> 42</span>{</div>
|
||||
<div class="line"><a id="l00043" name="l00043"></a><span class="lineno"> 43</span> </div>
|
||||
<div class="line"><a id="l00044" name="l00044"></a><span class="lineno"> 44</span>}</div>
|
||||
<div class="line"><a id="l00045" name="l00045"></a><span class="lineno"> 45</span> </div>
|
||||
<div class="line"><a id="l00046" name="l00046"></a><span class="lineno"><a class="line" href="classPenningTrap.html#a4790f41e4fbc6ede4991aa7bbda92182"> 46</a></span>arma::vec <a class="code hl_function" href="classPenningTrap.html#a4790f41e4fbc6ede4991aa7bbda92182">PenningTrap::force_on_particle</a>(<span class="keywordtype">int</span> i, <span class="keywordtype">int</span> j)</div>
|
||||
<div class="line"><a id="l00047" name="l00047"></a><span class="lineno"> 47</span>{</div>
|
||||
<div class="line"><a id="l00048" name="l00048"></a><span class="lineno"> 48</span> </div>
|
||||
<div class="line"><a id="l00049" name="l00049"></a><span class="lineno"> 49</span>}</div>
|
||||
<div class="line"><a id="l00050" name="l00050"></a><span class="lineno"> 50</span> </div>
|
||||
<div class="line"><a id="l00051" name="l00051"></a><span class="lineno"><a class="line" href="classPenningTrap.html#a045adb85e97a8e0c38fb36d2fd74eeee"> 51</a></span>arma::vec <a class="code hl_function" href="classPenningTrap.html#a045adb85e97a8e0c38fb36d2fd74eeee">PenningTrap::total_force_external</a>(<span class="keywordtype">int</span> i)</div>
|
||||
<div class="line"><a id="l00052" name="l00052"></a><span class="lineno"> 52</span>{</div>
|
||||
<div class="line"><a id="l00053" name="l00053"></a><span class="lineno"> 53</span> </div>
|
||||
<div class="line"><a id="l00054" name="l00054"></a><span class="lineno"> 54</span>}</div>
|
||||
<div class="line"><a id="l00055" name="l00055"></a><span class="lineno"> 55</span> </div>
|
||||
<div class="line"><a id="l00056" name="l00056"></a><span class="lineno"><a class="line" href="classPenningTrap.html#a135db7d991d9b88b00fde4edee71f78d"> 56</a></span>arma::vec <a class="code hl_function" href="classPenningTrap.html#a135db7d991d9b88b00fde4edee71f78d">PenningTrap::total_force_particles</a>(<span class="keywordtype">int</span> i)</div>
|
||||
<div class="line"><a id="l00057" name="l00057"></a><span class="lineno"> 57</span>{</div>
|
||||
<div class="line"><a id="l00058" name="l00058"></a><span class="lineno"> 58</span> </div>
|
||||
<div class="line"><a id="l00059" name="l00059"></a><span class="lineno"> 59</span>}</div>
|
||||
<div class="line"><a id="l00060" name="l00060"></a><span class="lineno"> 60</span> </div>
|
||||
<div class="line"><a id="l00061" name="l00061"></a><span class="lineno"><a class="line" href="classPenningTrap.html#a83cc7a04dae009ed8e75453c38fdf8be"> 61</a></span>arma::vec <a class="code hl_function" href="classPenningTrap.html#a83cc7a04dae009ed8e75453c38fdf8be">PenningTrap::total_force</a>(<span class="keywordtype">int</span> i)</div>
|
||||
<div class="line"><a id="l00062" name="l00062"></a><span class="lineno"> 62</span>{</div>
|
||||
<div class="line"><a id="l00063" name="l00063"></a><span class="lineno"> 63</span> </div>
|
||||
<div class="line"><a id="l00039" name="l00039"></a><span class="lineno"><a class="line" href="classPenningTrap.html#a826b7fa8e709d481eb1dee7d0c2cdc08"> 39</a></span><a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> <a class="code hl_function" href="classPenningTrap.html#a826b7fa8e709d481eb1dee7d0c2cdc08">PenningTrap::r_func</a>(uint i, uint j, <span class="keywordtype">double</span> dt)</div>
|
||||
<div class="line"><a id="l00040" name="l00040"></a><span class="lineno"> 40</span>{</div>
|
||||
<div class="line"><a id="l00041" name="l00041"></a><span class="lineno"> 41</span> <span class="keywordflow">switch</span> (i) {</div>
|
||||
<div class="line"><a id="l00042" name="l00042"></a><span class="lineno"> 42</span> <span class="keywordflow">case</span> 0:</div>
|
||||
<div class="line"><a id="l00043" name="l00043"></a><span class="lineno"> 43</span> <span class="keywordflow">return</span> .5 * dt * this-><a class="code hl_variable" href="classPenningTrap.html#a2f168622587709b9e3c49077f0b9a640">k_r</a>[0][j];</div>
|
||||
<div class="line"><a id="l00044" name="l00044"></a><span class="lineno"> 44</span> <span class="keywordflow">case</span> 1:</div>
|
||||
<div class="line"><a id="l00045" name="l00045"></a><span class="lineno"> 45</span> <span class="keywordflow">return</span> .5 * dt * this->k_r[1][j];</div>
|
||||
<div class="line"><a id="l00046" name="l00046"></a><span class="lineno"> 46</span> <span class="keywordflow">case</span> 2:</div>
|
||||
<div class="line"><a id="l00047" name="l00047"></a><span class="lineno"> 47</span> <span class="keywordflow">return</span> dt * this->k_r[2][j];</div>
|
||||
<div class="line"><a id="l00048" name="l00048"></a><span class="lineno"> 48</span> <span class="keywordflow">case</span> 3:</div>
|
||||
<div class="line"><a id="l00049" name="l00049"></a><span class="lineno"> 49</span> <span class="keywordflow">return</span> <a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a>((dt / 6.)</div>
|
||||
<div class="line"><a id="l00050" name="l00050"></a><span class="lineno"> 50</span> * (this->k_r[0][j] + 2. * this->k_r[1][j]</div>
|
||||
<div class="line"><a id="l00051" name="l00051"></a><span class="lineno"> 51</span> + 2. * this->k_r[2][j] + this->k_r[3][j]));</div>
|
||||
<div class="line"><a id="l00052" name="l00052"></a><span class="lineno"> 52</span> <span class="keywordflow">default</span>:</div>
|
||||
<div class="line"><a id="l00053" name="l00053"></a><span class="lineno"> 53</span> std::cout << <span class="stringliteral">"Not valid!"</span> << std::endl;</div>
|
||||
<div class="line"><a id="l00054" name="l00054"></a><span class="lineno"> 54</span> abort();</div>
|
||||
<div class="line"><a id="l00055" name="l00055"></a><span class="lineno"> 55</span> }</div>
|
||||
<div class="line"><a id="l00056" name="l00056"></a><span class="lineno"> 56</span>}</div>
|
||||
<div class="line"><a id="l00057" name="l00057"></a><span class="lineno"> 57</span> </div>
|
||||
<div class="line"><a id="l00058" name="l00058"></a><span class="lineno"><a class="line" href="classPenningTrap.html#a5846c8f75cdc543fd9cf0b2185a3ef22"> 58</a></span><a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> <a class="code hl_function" href="classPenningTrap.html#a5846c8f75cdc543fd9cf0b2185a3ef22">PenningTrap::external_E_field</a>(<a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> r)</div>
|
||||
<div class="line"><a id="l00059" name="l00059"></a><span class="lineno"> 59</span>{</div>
|
||||
<div class="line"><a id="l00060" name="l00060"></a><span class="lineno"> 60</span> r(2) *= -2.;</div>
|
||||
<div class="line"><a id="l00061" name="l00061"></a><span class="lineno"> 61</span> </div>
|
||||
<div class="line"><a id="l00062" name="l00062"></a><span class="lineno"> 62</span> <span class="keywordflow">return</span> <a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a>((this-><a class="code hl_variable" href="classPenningTrap.html#a715329844d75ec4c04f8391421fb4e89">V_0</a> * this-><a class="code hl_variable" href="classPenningTrap.html#ae915f6ad0eef1fb46530e836b6e071e5">perturbation</a>(this-><a class="code hl_variable" href="classPenningTrap.html#a8ca4e21291f60fde619c14099d8c4e8e">t</a>) / (this-><a class="code hl_variable" href="classPenningTrap.html#a66dfe89c68716b9502927b97f59c27d2">d</a> * this-><a class="code hl_variable" href="classPenningTrap.html#a66dfe89c68716b9502927b97f59c27d2">d</a>))</div>
|
||||
<div class="line"><a id="l00063" name="l00063"></a><span class="lineno"> 63</span> * r);</div>
|
||||
<div class="line"><a id="l00064" name="l00064"></a><span class="lineno"> 64</span>}</div>
|
||||
<div class="line"><a id="l00065" name="l00065"></a><span class="lineno"> 65</span> </div>
|
||||
<div class="line"><a id="l00066" name="l00066"></a><span class="lineno"><a class="line" href="classPenningTrap.html#ab891b839c40eeb38d8a2a636c70090a9"> 66</a></span><span class="keywordtype">void</span> <a class="code hl_function" href="classPenningTrap.html#ab891b839c40eeb38d8a2a636c70090a9">PenningTrap::evolve_RK4</a>(<span class="keywordtype">double</span> dt)</div>
|
||||
<div class="line"><a id="l00066" name="l00066"></a><span class="lineno"><a class="line" href="classPenningTrap.html#a361f2c4862c90b5e8e2a2f50c6a95655"> 66</a></span><a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> <a class="code hl_function" href="classPenningTrap.html#a361f2c4862c90b5e8e2a2f50c6a95655">PenningTrap::external_B_field</a>(<a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> r)</div>
|
||||
<div class="line"><a id="l00067" name="l00067"></a><span class="lineno"> 67</span>{</div>
|
||||
<div class="line"><a id="l00068" name="l00068"></a><span class="lineno"> 68</span> </div>
|
||||
<div class="line"><a id="l00068" name="l00068"></a><span class="lineno"> 68</span> <span class="keywordflow">return</span> <a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a>{0., 0., this-><a class="code hl_variable" href="classPenningTrap.html#a0cac3509aa96e71a26d3b2c902e27716">B_0</a>};</div>
|
||||
<div class="line"><a id="l00069" name="l00069"></a><span class="lineno"> 69</span>}</div>
|
||||
<div class="line"><a id="l00070" name="l00070"></a><span class="lineno"> 70</span> </div>
|
||||
<div class="line"><a id="l00071" name="l00071"></a><span class="lineno"><a class="line" href="classPenningTrap.html#a56544b6f4befb42984e9650cf2a40965"> 71</a></span><span class="keywordtype">void</span> <a class="code hl_function" href="classPenningTrap.html#a56544b6f4befb42984e9650cf2a40965">PenningTrap::evolve_forward_euler</a>(<span class="keywordtype">double</span> dt)</div>
|
||||
<div class="line"><a id="l00071" name="l00071"></a><span class="lineno"><a class="line" href="classPenningTrap.html#a7f210bb2768a5d79ced4b0df0df97598"> 71</a></span><a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> <a class="code hl_function" href="classPenningTrap.html#a7f210bb2768a5d79ced4b0df0df97598">PenningTrap::force_on_particle</a>(uint i, uint j)</div>
|
||||
<div class="line"><a id="l00072" name="l00072"></a><span class="lineno"> 72</span>{</div>
|
||||
<div class="line"><a id="l00073" name="l00073"></a><span class="lineno"> 73</span> </div>
|
||||
<div class="line"><a id="l00074" name="l00074"></a><span class="lineno"> 74</span>}</div>
|
||||
<div class="line"><a id="l00073" name="l00073"></a><span class="lineno"> 73</span> <span class="comment">// Calculate the difference between the particles' position</span></div>
|
||||
<div class="line"><a id="l00074" name="l00074"></a><span class="lineno"> 74</span> <a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> res = this-><a class="code hl_variable" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">particles</a>[i].r_vec - this-><a class="code hl_variable" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">particles</a>[j].r_vec;</div>
|
||||
<div class="line"><a id="l00075" name="l00075"></a><span class="lineno"> 75</span> </div>
|
||||
<div class="line"><a id="l00076" name="l00076"></a><span class="lineno"> 76</span> <span class="comment">// Get the distance between the particles</span></div>
|
||||
<div class="line"><a id="l00077" name="l00077"></a><span class="lineno"> 77</span> <span class="keywordtype">double</span> norm = arma::norm(res, 2);</div>
|
||||
<div class="line"><a id="l00078" name="l00078"></a><span class="lineno"> 78</span> </div>
|
||||
<div class="line"><a id="l00079" name="l00079"></a><span class="lineno"> 79</span> <span class="keywordflow">return</span> <a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a>((this-><a class="code hl_variable" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">particles</a>[j].q / (norm * norm * norm)) * res);</div>
|
||||
<div class="line"><a id="l00080" name="l00080"></a><span class="lineno"> 80</span>}</div>
|
||||
<div class="line"><a id="l00081" name="l00081"></a><span class="lineno"> 81</span> </div>
|
||||
<div class="line"><a id="l00082" name="l00082"></a><span class="lineno"><a class="line" href="classPenningTrap.html#a2c01108b52c8e2a003cf9170da9e7682"> 82</a></span><a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> <a class="code hl_function" href="classPenningTrap.html#a2c01108b52c8e2a003cf9170da9e7682">PenningTrap::total_force_external</a>(uint i)</div>
|
||||
<div class="line"><a id="l00083" name="l00083"></a><span class="lineno"> 83</span>{</div>
|
||||
<div class="line"><a id="l00084" name="l00084"></a><span class="lineno"> 84</span> <a class="code hl_class" href="classParticle.html">Particle</a> *p = &this-><a class="code hl_variable" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">particles</a>[i];</div>
|
||||
<div class="line"><a id="l00085" name="l00085"></a><span class="lineno"> 85</span> </div>
|
||||
<div class="line"><a id="l00086" name="l00086"></a><span class="lineno"> 86</span> <span class="keywordflow">if</span> (arma::norm(p-><a class="code hl_variable" href="classParticle.html#a1c59101411db43624828b766f87ad460">r_vec</a>) > this->d) {</div>
|
||||
<div class="line"><a id="l00087" name="l00087"></a><span class="lineno"> 87</span> <span class="keywordflow">return</span> <a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a>{0., 0., 0.};</div>
|
||||
<div class="line"><a id="l00088" name="l00088"></a><span class="lineno"> 88</span> }</div>
|
||||
<div class="line"><a id="l00089" name="l00089"></a><span class="lineno"> 89</span> </div>
|
||||
<div class="line"><a id="l00090" name="l00090"></a><span class="lineno"> 90</span> <span class="keywordflow">return</span> <a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a>(p-><a class="code hl_variable" href="classParticle.html#a566dcc1de4bdc01251776948798ea8e1">q</a></div>
|
||||
<div class="line"><a id="l00091" name="l00091"></a><span class="lineno"> 91</span> * (this->external_E_field(p-><a class="code hl_variable" href="classParticle.html#a1c59101411db43624828b766f87ad460">r_vec</a>)</div>
|
||||
<div class="line"><a id="l00092" name="l00092"></a><span class="lineno"> 92</span> + arma::cross(p-><a class="code hl_variable" href="classParticle.html#a3a10400add8dd22b8031330c2aafb6fe">v_vec</a>, this->external_B_field(p-><a class="code hl_variable" href="classParticle.html#a1c59101411db43624828b766f87ad460">r_vec</a>))));</div>
|
||||
<div class="line"><a id="l00093" name="l00093"></a><span class="lineno"> 93</span>}</div>
|
||||
<div class="line"><a id="l00094" name="l00094"></a><span class="lineno"> 94</span> </div>
|
||||
<div class="line"><a id="l00095" name="l00095"></a><span class="lineno"><a class="line" href="classPenningTrap.html#a2fe1cefbae18fa5808155ee0d2df713c"> 95</a></span><a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> <a class="code hl_function" href="classPenningTrap.html#a2fe1cefbae18fa5808155ee0d2df713c">PenningTrap::total_force_particles</a>(uint i)</div>
|
||||
<div class="line"><a id="l00096" name="l00096"></a><span class="lineno"> 96</span>{</div>
|
||||
<div class="line"><a id="l00097" name="l00097"></a><span class="lineno"> 97</span> <a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> res;</div>
|
||||
<div class="line"><a id="l00098" name="l00098"></a><span class="lineno"> 98</span> </div>
|
||||
<div class="line"><a id="l00099" name="l00099"></a><span class="lineno"> 99</span> <span class="keywordflow">for</span> (<span class="keywordtype">size_t</span> j = 0; j < this-><a class="code hl_variable" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">particles</a>.size(); j++) {</div>
|
||||
<div class="line"><a id="l00100" name="l00100"></a><span class="lineno"> 100</span> <span class="keywordflow">if</span> (i != j)</div>
|
||||
<div class="line"><a id="l00101" name="l00101"></a><span class="lineno"> 101</span> res += this-><a class="code hl_function" href="classPenningTrap.html#a7f210bb2768a5d79ced4b0df0df97598">force_on_particle</a>(i, j);</div>
|
||||
<div class="line"><a id="l00102" name="l00102"></a><span class="lineno"> 102</span> }</div>
|
||||
<div class="line"><a id="l00103" name="l00103"></a><span class="lineno"> 103</span> </div>
|
||||
<div class="line"><a id="l00104" name="l00104"></a><span class="lineno"> 104</span> <span class="keywordflow">return</span> <a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a>(res * (<a class="code hl_define" href="constants_8hpp.html#a4e451456ad7e9276ed0afa42826e7ccb">K_E</a> * this-><a class="code hl_variable" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">particles</a>[i].q));</div>
|
||||
<div class="line"><a id="l00105" name="l00105"></a><span class="lineno"> 105</span>}</div>
|
||||
<div class="line"><a id="l00106" name="l00106"></a><span class="lineno"> 106</span> </div>
|
||||
<div class="line"><a id="l00107" name="l00107"></a><span class="lineno"><a class="line" href="classPenningTrap.html#a9a301b0540078c36697880ef204afdf3"> 107</a></span><a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> <a class="code hl_function" href="classPenningTrap.html#a9a301b0540078c36697880ef204afdf3">PenningTrap::total_force</a>(uint i)</div>
|
||||
<div class="line"><a id="l00108" name="l00108"></a><span class="lineno"> 108</span>{</div>
|
||||
<div class="line"><a id="l00109" name="l00109"></a><span class="lineno"> 109</span> <span class="keywordflow">if</span> (arma::norm(this-><a class="code hl_variable" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">particles</a>[i].r_vec) > this-><a class="code hl_variable" href="classPenningTrap.html#a66dfe89c68716b9502927b97f59c27d2">d</a>) {</div>
|
||||
<div class="line"><a id="l00110" name="l00110"></a><span class="lineno"> 110</span> <span class="keywordflow">return</span> <a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a>{0., 0., 0.};</div>
|
||||
<div class="line"><a id="l00111" name="l00111"></a><span class="lineno"> 111</span> }</div>
|
||||
<div class="line"><a id="l00112" name="l00112"></a><span class="lineno"> 112</span> <span class="keywordflow">return</span> <a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a>(this-><a class="code hl_function" href="classPenningTrap.html#a2c01108b52c8e2a003cf9170da9e7682">total_force_external</a>(i) - this-><a class="code hl_function" href="classPenningTrap.html#a2fe1cefbae18fa5808155ee0d2df713c">total_force_particles</a>(i));</div>
|
||||
<div class="line"><a id="l00113" name="l00113"></a><span class="lineno"> 113</span>}</div>
|
||||
<div class="line"><a id="l00114" name="l00114"></a><span class="lineno"> 114</span> </div>
|
||||
<div class="line"><a id="l00115" name="l00115"></a><span class="lineno"><a class="line" href="classPenningTrap.html#a5b6c6d4636f3a6e279ccde59d4a345e8"> 115</a></span><a class="code hl_function" href="classPenningTrap.html#a5b6c6d4636f3a6e279ccde59d4a345e8">PenningTrap::PenningTrap</a>(<span class="keywordtype">double</span> B_0, <span class="keywordtype">double</span> V_0, <span class="keywordtype">double</span> d, <span class="keywordtype">double</span> t)</div>
|
||||
<div class="line"><a id="l00116" name="l00116"></a><span class="lineno"> 116</span>{</div>
|
||||
<div class="line"><a id="l00117" name="l00117"></a><span class="lineno"> 117</span> this->B_0 = <a class="code hl_variable" href="classPenningTrap.html#a0cac3509aa96e71a26d3b2c902e27716">B_0</a>;</div>
|
||||
<div class="line"><a id="l00118" name="l00118"></a><span class="lineno"> 118</span> this->V_0 = <a class="code hl_variable" href="classPenningTrap.html#a715329844d75ec4c04f8391421fb4e89">V_0</a>;</div>
|
||||
<div class="line"><a id="l00119" name="l00119"></a><span class="lineno"> 119</span> this->d = <a class="code hl_variable" href="classPenningTrap.html#a66dfe89c68716b9502927b97f59c27d2">d</a>;</div>
|
||||
<div class="line"><a id="l00120" name="l00120"></a><span class="lineno"> 120</span> this->t = <a class="code hl_variable" href="classPenningTrap.html#a8ca4e21291f60fde619c14099d8c4e8e">t</a>;</div>
|
||||
<div class="line"><a id="l00121" name="l00121"></a><span class="lineno"> 121</span> this-><a class="code hl_variable" href="classPenningTrap.html#ae915f6ad0eef1fb46530e836b6e071e5">perturbation</a> = [](<span class="keywordtype">double</span> <a class="code hl_variable" href="classPenningTrap.html#a8ca4e21291f60fde619c14099d8c4e8e">t</a>) { <span class="keywordflow">return</span> 1.; };</div>
|
||||
<div class="line"><a id="l00122" name="l00122"></a><span class="lineno"> 122</span>}</div>
|
||||
<div class="line"><a id="l00123" name="l00123"></a><span class="lineno"> 123</span> </div>
|
||||
<div class="line"><a id="l00124" name="l00124"></a><span class="lineno"><a class="line" href="classPenningTrap.html#a830be1b8cbf59664e060b6edbeaa302f"> 124</a></span><a class="code hl_function" href="classPenningTrap.html#a5b6c6d4636f3a6e279ccde59d4a345e8">PenningTrap::PenningTrap</a>(uint i, <span class="keywordtype">double</span> B_0, <span class="keywordtype">double</span> V_0, <span class="keywordtype">double</span> d, <span class="keywordtype">double</span> t)</div>
|
||||
<div class="line"><a id="l00125" name="l00125"></a><span class="lineno"> 125</span> : <a class="code hl_class" href="classPenningTrap.html">PenningTrap</a>::<a class="code hl_class" href="classPenningTrap.html">PenningTrap</a>(B_0, V_0, d)</div>
|
||||
<div class="line"><a id="l00126" name="l00126"></a><span class="lineno"> 126</span>{</div>
|
||||
<div class="line"><a id="l00127" name="l00127"></a><span class="lineno"> 127</span> <span class="keywordflow">for</span> (<span class="keywordtype">size_t</span> j = 0; j < i; j++) {</div>
|
||||
<div class="line"><a id="l00128" name="l00128"></a><span class="lineno"> 128</span> this-><a class="code hl_variable" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">particles</a>.push_back(</div>
|
||||
<div class="line"><a id="l00129" name="l00129"></a><span class="lineno"> 129</span> <a class="code hl_class" href="classParticle.html">Particle</a>(<a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a>(<a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a>().randn() * .1 * this->d),</div>
|
||||
<div class="line"><a id="l00130" name="l00130"></a><span class="lineno"> 130</span> <a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a>(<a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a>().randn() * .1 * this->d)));</div>
|
||||
<div class="line"><a id="l00131" name="l00131"></a><span class="lineno"> 131</span> }</div>
|
||||
<div class="line"><a id="l00132" name="l00132"></a><span class="lineno"> 132</span>}</div>
|
||||
<div class="line"><a id="l00133" name="l00133"></a><span class="lineno"> 133</span> </div>
|
||||
<div class="line"><a id="l00134" name="l00134"></a><span class="lineno"><a class="line" href="classPenningTrap.html#addc96789dcfec07b75156e19fee82f4f"> 134</a></span><a class="code hl_function" href="classPenningTrap.html#a5b6c6d4636f3a6e279ccde59d4a345e8">PenningTrap::PenningTrap</a>(std::vector<Particle> particles, <span class="keywordtype">double</span> B_0,</div>
|
||||
<div class="line"><a id="l00135" name="l00135"></a><span class="lineno"> 135</span> <span class="keywordtype">double</span> V_0, <span class="keywordtype">double</span> d, <span class="keywordtype">double</span> t)</div>
|
||||
<div class="line"><a id="l00136" name="l00136"></a><span class="lineno"> 136</span> : <a class="code hl_class" href="classPenningTrap.html">PenningTrap</a>::<a class="code hl_class" href="classPenningTrap.html">PenningTrap</a>(B_0, V_0, d)</div>
|
||||
<div class="line"><a id="l00137" name="l00137"></a><span class="lineno"> 137</span>{</div>
|
||||
<div class="line"><a id="l00138" name="l00138"></a><span class="lineno"> 138</span> this->particles = <a class="code hl_variable" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">particles</a>;</div>
|
||||
<div class="line"><a id="l00139" name="l00139"></a><span class="lineno"> 139</span>}</div>
|
||||
<div class="line"><a id="l00140" name="l00140"></a><span class="lineno"> 140</span> </div>
|
||||
<div class="line"><a id="l00141" name="l00141"></a><span class="lineno"><a class="line" href="classPenningTrap.html#a9d1d8e90ca839b928aee1ad0cd4aff43"> 141</a></span><span class="keywordtype">void</span> <a class="code hl_function" href="classPenningTrap.html#a9d1d8e90ca839b928aee1ad0cd4aff43">PenningTrap::set_pertubation</a>(<span class="keywordtype">double</span> f, <span class="keywordtype">double</span> omega_V)</div>
|
||||
<div class="line"><a id="l00142" name="l00142"></a><span class="lineno"> 142</span>{</div>
|
||||
<div class="line"><a id="l00143" name="l00143"></a><span class="lineno"> 143</span> this-><a class="code hl_variable" href="classPenningTrap.html#ae915f6ad0eef1fb46530e836b6e071e5">perturbation</a> = [f, omega_V](<span class="keywordtype">double</span> <a class="code hl_variable" href="classPenningTrap.html#a8ca4e21291f60fde619c14099d8c4e8e">t</a>) {</div>
|
||||
<div class="line"><a id="l00144" name="l00144"></a><span class="lineno"> 144</span> <span class="keywordflow">return</span> 1 + f * std::cos(omega_V * <a class="code hl_variable" href="classPenningTrap.html#a8ca4e21291f60fde619c14099d8c4e8e">t</a>);</div>
|
||||
<div class="line"><a id="l00145" name="l00145"></a><span class="lineno"> 145</span> };</div>
|
||||
<div class="line"><a id="l00146" name="l00146"></a><span class="lineno"> 146</span>}</div>
|
||||
<div class="line"><a id="l00147" name="l00147"></a><span class="lineno"> 147</span> </div>
|
||||
<div class="line"><a id="l00148" name="l00148"></a><span class="lineno"><a class="line" href="classPenningTrap.html#aaee129f177657455348d0c8ae1441dea"> 148</a></span><span class="keywordtype">void</span> <a class="code hl_function" href="classPenningTrap.html#aaee129f177657455348d0c8ae1441dea">PenningTrap::reinitialize</a>(<span class="keywordtype">double</span> f, <span class="keywordtype">double</span> omega_V, <span class="keywordtype">double</span> t)</div>
|
||||
<div class="line"><a id="l00149" name="l00149"></a><span class="lineno"> 149</span>{</div>
|
||||
<div class="line"><a id="l00150" name="l00150"></a><span class="lineno"> 150</span> this->t = <a class="code hl_variable" href="classPenningTrap.html#a8ca4e21291f60fde619c14099d8c4e8e">t</a>;</div>
|
||||
<div class="line"><a id="l00151" name="l00151"></a><span class="lineno"> 151</span> this-><a class="code hl_function" href="classPenningTrap.html#a9d1d8e90ca839b928aee1ad0cd4aff43">set_pertubation</a>(f, omega_V);</div>
|
||||
<div class="line"><a id="l00152" name="l00152"></a><span class="lineno"> 152</span> </div>
|
||||
<div class="line"><a id="l00153" name="l00153"></a><span class="lineno"> 153</span> <span class="keywordflow">for</span> (<span class="keywordtype">size_t</span> i = 0; i < this-><a class="code hl_variable" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">particles</a>.size(); i++) {</div>
|
||||
<div class="line"><a id="l00154" name="l00154"></a><span class="lineno"> 154</span> this-><a class="code hl_variable" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">particles</a>[i].r_vec = <a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a>().randn() * .1 * this-><a class="code hl_variable" href="classPenningTrap.html#a66dfe89c68716b9502927b97f59c27d2">d</a>;</div>
|
||||
<div class="line"><a id="l00155" name="l00155"></a><span class="lineno"> 155</span> }</div>
|
||||
<div class="line"><a id="l00156" name="l00156"></a><span class="lineno"> 156</span>}</div>
|
||||
<div class="line"><a id="l00157" name="l00157"></a><span class="lineno"> 157</span> </div>
|
||||
<div class="line"><a id="l00158" name="l00158"></a><span class="lineno"><a class="line" href="classPenningTrap.html#a6e9776ff5b149f01080800716455d7c8"> 158</a></span><span class="keywordtype">void</span> <a class="code hl_function" href="classPenningTrap.html#a6e9776ff5b149f01080800716455d7c8">PenningTrap::add_particle</a>(<a class="code hl_class" href="classParticle.html">Particle</a> particle)</div>
|
||||
<div class="line"><a id="l00159" name="l00159"></a><span class="lineno"> 159</span>{</div>
|
||||
<div class="line"><a id="l00160" name="l00160"></a><span class="lineno"> 160</span> this-><a class="code hl_variable" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">particles</a>.push_back(particle);</div>
|
||||
<div class="line"><a id="l00161" name="l00161"></a><span class="lineno"> 161</span>}</div>
|
||||
<div class="line"><a id="l00162" name="l00162"></a><span class="lineno"> 162</span> </div>
|
||||
<div class="line"><a id="l00163" name="l00163"></a><span class="lineno"><a class="line" href="classPenningTrap.html#a36946152fd951b1f7c346c51ff900d8e"> 163</a></span><span class="keywordtype">void</span> <a class="code hl_function" href="classPenningTrap.html#a36946152fd951b1f7c346c51ff900d8e">PenningTrap::evolve_RK4</a>(<span class="keywordtype">double</span> dt, <span class="keywordtype">bool</span> particle_interaction)</div>
|
||||
<div class="line"><a id="l00164" name="l00164"></a><span class="lineno"> 164</span>{</div>
|
||||
<div class="line"><a id="l00165" name="l00165"></a><span class="lineno"> 165</span> </div>
|
||||
<div class="line"><a id="l00166" name="l00166"></a><span class="lineno"> 166</span> std::vector<Particle> original_particles = this-><a class="code hl_variable" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">particles</a>;</div>
|
||||
<div class="line"><a id="l00167" name="l00167"></a><span class="lineno"> 167</span> std::vector<Particle> tmp_particles = this-><a class="code hl_variable" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">particles</a>;</div>
|
||||
<div class="line"><a id="l00168" name="l00168"></a><span class="lineno"> 168</span> </div>
|
||||
<div class="line"><a id="l00169" name="l00169"></a><span class="lineno"> 169</span> <a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> (<a class="code hl_class" href="classPenningTrap.html">PenningTrap</a>::*force)(uint) = particle_interaction</div>
|
||||
<div class="line"><a id="l00170" name="l00170"></a><span class="lineno"> 170</span> ? &<a class="code hl_function" href="classPenningTrap.html#a9a301b0540078c36697880ef204afdf3">PenningTrap::total_force</a></div>
|
||||
<div class="line"><a id="l00171" name="l00171"></a><span class="lineno"> 171</span> : &<a class="code hl_function" href="classPenningTrap.html#a2c01108b52c8e2a003cf9170da9e7682">PenningTrap::total_force_external</a>;</div>
|
||||
<div class="line"><a id="l00172" name="l00172"></a><span class="lineno"> 172</span> </div>
|
||||
<div class="line"><a id="l00173" name="l00173"></a><span class="lineno"> 173</span> <span class="keywordtype">size_t</span> size = this-><a class="code hl_variable" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">particles</a>.size();</div>
|
||||
<div class="line"><a id="l00174" name="l00174"></a><span class="lineno"> 174</span> </div>
|
||||
<div class="line"><a id="l00175" name="l00175"></a><span class="lineno"> 175</span> <span class="comment">// Allocating takes a long time, so reuse sim_arr if possible</span></div>
|
||||
<div class="line"><a id="l00176" name="l00176"></a><span class="lineno"> 176</span> <span class="keywordflow">if</span> (this-><a class="code hl_variable" href="classPenningTrap.html#ae9b5afdaa5cd366e94bd294452a1eed4">k_v</a>.size() != 4 || this-><a class="code hl_variable" href="classPenningTrap.html#a2f168622587709b9e3c49077f0b9a640">k_r</a>.size() != 4</div>
|
||||
<div class="line"><a id="l00177" name="l00177"></a><span class="lineno"> 177</span> || this-><a class="code hl_variable" href="classPenningTrap.html#ae9b5afdaa5cd366e94bd294452a1eed4">k_v</a>[0].size() != size || this-><a class="code hl_variable" href="classPenningTrap.html#a2f168622587709b9e3c49077f0b9a640">k_r</a>[0].size() != size) {</div>
|
||||
<div class="line"><a id="l00178" name="l00178"></a><span class="lineno"> 178</span> this-><a class="code hl_variable" href="classPenningTrap.html#ae9b5afdaa5cd366e94bd294452a1eed4">k_v</a> = <a class="code hl_typedef" href="typedefs_8hpp.html#aec69d34220fff45de238b9e01f2686af">sim_arr</a>(4, <a class="code hl_typedef" href="typedefs_8hpp.html#a46482a2697556c00556c9d73f461784f">sim_cols</a>(size));</div>
|
||||
<div class="line"><a id="l00179" name="l00179"></a><span class="lineno"> 179</span> this-><a class="code hl_variable" href="classPenningTrap.html#a2f168622587709b9e3c49077f0b9a640">k_r</a> = <a class="code hl_typedef" href="typedefs_8hpp.html#aec69d34220fff45de238b9e01f2686af">sim_arr</a>(4, <a class="code hl_typedef" href="typedefs_8hpp.html#a46482a2697556c00556c9d73f461784f">sim_cols</a>(size));</div>
|
||||
<div class="line"><a id="l00180" name="l00180"></a><span class="lineno"> 180</span> }</div>
|
||||
<div class="line"><a id="l00181" name="l00181"></a><span class="lineno"> 181</span> </div>
|
||||
<div class="line"><a id="l00182" name="l00182"></a><span class="lineno"> 182</span> <span class="comment">// Each k_{i+1} is dependent on k_i, so outer loop is not parallelizable</span></div>
|
||||
<div class="line"><a id="l00183" name="l00183"></a><span class="lineno"> 183</span> <span class="keywordflow">for</span> (<span class="keywordtype">size_t</span> i = 0; i < 4; i++) {</div>
|
||||
<div class="line"><a id="l00184" name="l00184"></a><span class="lineno"> 184</span> <span class="comment">// Inner loop is able to be parallelized</span></div>
|
||||
<div class="line"><a id="l00185" name="l00185"></a><span class="lineno"> 185</span><span class="preprocessor">#pragma omp parallel for</span></div>
|
||||
<div class="line"><a id="l00186" name="l00186"></a><span class="lineno"> 186</span> <span class="keywordflow">for</span> (<span class="keywordtype">size_t</span> j = 0; j < size; j++) {</div>
|
||||
<div class="line"><a id="l00187" name="l00187"></a><span class="lineno"> 187</span> this-><a class="code hl_variable" href="classPenningTrap.html#ae9b5afdaa5cd366e94bd294452a1eed4">k_v</a>[i][j] = (this->*force)(j) / this-><a class="code hl_variable" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">particles</a>[j].m;</div>
|
||||
<div class="line"><a id="l00188" name="l00188"></a><span class="lineno"> 188</span> this-><a class="code hl_variable" href="classPenningTrap.html#a2f168622587709b9e3c49077f0b9a640">k_r</a>[i][j] = this-><a class="code hl_variable" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">particles</a>[j].v_vec;</div>
|
||||
<div class="line"><a id="l00189" name="l00189"></a><span class="lineno"> 189</span> </div>
|
||||
<div class="line"><a id="l00190" name="l00190"></a><span class="lineno"> 190</span> tmp_particles[j].v_vec =</div>
|
||||
<div class="line"><a id="l00191" name="l00191"></a><span class="lineno"> 191</span> original_particles[j].v_vec + this-><a class="code hl_function" href="classPenningTrap.html#a3c0a44e4e0a94366ff609e81fe463fa2">v_func</a>(i, j, dt);</div>
|
||||
<div class="line"><a id="l00192" name="l00192"></a><span class="lineno"> 192</span> tmp_particles[j].r_vec =</div>
|
||||
<div class="line"><a id="l00193" name="l00193"></a><span class="lineno"> 193</span> original_particles[j].r_vec + this-><a class="code hl_function" href="classPenningTrap.html#a826b7fa8e709d481eb1dee7d0c2cdc08">r_func</a>(i, j, dt);</div>
|
||||
<div class="line"><a id="l00194" name="l00194"></a><span class="lineno"> 194</span> }</div>
|
||||
<div class="line"><a id="l00195" name="l00195"></a><span class="lineno"> 195</span> this-><a class="code hl_variable" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">particles</a> = tmp_particles;</div>
|
||||
<div class="line"><a id="l00196" name="l00196"></a><span class="lineno"> 196</span> }</div>
|
||||
<div class="line"><a id="l00197" name="l00197"></a><span class="lineno"> 197</span> </div>
|
||||
<div class="line"><a id="l00198" name="l00198"></a><span class="lineno"> 198</span> this-><a class="code hl_variable" href="classPenningTrap.html#a8ca4e21291f60fde619c14099d8c4e8e">t</a> += dt;</div>
|
||||
<div class="line"><a id="l00199" name="l00199"></a><span class="lineno"> 199</span>}</div>
|
||||
<div class="line"><a id="l00200" name="l00200"></a><span class="lineno"> 200</span> </div>
|
||||
<div class="line"><a id="l00201" name="l00201"></a><span class="lineno"><a class="line" href="classPenningTrap.html#ab9ea97a406534bbe621a95215144875e"> 201</a></span><span class="keywordtype">void</span> <a class="code hl_function" href="classPenningTrap.html#ab9ea97a406534bbe621a95215144875e">PenningTrap::evolve_forward_euler</a>(<span class="keywordtype">double</span> dt, <span class="keywordtype">bool</span> particle_interaction)</div>
|
||||
<div class="line"><a id="l00202" name="l00202"></a><span class="lineno"> 202</span>{</div>
|
||||
<div class="line"><a id="l00203" name="l00203"></a><span class="lineno"> 203</span> <span class="keywordtype">size_t</span> size = this-><a class="code hl_variable" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">particles</a>.size();</div>
|
||||
<div class="line"><a id="l00204" name="l00204"></a><span class="lineno"> 204</span> <a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> force_res[size];</div>
|
||||
<div class="line"><a id="l00205" name="l00205"></a><span class="lineno"> 205</span> </div>
|
||||
<div class="line"><a id="l00206" name="l00206"></a><span class="lineno"> 206</span> <a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> (<a class="code hl_class" href="classPenningTrap.html">PenningTrap</a>::*force)(uint) = particle_interaction</div>
|
||||
<div class="line"><a id="l00207" name="l00207"></a><span class="lineno"> 207</span> ? &<a class="code hl_function" href="classPenningTrap.html#a9a301b0540078c36697880ef204afdf3">PenningTrap::total_force</a></div>
|
||||
<div class="line"><a id="l00208" name="l00208"></a><span class="lineno"> 208</span> : &<a class="code hl_function" href="classPenningTrap.html#a2c01108b52c8e2a003cf9170da9e7682">PenningTrap::total_force_external</a>;</div>
|
||||
<div class="line"><a id="l00209" name="l00209"></a><span class="lineno"> 209</span> </div>
|
||||
<div class="line"><a id="l00210" name="l00210"></a><span class="lineno"> 210</span> <span class="comment">// Calculating the force for each particle is independent and therefore</span></div>
|
||||
<div class="line"><a id="l00211" name="l00211"></a><span class="lineno"> 211</span> <span class="comment">// a good candidate for parallel execution</span></div>
|
||||
<div class="line"><a id="l00212" name="l00212"></a><span class="lineno"> 212</span><span class="preprocessor">#pragma omp parallel for</span></div>
|
||||
<div class="line"><a id="l00213" name="l00213"></a><span class="lineno"> 213</span> <span class="keywordflow">for</span> (<span class="keywordtype">size_t</span> i = 0; i < size; i++) {</div>
|
||||
<div class="line"><a id="l00214" name="l00214"></a><span class="lineno"> 214</span> force_res[i] = (this->*force)(i);</div>
|
||||
<div class="line"><a id="l00215" name="l00215"></a><span class="lineno"> 215</span> }</div>
|
||||
<div class="line"><a id="l00216" name="l00216"></a><span class="lineno"> 216</span> </div>
|
||||
<div class="line"><a id="l00217" name="l00217"></a><span class="lineno"> 217</span> <span class="comment">// Updating the particles is also independent, so we can parallelize</span></div>
|
||||
<div class="line"><a id="l00218" name="l00218"></a><span class="lineno"> 218</span> <span class="comment">// this as well</span></div>
|
||||
<div class="line"><a id="l00219" name="l00219"></a><span class="lineno"> 219</span><span class="preprocessor">#pragma omp parallel for</span></div>
|
||||
<div class="line"><a id="l00220" name="l00220"></a><span class="lineno"> 220</span> <span class="keywordflow">for</span> (<span class="keywordtype">size_t</span> i = 0; i < size; i++) {</div>
|
||||
<div class="line"><a id="l00221" name="l00221"></a><span class="lineno"> 221</span> this-><a class="code hl_variable" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">particles</a>[i].r_vec += dt * this-><a class="code hl_variable" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">particles</a>[i].v_vec;</div>
|
||||
<div class="line"><a id="l00222" name="l00222"></a><span class="lineno"> 222</span> this-><a class="code hl_variable" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">particles</a>[i].v_vec += dt * force_res[i] / this-><a class="code hl_variable" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">particles</a>[i].m;</div>
|
||||
<div class="line"><a id="l00223" name="l00223"></a><span class="lineno"> 223</span> }</div>
|
||||
<div class="line"><a id="l00224" name="l00224"></a><span class="lineno"> 224</span> </div>
|
||||
<div class="line"><a id="l00225" name="l00225"></a><span class="lineno"> 225</span> this-><a class="code hl_variable" href="classPenningTrap.html#a8ca4e21291f60fde619c14099d8c4e8e">t</a> += dt;</div>
|
||||
<div class="line"><a id="l00226" name="l00226"></a><span class="lineno"> 226</span>}</div>
|
||||
<div class="line"><a id="l00227" name="l00227"></a><span class="lineno"> 227</span> </div>
|
||||
<div class="line"><a id="l00228" name="l00228"></a><span class="lineno"><a class="line" href="classPenningTrap.html#a7a1d9f0528a12308de25bc30718da20a"> 228</a></span><a class="code hl_struct" href="structsimulation.html">simulation_t</a> <a class="code hl_function" href="classPenningTrap.html#a7a1d9f0528a12308de25bc30718da20a">PenningTrap::simulate</a>(<span class="keywordtype">double</span> time, uint steps, std::string method,</div>
|
||||
<div class="line"><a id="l00229" name="l00229"></a><span class="lineno"> 229</span> <span class="keywordtype">bool</span> particle_interaction)</div>
|
||||
<div class="line"><a id="l00230" name="l00230"></a><span class="lineno"> 230</span>{</div>
|
||||
<div class="line"><a id="l00231" name="l00231"></a><span class="lineno"> 231</span> <span class="keywordtype">double</span> dt = time / (double)steps;</div>
|
||||
<div class="line"><a id="l00232" name="l00232"></a><span class="lineno"> 232</span> </div>
|
||||
<div class="line"><a id="l00233" name="l00233"></a><span class="lineno"> 233</span> uint size = this-><a class="code hl_variable" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">particles</a>.size();</div>
|
||||
<div class="line"><a id="l00234" name="l00234"></a><span class="lineno"> 234</span> </div>
|
||||
<div class="line"><a id="l00235" name="l00235"></a><span class="lineno"> 235</span> <a class="code hl_struct" href="structsimulation.html">simulation_t</a> res{<a class="code hl_typedef" href="typedefs_8hpp.html#aec69d34220fff45de238b9e01f2686af">sim_arr</a>(size, <a class="code hl_typedef" href="typedefs_8hpp.html#a46482a2697556c00556c9d73f461784f">sim_cols</a>(steps)),</div>
|
||||
<div class="line"><a id="l00236" name="l00236"></a><span class="lineno"> 236</span> <a class="code hl_typedef" href="typedefs_8hpp.html#aec69d34220fff45de238b9e01f2686af">sim_arr</a>(size, <a class="code hl_typedef" href="typedefs_8hpp.html#a46482a2697556c00556c9d73f461784f">sim_cols</a>(steps))};</div>
|
||||
<div class="line"><a id="l00237" name="l00237"></a><span class="lineno"> 237</span> </div>
|
||||
<div class="line"><a id="l00238" name="l00238"></a><span class="lineno"> 238</span> void (<a class="code hl_class" href="classPenningTrap.html">PenningTrap</a>::*func)(double, bool);</div>
|
||||
<div class="line"><a id="l00239" name="l00239"></a><span class="lineno"> 239</span> <span class="keywordflow">if</span> (method == <span class="stringliteral">"rk4"</span>) {</div>
|
||||
<div class="line"><a id="l00240" name="l00240"></a><span class="lineno"> 240</span> func = &<a class="code hl_function" href="classPenningTrap.html#a36946152fd951b1f7c346c51ff900d8e">PenningTrap::evolve_RK4</a>;</div>
|
||||
<div class="line"><a id="l00241" name="l00241"></a><span class="lineno"> 241</span> } <span class="keywordflow">else</span> <span class="keywordflow">if</span> (method == <span class="stringliteral">"euler"</span>) {</div>
|
||||
<div class="line"><a id="l00242" name="l00242"></a><span class="lineno"> 242</span> func = &<a class="code hl_function" href="classPenningTrap.html#ab9ea97a406534bbe621a95215144875e">PenningTrap::evolve_forward_euler</a>;</div>
|
||||
<div class="line"><a id="l00243" name="l00243"></a><span class="lineno"> 243</span> } <span class="keywordflow">else</span> {</div>
|
||||
<div class="line"><a id="l00244" name="l00244"></a><span class="lineno"> 244</span> std::cout << <span class="stringliteral">"Not a valid method!"</span> << std::endl;</div>
|
||||
<div class="line"><a id="l00245" name="l00245"></a><span class="lineno"> 245</span> abort();</div>
|
||||
<div class="line"><a id="l00246" name="l00246"></a><span class="lineno"> 246</span> }</div>
|
||||
<div class="line"><a id="l00247" name="l00247"></a><span class="lineno"> 247</span> </div>
|
||||
<div class="line"><a id="l00248" name="l00248"></a><span class="lineno"> 248</span> <span class="keywordflow">for</span> (<span class="keywordtype">size_t</span> j = 0; j < steps; j++) {</div>
|
||||
<div class="line"><a id="l00249" name="l00249"></a><span class="lineno"> 249</span> <span class="keywordflow">for</span> (<span class="keywordtype">size_t</span> i = 0; i < size; i++) {</div>
|
||||
<div class="line"><a id="l00250" name="l00250"></a><span class="lineno"> 250</span> res.r_vecs[i][j] = this-><a class="code hl_variable" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">particles</a>[i].r_vec;</div>
|
||||
<div class="line"><a id="l00251" name="l00251"></a><span class="lineno"> 251</span> res.v_vecs[i][j] = this-><a class="code hl_variable" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">particles</a>[i].v_vec;</div>
|
||||
<div class="line"><a id="l00252" name="l00252"></a><span class="lineno"> 252</span> }</div>
|
||||
<div class="line"><a id="l00253" name="l00253"></a><span class="lineno"> 253</span> (this->*func)(dt, particle_interaction);</div>
|
||||
<div class="line"><a id="l00254" name="l00254"></a><span class="lineno"> 254</span> }</div>
|
||||
<div class="line"><a id="l00255" name="l00255"></a><span class="lineno"> 255</span> </div>
|
||||
<div class="line"><a id="l00256" name="l00256"></a><span class="lineno"> 256</span> <span class="keywordflow">return</span> res;</div>
|
||||
<div class="line"><a id="l00257" name="l00257"></a><span class="lineno"> 257</span>}</div>
|
||||
<div class="line"><a id="l00258" name="l00258"></a><span class="lineno"> 258</span> </div>
|
||||
<div class="line"><a id="l00259" name="l00259"></a><span class="lineno"><a class="line" href="classPenningTrap.html#ad8bc4df7ab3eed53b16cfdff38e7760b"> 259</a></span><span class="keywordtype">void</span> <a class="code hl_function" href="classPenningTrap.html#ad8bc4df7ab3eed53b16cfdff38e7760b">PenningTrap::write_simulation_to_dir</a>(std::string path, <span class="keywordtype">double</span> time,</div>
|
||||
<div class="line"><a id="l00260" name="l00260"></a><span class="lineno"> 260</span> uint steps, std::string method,</div>
|
||||
<div class="line"><a id="l00261" name="l00261"></a><span class="lineno"> 261</span> <span class="keywordtype">bool</span> particle_interaction)</div>
|
||||
<div class="line"><a id="l00262" name="l00262"></a><span class="lineno"> 262</span>{</div>
|
||||
<div class="line"><a id="l00263" name="l00263"></a><span class="lineno"> 263</span> <span class="keywordflow">if</span> (path.back() != <span class="charliteral">'/'</span>) {</div>
|
||||
<div class="line"><a id="l00264" name="l00264"></a><span class="lineno"> 264</span> path += <span class="charliteral">'/'</span>;</div>
|
||||
<div class="line"><a id="l00265" name="l00265"></a><span class="lineno"> 265</span> }</div>
|
||||
<div class="line"><a id="l00266" name="l00266"></a><span class="lineno"> 266</span> <span class="keywordflow">if</span> (<a class="code hl_function" href="utils_8hpp.html#a6fdd7217b750aff5b6295ece7cbdeffa">mkpath</a>(path, 0777) != 0) {</div>
|
||||
<div class="line"><a id="l00267" name="l00267"></a><span class="lineno"> 267</span> std::cout << <span class="stringliteral">"Failed to make path"</span> << std::endl;</div>
|
||||
<div class="line"><a id="l00268" name="l00268"></a><span class="lineno"> 268</span> abort();</div>
|
||||
<div class="line"><a id="l00269" name="l00269"></a><span class="lineno"> 269</span> }</div>
|
||||
<div class="line"><a id="l00270" name="l00270"></a><span class="lineno"> 270</span> </div>
|
||||
<div class="line"><a id="l00271" name="l00271"></a><span class="lineno"> 271</span> <a class="code hl_struct" href="structsimulation.html">simulation_t</a> res =</div>
|
||||
<div class="line"><a id="l00272" name="l00272"></a><span class="lineno"> 272</span> this-><a class="code hl_function" href="classPenningTrap.html#a7a1d9f0528a12308de25bc30718da20a">simulate</a>(time, steps, method, particle_interaction);</div>
|
||||
<div class="line"><a id="l00273" name="l00273"></a><span class="lineno"> 273</span> </div>
|
||||
<div class="line"><a id="l00274" name="l00274"></a><span class="lineno"> 274</span> std::ofstream ofile;</div>
|
||||
<div class="line"><a id="l00275" name="l00275"></a><span class="lineno"> 275</span> </div>
|
||||
<div class="line"><a id="l00276" name="l00276"></a><span class="lineno"> 276</span> <span class="comment">// Writing each particle to its own file is independent and can be run in</span></div>
|
||||
<div class="line"><a id="l00277" name="l00277"></a><span class="lineno"> 277</span> <span class="comment">// parallel.</span></div>
|
||||
<div class="line"><a id="l00278" name="l00278"></a><span class="lineno"> 278</span><span class="preprocessor">#pragma omp parallel for private(ofile)</span></div>
|
||||
<div class="line"><a id="l00279" name="l00279"></a><span class="lineno"> 279</span> <span class="keywordflow">for</span> (<span class="keywordtype">size_t</span> i = 0; i < this-><a class="code hl_variable" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">particles</a>.size(); i++) {</div>
|
||||
<div class="line"><a id="l00280" name="l00280"></a><span class="lineno"> 280</span> ofile.open(path + <span class="stringliteral">"particle_"</span> + std::to_string(i) + <span class="stringliteral">"_r.txt"</span>);</div>
|
||||
<div class="line"><a id="l00281" name="l00281"></a><span class="lineno"> 281</span> <span class="keywordflow">for</span> (<a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> &vec : res.r_vecs[i]) {</div>
|
||||
<div class="line"><a id="l00282" name="l00282"></a><span class="lineno"> 282</span> ofile << <a class="code hl_function" href="utils_8hpp.html#adfb618b2fdff47ef30a4a2b62c04f384">scientific_format</a>(vec(0), 10, 8) << <span class="charliteral">','</span></div>
|
||||
<div class="line"><a id="l00283" name="l00283"></a><span class="lineno"> 283</span> << <a class="code hl_function" href="utils_8hpp.html#adfb618b2fdff47ef30a4a2b62c04f384">scientific_format</a>(vec(1), 10, 8) << <span class="charliteral">','</span></div>
|
||||
<div class="line"><a id="l00284" name="l00284"></a><span class="lineno"> 284</span> << <a class="code hl_function" href="utils_8hpp.html#adfb618b2fdff47ef30a4a2b62c04f384">scientific_format</a>(vec(2), 10, 8) << <span class="charliteral">'\n'</span>;</div>
|
||||
<div class="line"><a id="l00285" name="l00285"></a><span class="lineno"> 285</span> }</div>
|
||||
<div class="line"><a id="l00286" name="l00286"></a><span class="lineno"> 286</span> ofile.close();</div>
|
||||
<div class="line"><a id="l00287" name="l00287"></a><span class="lineno"> 287</span> ofile.open(path + <span class="stringliteral">"particle_"</span> + std::to_string(i) + <span class="stringliteral">"_v.txt"</span>);</div>
|
||||
<div class="line"><a id="l00288" name="l00288"></a><span class="lineno"> 288</span> <span class="keywordflow">for</span> (<a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> &vec : res.v_vecs[i]) {</div>
|
||||
<div class="line"><a id="l00289" name="l00289"></a><span class="lineno"> 289</span> ofile << <a class="code hl_function" href="utils_8hpp.html#adfb618b2fdff47ef30a4a2b62c04f384">scientific_format</a>(vec(0), 10, 8) << <span class="charliteral">','</span></div>
|
||||
<div class="line"><a id="l00290" name="l00290"></a><span class="lineno"> 290</span> << <a class="code hl_function" href="utils_8hpp.html#adfb618b2fdff47ef30a4a2b62c04f384">scientific_format</a>(vec(1), 10, 8) << <span class="charliteral">','</span></div>
|
||||
<div class="line"><a id="l00291" name="l00291"></a><span class="lineno"> 291</span> << <a class="code hl_function" href="utils_8hpp.html#adfb618b2fdff47ef30a4a2b62c04f384">scientific_format</a>(vec(2), 10, 8) << <span class="charliteral">'\n'</span>;</div>
|
||||
<div class="line"><a id="l00292" name="l00292"></a><span class="lineno"> 292</span> }</div>
|
||||
<div class="line"><a id="l00293" name="l00293"></a><span class="lineno"> 293</span> ofile.close();</div>
|
||||
<div class="line"><a id="l00294" name="l00294"></a><span class="lineno"> 294</span> }</div>
|
||||
<div class="line"><a id="l00295" name="l00295"></a><span class="lineno"> 295</span>}</div>
|
||||
<div class="line"><a id="l00296" name="l00296"></a><span class="lineno"> 296</span> </div>
|
||||
<div class="line"><a id="l00297" name="l00297"></a><span class="lineno"><a class="line" href="classPenningTrap.html#ac529aa26c288f34eae184a67e6bac41f"> 297</a></span><span class="keywordtype">double</span> <a class="code hl_function" href="classPenningTrap.html#ac529aa26c288f34eae184a67e6bac41f">PenningTrap::fraction_of_particles_left</a>(<span class="keywordtype">double</span> time, uint steps,</div>
|
||||
<div class="line"><a id="l00298" name="l00298"></a><span class="lineno"> 298</span> std::string method,</div>
|
||||
<div class="line"><a id="l00299" name="l00299"></a><span class="lineno"> 299</span> <span class="keywordtype">bool</span> particle_interaction)</div>
|
||||
<div class="line"><a id="l00300" name="l00300"></a><span class="lineno"> 300</span>{</div>
|
||||
<div class="line"><a id="l00301" name="l00301"></a><span class="lineno"> 301</span> <span class="keywordtype">double</span> dt = time / (double)steps;</div>
|
||||
<div class="line"><a id="l00302" name="l00302"></a><span class="lineno"> 302</span> </div>
|
||||
<div class="line"><a id="l00303" name="l00303"></a><span class="lineno"> 303</span> void (<a class="code hl_class" href="classPenningTrap.html">PenningTrap</a>::*func)(double, bool);</div>
|
||||
<div class="line"><a id="l00304" name="l00304"></a><span class="lineno"> 304</span> <span class="keywordflow">if</span> (method == <span class="stringliteral">"rk4"</span>) {</div>
|
||||
<div class="line"><a id="l00305" name="l00305"></a><span class="lineno"> 305</span> func = &<a class="code hl_function" href="classPenningTrap.html#a36946152fd951b1f7c346c51ff900d8e">PenningTrap::evolve_RK4</a>;</div>
|
||||
<div class="line"><a id="l00306" name="l00306"></a><span class="lineno"> 306</span> } <span class="keywordflow">else</span> <span class="keywordflow">if</span> (method == <span class="stringliteral">"euler"</span>) {</div>
|
||||
<div class="line"><a id="l00307" name="l00307"></a><span class="lineno"> 307</span> func = &<a class="code hl_function" href="classPenningTrap.html#ab9ea97a406534bbe621a95215144875e">PenningTrap::evolve_forward_euler</a>;</div>
|
||||
<div class="line"><a id="l00308" name="l00308"></a><span class="lineno"> 308</span> } <span class="keywordflow">else</span> {</div>
|
||||
<div class="line"><a id="l00309" name="l00309"></a><span class="lineno"> 309</span> std::cout << <span class="stringliteral">"Not a valid method!"</span> << std::endl;</div>
|
||||
<div class="line"><a id="l00310" name="l00310"></a><span class="lineno"> 310</span> abort();</div>
|
||||
<div class="line"><a id="l00311" name="l00311"></a><span class="lineno"> 311</span> }</div>
|
||||
<div class="line"><a id="l00312" name="l00312"></a><span class="lineno"> 312</span> </div>
|
||||
<div class="line"><a id="l00313" name="l00313"></a><span class="lineno"> 313</span> <span class="keywordflow">for</span> (<span class="keywordtype">size_t</span> j = 0; j < steps; j++) {</div>
|
||||
<div class="line"><a id="l00314" name="l00314"></a><span class="lineno"> 314</span> (this->*func)(dt, particle_interaction);</div>
|
||||
<div class="line"><a id="l00315" name="l00315"></a><span class="lineno"> 315</span> }</div>
|
||||
<div class="line"><a id="l00316" name="l00316"></a><span class="lineno"> 316</span> </div>
|
||||
<div class="line"><a id="l00317" name="l00317"></a><span class="lineno"> 317</span> <span class="keywordtype">int</span> particles_left = 0;</div>
|
||||
<div class="line"><a id="l00318" name="l00318"></a><span class="lineno"> 318</span> </div>
|
||||
<div class="line"><a id="l00319" name="l00319"></a><span class="lineno"> 319</span> <span class="comment">// A reduction is perfect here</span></div>
|
||||
<div class="line"><a id="l00320" name="l00320"></a><span class="lineno"> 320</span><span class="preprocessor">#pragma omp parallel for reduction(+ : particles_left)</span></div>
|
||||
<div class="line"><a id="l00321" name="l00321"></a><span class="lineno"> 321</span> <span class="keywordflow">for</span> (<span class="keywordtype">size_t</span> i = 0; i < this-><a class="code hl_variable" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">particles</a>.size(); i++) {</div>
|
||||
<div class="line"><a id="l00322" name="l00322"></a><span class="lineno"> 322</span> <span class="keywordflow">if</span> (arma::norm(this-><a class="code hl_variable" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">particles</a>[i].r_vec) < this-><a class="code hl_variable" href="classPenningTrap.html#a66dfe89c68716b9502927b97f59c27d2">d</a>) {</div>
|
||||
<div class="line"><a id="l00323" name="l00323"></a><span class="lineno"> 323</span> particles_left++;</div>
|
||||
<div class="line"><a id="l00324" name="l00324"></a><span class="lineno"> 324</span> }</div>
|
||||
<div class="line"><a id="l00325" name="l00325"></a><span class="lineno"> 325</span> }</div>
|
||||
<div class="line"><a id="l00326" name="l00326"></a><span class="lineno"> 326</span> </div>
|
||||
<div class="line"><a id="l00327" name="l00327"></a><span class="lineno"> 327</span> <span class="keywordflow">return</span> (<span class="keywordtype">double</span>)particles_left / (double)this-><a class="code hl_variable" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">particles</a>.size();</div>
|
||||
<div class="line"><a id="l00328" name="l00328"></a><span class="lineno"> 328</span>}</div>
|
||||
<div class="ttc" id="aPenningTrap_8hpp_html"><div class="ttname"><a href="PenningTrap_8hpp.html">PenningTrap.hpp</a></div><div class="ttdoc">A class for simulating a Penning trap.</div></div>
|
||||
<div class="ttc" id="aclassParticle_html"><div class="ttname"><a href="classParticle.html">Particle</a></div><div class="ttdoc">A class that holds attributes of a particle.</div><div class="ttdef"><b>Definition:</b> <a href="Particle_8hpp_source.html#l00019">Particle.hpp:19</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a045adb85e97a8e0c38fb36d2fd74eeee"><div class="ttname"><a href="classPenningTrap.html#a045adb85e97a8e0c38fb36d2fd74eeee">PenningTrap::total_force_external</a></div><div class="ttdeci">arma::vec total_force_external(int i)</div><div class="ttdoc">Calculate the total external force on a particle.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00051">PenningTrap.cpp:51</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a135db7d991d9b88b00fde4edee71f78d"><div class="ttname"><a href="classPenningTrap.html#a135db7d991d9b88b00fde4edee71f78d">PenningTrap::total_force_particles</a></div><div class="ttdeci">arma::vec total_force_particles(int i)</div><div class="ttdoc">Calculate the total force on a particle from other particles.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00056">PenningTrap.cpp:56</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a2a3e7f480ba52e9f24d4c50c3981a784"><div class="ttname"><a href="classPenningTrap.html#a2a3e7f480ba52e9f24d4c50c3981a784">PenningTrap::external_B_field</a></div><div class="ttdeci">arma::vec external_B_field(arma::vec r)</div><div class="ttdoc">Calculate B at point r.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00041">PenningTrap.cpp:41</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a4790f41e4fbc6ede4991aa7bbda92182"><div class="ttname"><a href="classPenningTrap.html#a4790f41e4fbc6ede4991aa7bbda92182">PenningTrap::force_on_particle</a></div><div class="ttdeci">arma::vec force_on_particle(int i, int j)</div><div class="ttdoc">Calculate the force between 2 particles.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00046">PenningTrap.cpp:46</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a56544b6f4befb42984e9650cf2a40965"><div class="ttname"><a href="classPenningTrap.html#a56544b6f4befb42984e9650cf2a40965">PenningTrap::evolve_forward_euler</a></div><div class="ttdeci">void evolve_forward_euler(double dt)</div><div class="ttdoc">Go forward one timestep using the forward Euler method.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00071">PenningTrap.cpp:71</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a6e9776ff5b149f01080800716455d7c8"><div class="ttname"><a href="classPenningTrap.html#a6e9776ff5b149f01080800716455d7c8">PenningTrap::add_particle</a></div><div class="ttdeci">void add_particle(Particle particle)</div><div class="ttdoc">Add a particle to the system.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00031">PenningTrap.cpp:31</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a81add5063bd5f29d77f0b5c299c6c560"><div class="ttname"><a href="classPenningTrap.html#a81add5063bd5f29d77f0b5c299c6c560">PenningTrap::PenningTrap</a></div><div class="ttdeci">PenningTrap(double B_0=T, double V_0=25.*V/1000., double d=500.)</div><div class="ttdoc">Set B_0, V_0 and d.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00026">PenningTrap.cpp:26</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a83cc7a04dae009ed8e75453c38fdf8be"><div class="ttname"><a href="classPenningTrap.html#a83cc7a04dae009ed8e75453c38fdf8be">PenningTrap::total_force</a></div><div class="ttdeci">arma::vec total_force(int i)</div><div class="ttdoc">calculate the total force on a particle.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00061">PenningTrap.cpp:61</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a978a2e2026a4b5308d5184712f81704b"><div class="ttname"><a href="classPenningTrap.html#a978a2e2026a4b5308d5184712f81704b">PenningTrap::external_E_field</a></div><div class="ttdeci">arma::vec external_E_field(arma::vec r)</div><div class="ttdoc">Calculate E at point r.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00036">PenningTrap.cpp:36</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_ab891b839c40eeb38d8a2a636c70090a9"><div class="ttname"><a href="classPenningTrap.html#ab891b839c40eeb38d8a2a636c70090a9">PenningTrap::evolve_RK4</a></div><div class="ttdeci">void evolve_RK4(double dt)</div><div class="ttdoc">Go forward one timestep using the RK4 method.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00066">PenningTrap.cpp:66</a></div></div>
|
||||
<div class="ttc" id="aclassParticle_html"><div class="ttname"><a href="classParticle.html">Particle</a></div><div class="ttdoc">A class that holds attributes of a particle.</div><div class="ttdef"><b>Definition:</b> <a href="Particle_8hpp_source.html#l00022">Particle.hpp:23</a></div></div>
|
||||
<div class="ttc" id="aclassParticle_html_a1c59101411db43624828b766f87ad460"><div class="ttname"><a href="classParticle.html#a1c59101411db43624828b766f87ad460">Particle::r_vec</a></div><div class="ttdeci">vec3 r_vec</div><div class="ttdoc">position</div><div class="ttdef"><b>Definition:</b> <a href="Particle_8hpp_source.html#l00025">Particle.hpp:25</a></div></div>
|
||||
<div class="ttc" id="aclassParticle_html_a3a10400add8dd22b8031330c2aafb6fe"><div class="ttname"><a href="classParticle.html#a3a10400add8dd22b8031330c2aafb6fe">Particle::v_vec</a></div><div class="ttdeci">vec3 v_vec</div><div class="ttdoc">velocity</div><div class="ttdef"><b>Definition:</b> <a href="Particle_8hpp_source.html#l00026">Particle.hpp:26</a></div></div>
|
||||
<div class="ttc" id="aclassParticle_html_a566dcc1de4bdc01251776948798ea8e1"><div class="ttname"><a href="classParticle.html#a566dcc1de4bdc01251776948798ea8e1">Particle::q</a></div><div class="ttdeci">double q</div><div class="ttdoc">Charge.</div><div class="ttdef"><b>Definition:</b> <a href="Particle_8hpp_source.html#l00027">Particle.hpp:27</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html"><div class="ttname"><a href="classPenningTrap.html">PenningTrap</a></div><div class="ttdoc">A class that simulates a Penning trap.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8hpp_source.html#l00031">PenningTrap.hpp:32</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a0112525d9e79a472e761f8ef402a339f"><div class="ttname"><a href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">PenningTrap::particles</a></div><div class="ttdeci">std::vector< Particle > particles</div><div class="ttdoc">The particles in the Penning trap.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8hpp_source.html#l00042">PenningTrap.hpp:42</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a0cac3509aa96e71a26d3b2c902e27716"><div class="ttname"><a href="classPenningTrap.html#a0cac3509aa96e71a26d3b2c902e27716">PenningTrap::B_0</a></div><div class="ttdeci">double B_0</div><div class="ttdoc">Magnetic field strength.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8hpp_source.html#l00037">PenningTrap.hpp:37</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a2c01108b52c8e2a003cf9170da9e7682"><div class="ttname"><a href="classPenningTrap.html#a2c01108b52c8e2a003cf9170da9e7682">PenningTrap::total_force_external</a></div><div class="ttdeci">vec3 total_force_external(uint i)</div><div class="ttdoc">Calculate the total external force on a particle.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00082">PenningTrap.cpp:82</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a2f168622587709b9e3c49077f0b9a640"><div class="ttname"><a href="classPenningTrap.html#a2f168622587709b9e3c49077f0b9a640">PenningTrap::k_r</a></div><div class="ttdeci">sim_arr k_r</div><div class="ttdoc">A 2D vector containing all where is the index of a particle.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8hpp_source.html#l00052">PenningTrap.hpp:52</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a2fe1cefbae18fa5808155ee0d2df713c"><div class="ttname"><a href="classPenningTrap.html#a2fe1cefbae18fa5808155ee0d2df713c">PenningTrap::total_force_particles</a></div><div class="ttdeci">vec3 total_force_particles(uint i)</div><div class="ttdoc">Calculate the total force on a particle p_i from other particles.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00095">PenningTrap.cpp:95</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a361f2c4862c90b5e8e2a2f50c6a95655"><div class="ttname"><a href="classPenningTrap.html#a361f2c4862c90b5e8e2a2f50c6a95655">PenningTrap::external_B_field</a></div><div class="ttdeci">vec3 external_B_field(vec3 r)</div><div class="ttdoc">Calculate B at point r.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00066">PenningTrap.cpp:66</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a36946152fd951b1f7c346c51ff900d8e"><div class="ttname"><a href="classPenningTrap.html#a36946152fd951b1f7c346c51ff900d8e">PenningTrap::evolve_RK4</a></div><div class="ttdeci">void evolve_RK4(double dt, bool particle_interaction=true)</div><div class="ttdoc">Go forward one timestep using the RK4 method.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00163">PenningTrap.cpp:163</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a3c0a44e4e0a94366ff609e81fe463fa2"><div class="ttname"><a href="classPenningTrap.html#a3c0a44e4e0a94366ff609e81fe463fa2">PenningTrap::v_func</a></div><div class="ttdeci">vec3 v_func(uint i, uint j, double dt)</div><div class="ttdoc">Helper for evolve_RK4 when calculating values.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00020">PenningTrap.cpp:20</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a5846c8f75cdc543fd9cf0b2185a3ef22"><div class="ttname"><a href="classPenningTrap.html#a5846c8f75cdc543fd9cf0b2185a3ef22">PenningTrap::external_E_field</a></div><div class="ttdeci">vec3 external_E_field(vec3 r)</div><div class="ttdoc">Calculate E at point r.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00058">PenningTrap.cpp:58</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a5b6c6d4636f3a6e279ccde59d4a345e8"><div class="ttname"><a href="classPenningTrap.html#a5b6c6d4636f3a6e279ccde59d4a345e8">PenningTrap::PenningTrap</a></div><div class="ttdeci">PenningTrap(double B_0=T, double V_0=(25. *V)/1000., double d=500., double t=0.)</div><div class="ttdoc">Constructor for the PenningTrap class.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00115">PenningTrap.cpp:115</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a66dfe89c68716b9502927b97f59c27d2"><div class="ttname"><a href="classPenningTrap.html#a66dfe89c68716b9502927b97f59c27d2">PenningTrap::d</a></div><div class="ttdeci">double d</div><div class="ttdoc">Characteristic dimension.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8hpp_source.html#l00040">PenningTrap.hpp:40</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a6e9776ff5b149f01080800716455d7c8"><div class="ttname"><a href="classPenningTrap.html#a6e9776ff5b149f01080800716455d7c8">PenningTrap::add_particle</a></div><div class="ttdeci">void add_particle(Particle particle)</div><div class="ttdoc">Add a particle to the system.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00158">PenningTrap.cpp:158</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a715329844d75ec4c04f8391421fb4e89"><div class="ttname"><a href="classPenningTrap.html#a715329844d75ec4c04f8391421fb4e89">PenningTrap::V_0</a></div><div class="ttdeci">double V_0</div><div class="ttdoc">Applied potential.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8hpp_source.html#l00038">PenningTrap.hpp:38</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a7a1d9f0528a12308de25bc30718da20a"><div class="ttname"><a href="classPenningTrap.html#a7a1d9f0528a12308de25bc30718da20a">PenningTrap::simulate</a></div><div class="ttdeci">simulation_t simulate(double time, uint steps, std::string method="rk4", bool particle_interaction=true)</div><div class="ttdoc">Simulate the particle system inside the Penning trap over a certain amount of time.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00228">PenningTrap.cpp:228</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a7f210bb2768a5d79ced4b0df0df97598"><div class="ttname"><a href="classPenningTrap.html#a7f210bb2768a5d79ced4b0df0df97598">PenningTrap::force_on_particle</a></div><div class="ttdeci">vec3 force_on_particle(uint i, uint j)</div><div class="ttdoc">Calculate the force between 2 particles.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00071">PenningTrap.cpp:71</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a826b7fa8e709d481eb1dee7d0c2cdc08"><div class="ttname"><a href="classPenningTrap.html#a826b7fa8e709d481eb1dee7d0c2cdc08">PenningTrap::r_func</a></div><div class="ttdeci">vec3 r_func(uint i, uint j, double dt)</div><div class="ttdoc">Helper for evolve_RK4 when calculating values.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00039">PenningTrap.cpp:39</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a8ca4e21291f60fde619c14099d8c4e8e"><div class="ttname"><a href="classPenningTrap.html#a8ca4e21291f60fde619c14099d8c4e8e">PenningTrap::t</a></div><div class="ttdeci">double t</div><div class="ttdoc">Current time.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8hpp_source.html#l00041">PenningTrap.hpp:41</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a9a301b0540078c36697880ef204afdf3"><div class="ttname"><a href="classPenningTrap.html#a9a301b0540078c36697880ef204afdf3">PenningTrap::total_force</a></div><div class="ttdeci">vec3 total_force(uint i)</div><div class="ttdoc">calculate the total force on a particle p_i.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00107">PenningTrap.cpp:107</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a9d1d8e90ca839b928aee1ad0cd4aff43"><div class="ttname"><a href="classPenningTrap.html#a9d1d8e90ca839b928aee1ad0cd4aff43">PenningTrap::set_pertubation</a></div><div class="ttdeci">void set_pertubation(double f, double omega_V)</div><div class="ttdoc">Time dependent perturbation to V_0.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00141">PenningTrap.cpp:141</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_aaee129f177657455348d0c8ae1441dea"><div class="ttname"><a href="classPenningTrap.html#aaee129f177657455348d0c8ae1441dea">PenningTrap::reinitialize</a></div><div class="ttdeci">void reinitialize(double f, double omega_V, double t=0.)</div><div class="ttdoc">Give all particles new positions and velocities, and change t and V_0.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00148">PenningTrap.cpp:148</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_ab9ea97a406534bbe621a95215144875e"><div class="ttname"><a href="classPenningTrap.html#ab9ea97a406534bbe621a95215144875e">PenningTrap::evolve_forward_euler</a></div><div class="ttdeci">void evolve_forward_euler(double dt, bool particle_interaction=true)</div><div class="ttdoc">Go forward one timestep using the forward Euler method.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00201">PenningTrap.cpp:201</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_ac529aa26c288f34eae184a67e6bac41f"><div class="ttname"><a href="classPenningTrap.html#ac529aa26c288f34eae184a67e6bac41f">PenningTrap::fraction_of_particles_left</a></div><div class="ttdeci">double fraction_of_particles_left(double time, uint steps, std::string method="rk4", bool particle_interaction=true)</div><div class="ttdoc">Simulate and calculate what fraction of particles are still left inside the Penning trap after the si...</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00297">PenningTrap.cpp:297</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_ad8bc4df7ab3eed53b16cfdff38e7760b"><div class="ttname"><a href="classPenningTrap.html#ad8bc4df7ab3eed53b16cfdff38e7760b">PenningTrap::write_simulation_to_dir</a></div><div class="ttdeci">void write_simulation_to_dir(std::string path, double time, uint steps, std::string method="rk4", bool particle_interaction=true)</div><div class="ttdoc">Simulate and write the displacement of all particles to files.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00259">PenningTrap.cpp:259</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_ae915f6ad0eef1fb46530e836b6e071e5"><div class="ttname"><a href="classPenningTrap.html#ae915f6ad0eef1fb46530e836b6e071e5">PenningTrap::perturbation</a></div><div class="ttdeci">std::function< double(double)> perturbation</div><div class="ttdoc">Time-dependent perturbation.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8hpp_source.html#l00039">PenningTrap.hpp:39</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_ae9b5afdaa5cd366e94bd294452a1eed4"><div class="ttname"><a href="classPenningTrap.html#ae9b5afdaa5cd366e94bd294452a1eed4">PenningTrap::k_v</a></div><div class="ttdeci">sim_arr k_v</div><div class="ttdoc">A 2D vector containing all where is the index of a particle.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8hpp_source.html#l00047">PenningTrap.hpp:47</a></div></div>
|
||||
<div class="ttc" id="aconstants_8hpp_html_a4e451456ad7e9276ed0afa42826e7ccb"><div class="ttname"><a href="constants_8hpp.html#a4e451456ad7e9276ed0afa42826e7ccb">K_E</a></div><div class="ttdeci">#define K_E</div><div class="ttdoc">Coulomb constant. unit: .</div><div class="ttdef"><b>Definition:</b> <a href="constants_8hpp_source.html#l00017">constants.hpp:17</a></div></div>
|
||||
<div class="ttc" id="astructsimulation_html"><div class="ttname"><a href="structsimulation.html">simulation</a></div><div class="ttdoc">Typedef for PenningTrap::simulation return value.</div><div class="ttdef"><b>Definition:</b> <a href="typedefs_8hpp_source.html#l00040">typedefs.hpp:40</a></div></div>
|
||||
<div class="ttc" id="atypedefs_8hpp_html"><div class="ttname"><a href="typedefs_8hpp.html">typedefs.hpp</a></div><div class="ttdoc">Useful typedefs for cleaner code.</div></div>
|
||||
<div class="ttc" id="atypedefs_8hpp_html_a3bdfb73a02f88ae32b6128ef747c4aea"><div class="ttname"><a href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a></div><div class="ttdeci">arma::vec::fixed< 3 > vec3</div><div class="ttdoc">Typedef for a fixed 3d arma vector.</div><div class="ttdef"><b>Definition:</b> <a href="typedefs_8hpp_source.html#l00023">typedefs.hpp:23</a></div></div>
|
||||
<div class="ttc" id="atypedefs_8hpp_html_a46482a2697556c00556c9d73f461784f"><div class="ttname"><a href="typedefs_8hpp.html#a46482a2697556c00556c9d73f461784f">sim_cols</a></div><div class="ttdeci">std::vector< vec3 > sim_cols</div><div class="ttdoc">Typedef for the column of the result vector from simulating particles.</div><div class="ttdef"><b>Definition:</b> <a href="typedefs_8hpp_source.html#l00028">typedefs.hpp:28</a></div></div>
|
||||
<div class="ttc" id="atypedefs_8hpp_html_aec69d34220fff45de238b9e01f2686af"><div class="ttname"><a href="typedefs_8hpp.html#aec69d34220fff45de238b9e01f2686af">sim_arr</a></div><div class="ttdeci">std::vector< sim_cols > sim_arr</div><div class="ttdoc">Typedef for the result of the simulate method.</div><div class="ttdef"><b>Definition:</b> <a href="typedefs_8hpp_source.html#l00036">typedefs.hpp:36</a></div></div>
|
||||
<div class="ttc" id="autils_8hpp_html_a6fdd7217b750aff5b6295ece7cbdeffa"><div class="ttname"><a href="utils_8hpp.html#a6fdd7217b750aff5b6295ece7cbdeffa">mkpath</a></div><div class="ttdeci">bool mkpath(std::string path, int mode=0777)</div><div class="ttdoc">Make path given.</div><div class="ttdef"><b>Definition:</b> <a href="utils_8cpp_source.html#l00072">utils.cpp:72</a></div></div>
|
||||
<div class="ttc" id="autils_8hpp_html_adfb618b2fdff47ef30a4a2b62c04f384"><div class="ttname"><a href="utils_8hpp.html#adfb618b2fdff47ef30a4a2b62c04f384">scientific_format</a></div><div class="ttdeci">std::string scientific_format(double d, int width=20, int prec=10)</div><div class="ttdoc">Turns a double into a string written in scientific format.</div><div class="ttdef"><b>Definition:</b> <a href="utils_8cpp_source.html#l00015">utils.cpp:15</a></div></div>
|
||||
</div><!-- fragment --></div><!-- contents -->
|
||||
</div><!-- doc-content -->
|
||||
<!-- start footer part -->
|
||||
|
||||
@@ -107,8 +107,11 @@ $(document).ready(function(){initNavTree('PenningTrap_8hpp.html',''); initResiza
|
||||
<p>A class for simulating a Penning trap.
|
||||
<a href="#details">More...</a></p>
|
||||
<div class="textblock"><code>#include <armadillo></code><br />
|
||||
<code>#include "<a class="el" href="constants_8hpp_source.html">constants.hpp</a>"</code><br />
|
||||
<code>#include <omp.h></code><br />
|
||||
<code>#include "<a class="el" href="Particle_8hpp_source.html">Particle.hpp</a>"</code><br />
|
||||
<code>#include "<a class="el" href="constants_8hpp_source.html">constants.hpp</a>"</code><br />
|
||||
<code>#include "<a class="el" href="typedefs_8hpp_source.html">typedefs.hpp</a>"</code><br />
|
||||
<code>#include "<a class="el" href="utils_8hpp_source.html">utils.hpp</a>"</code><br />
|
||||
</div>
|
||||
<p><a href="PenningTrap_8hpp_source.html">Go to the source code of this file.</a></p>
|
||||
<table class="memberdecls">
|
||||
@@ -123,7 +126,7 @@ Classes</h2></td></tr>
|
||||
<dl class="section author"><dt>Author</dt><dd>Cory Alexander Balaton (coryab) </dd>
|
||||
<dd>
|
||||
Janita Ovidie Sandtrøen Willumsen (janitaws)</dd></dl>
|
||||
<dl class="section version"><dt>Version</dt><dd>0.1</dd></dl>
|
||||
<dl class="section version"><dt>Version</dt><dd>1.0</dd></dl>
|
||||
<dl class="bug"><dt><b><a class="el" href="bug.html#_bug000003">Bug:</a></b></dt><dd>No known bugs </dd></dl>
|
||||
|
||||
<p class="definition">Definition in file <a class="el" href="PenningTrap_8hpp_source.html">PenningTrap.hpp</a>.</p>
|
||||
|
||||
@@ -106,59 +106,117 @@ $(document).ready(function(){initNavTree('PenningTrap_8hpp_source.html',''); ini
|
||||
<div class="line"><a id="l00013" name="l00013"></a><span class="lineno"> 13</span><span class="preprocessor">#define __PENNING_TRAP__</span></div>
|
||||
<div class="line"><a id="l00014" name="l00014"></a><span class="lineno"> 14</span> </div>
|
||||
<div class="line"><a id="l00015" name="l00015"></a><span class="lineno"> 15</span><span class="preprocessor">#include <armadillo></span></div>
|
||||
<div class="line"><a id="l00016" name="l00016"></a><span class="lineno"> 16</span> </div>
|
||||
<div class="line"><a id="l00017" name="l00017"></a><span class="lineno"> 17</span><span class="preprocessor">#include "<a class="code" href="constants_8hpp.html">constants.hpp</a>"</span></div>
|
||||
<div class="line"><a id="l00016" name="l00016"></a><span class="lineno"> 16</span><span class="preprocessor">#include <omp.h></span></div>
|
||||
<div class="line"><a id="l00017" name="l00017"></a><span class="lineno"> 17</span> </div>
|
||||
<div class="line"><a id="l00018" name="l00018"></a><span class="lineno"> 18</span><span class="preprocessor">#include "<a class="code" href="Particle_8hpp.html">Particle.hpp</a>"</span></div>
|
||||
<div class="line"><a id="l00019" name="l00019"></a><span class="lineno"> 19</span> </div>
|
||||
<div class="line"><a id="l00025" name="l00025"></a><span class="lineno"><a class="line" href="classPenningTrap.html"> 25</a></span><span class="keyword">class </span><a class="code hl_class" href="classPenningTrap.html">PenningTrap</a> {</div>
|
||||
<div class="line"><a id="l00026" name="l00026"></a><span class="lineno"> 26</span><span class="keyword">private</span>:</div>
|
||||
<div class="line"><a id="l00027" name="l00027"></a><span class="lineno"><a class="line" href="classPenningTrap.html#a0cac3509aa96e71a26d3b2c902e27716"> 27</a></span> <span class="keywordtype">double</span> <a class="code hl_variable" href="classPenningTrap.html#a0cac3509aa96e71a26d3b2c902e27716">B_0</a>; </div>
|
||||
<div class="line"><a id="l00028" name="l00028"></a><span class="lineno"><a class="line" href="classPenningTrap.html#a715329844d75ec4c04f8391421fb4e89"> 28</a></span> <span class="keywordtype">double</span> <a class="code hl_variable" href="classPenningTrap.html#a715329844d75ec4c04f8391421fb4e89">V_0</a>; </div>
|
||||
<div class="line"><a id="l00029" name="l00029"></a><span class="lineno"><a class="line" href="classPenningTrap.html#a66dfe89c68716b9502927b97f59c27d2"> 29</a></span> <span class="keywordtype">double</span> <a class="code hl_variable" href="classPenningTrap.html#a66dfe89c68716b9502927b97f59c27d2">d</a>; </div>
|
||||
<div class="line"><a id="l00030" name="l00030"></a><span class="lineno"><a class="line" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f"> 30</a></span> std::vector<Particle> <a class="code hl_variable" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">particles</a>; </div>
|
||||
<div class="line"><a id="l00031" name="l00031"></a><span class="lineno"> 31</span> </div>
|
||||
<div class="line"><a id="l00032" name="l00032"></a><span class="lineno"> 32</span><span class="keyword">public</span>:</div>
|
||||
<div class="line"><a id="l00035" name="l00035"></a><span class="lineno"> 35</span> <a class="code hl_class" href="classPenningTrap.html">PenningTrap</a>(<span class="keywordtype">double</span> <a class="code hl_variable" href="classPenningTrap.html#a0cac3509aa96e71a26d3b2c902e27716">B_0</a> = <a class="code hl_define" href="constants_8hpp.html#a0acb682b8260ab1c60b918599864e2e5">T</a>, <span class="keywordtype">double</span> <a class="code hl_variable" href="classPenningTrap.html#a715329844d75ec4c04f8391421fb4e89">V_0</a> = 25.*<a class="code hl_define" href="constants_8hpp.html#af40a326b23c68a27cebe60f16634a2cb">V</a>/1000., <span class="keywordtype">double</span> <a class="code hl_variable" href="classPenningTrap.html#a66dfe89c68716b9502927b97f59c27d2">d</a> = 500.);</div>
|
||||
<div class="line"><a id="l00036" name="l00036"></a><span class="lineno"> 36</span> </div>
|
||||
<div class="line"><a id="l00039" name="l00039"></a><span class="lineno"> 39</span> <span class="keywordtype">void</span> <a class="code hl_function" href="classPenningTrap.html#a6e9776ff5b149f01080800716455d7c8">add_particle</a>(<a class="code hl_class" href="classParticle.html">Particle</a> particle);</div>
|
||||
<div class="line"><a id="l00040" name="l00040"></a><span class="lineno"> 40</span> </div>
|
||||
<div class="line"><a id="l00043" name="l00043"></a><span class="lineno"> 43</span> arma::vec <a class="code hl_function" href="classPenningTrap.html#a978a2e2026a4b5308d5184712f81704b">external_E_field</a>(arma::vec r);</div>
|
||||
<div class="line"><a id="l00044" name="l00044"></a><span class="lineno"> 44</span> </div>
|
||||
<div class="line"><a id="l00047" name="l00047"></a><span class="lineno"> 47</span> arma::vec <a class="code hl_function" href="classPenningTrap.html#a2a3e7f480ba52e9f24d4c50c3981a784">external_B_field</a>(arma::vec r);</div>
|
||||
<div class="line"><a id="l00019" name="l00019"></a><span class="lineno"> 19</span><span class="preprocessor">#include "<a class="code" href="constants_8hpp.html">constants.hpp</a>"</span></div>
|
||||
<div class="line"><a id="l00020" name="l00020"></a><span class="lineno"> 20</span><span class="preprocessor">#include "<a class="code" href="typedefs_8hpp.html">typedefs.hpp</a>"</span></div>
|
||||
<div class="line"><a id="l00021" name="l00021"></a><span class="lineno"> 21</span><span class="preprocessor">#include "<a class="code" href="utils_8hpp.html">utils.hpp</a>"</span></div>
|
||||
<div class="line"><a id="l00022" name="l00022"></a><span class="lineno"> 22</span> </div>
|
||||
<div class="line"><a id="l00023" name="l00023"></a><span class="lineno"> 23</span><span class="preprocessor">#pragma omp declare reduction(+ : vec3 : omp_out += omp_in) \</span></div>
|
||||
<div class="line"><a id="l00024" name="l00024"></a><span class="lineno"> 24</span><span class="preprocessor"> initializer(omp_priv = omp_orig)</span></div>
|
||||
<div class="line"><a id="l00025" name="l00025"></a><span class="lineno"> 25</span> </div>
|
||||
<div class="line"><a id="l00031" name="l00031"></a><span class="lineno"><a class="line" href="classPenningTrap.html"> 31</a></span><span class="keyword">class </span><a class="code hl_class" href="classPenningTrap.html">PenningTrap</a></div>
|
||||
<div class="line"><a id="l00032" name="l00032"></a><span class="lineno"> 32</span>{</div>
|
||||
<div class="line"><a id="l00035" name="l00035"></a><span class="lineno"><a class="line" href="classPenningTrap.html#a869f032f37d0569ed16f224b4c4356ae"> 35</a></span> <span class="keyword">friend</span> <span class="keyword">class </span><a class="code hl_class" href="classPenningTrapTest.html">PenningTrapTest</a>;</div>
|
||||
<div class="line"><a id="l00036" name="l00036"></a><span class="lineno"> 36</span><span class="keyword">private</span>:</div>
|
||||
<div class="line"><a id="l00037" name="l00037"></a><span class="lineno"><a class="line" href="classPenningTrap.html#a0cac3509aa96e71a26d3b2c902e27716"> 37</a></span> <span class="keywordtype">double</span> <a class="code hl_variable" href="classPenningTrap.html#a0cac3509aa96e71a26d3b2c902e27716">B_0</a>; </div>
|
||||
<div class="line"><a id="l00038" name="l00038"></a><span class="lineno"><a class="line" href="classPenningTrap.html#a715329844d75ec4c04f8391421fb4e89"> 38</a></span> <span class="keywordtype">double</span> <a class="code hl_variable" href="classPenningTrap.html#a715329844d75ec4c04f8391421fb4e89">V_0</a>; </div>
|
||||
<div class="line"><a id="l00039" name="l00039"></a><span class="lineno"><a class="line" href="classPenningTrap.html#ae915f6ad0eef1fb46530e836b6e071e5"> 39</a></span> std::function<double(<span class="keywordtype">double</span>)> <a class="code hl_variable" href="classPenningTrap.html#ae915f6ad0eef1fb46530e836b6e071e5">perturbation</a>; </div>
|
||||
<div class="line"><a id="l00040" name="l00040"></a><span class="lineno"><a class="line" href="classPenningTrap.html#a66dfe89c68716b9502927b97f59c27d2"> 40</a></span> <span class="keywordtype">double</span> <a class="code hl_variable" href="classPenningTrap.html#a66dfe89c68716b9502927b97f59c27d2">d</a>; </div>
|
||||
<div class="line"><a id="l00041" name="l00041"></a><span class="lineno"><a class="line" href="classPenningTrap.html#a8ca4e21291f60fde619c14099d8c4e8e"> 41</a></span> <span class="keywordtype">double</span> <a class="code hl_variable" href="classPenningTrap.html#a8ca4e21291f60fde619c14099d8c4e8e">t</a>; </div>
|
||||
<div class="line"><a id="l00042" name="l00042"></a><span class="lineno"><a class="line" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f"> 42</a></span> std::vector<Particle> <a class="code hl_variable" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">particles</a>; </div>
|
||||
<div class="line"><a id="l00043" name="l00043"></a><span class="lineno"> 43</span> </div>
|
||||
<div class="line"><a id="l00047" name="l00047"></a><span class="lineno"><a class="line" href="classPenningTrap.html#ae9b5afdaa5cd366e94bd294452a1eed4"> 47</a></span> <a class="code hl_typedef" href="typedefs_8hpp.html#aec69d34220fff45de238b9e01f2686af">sim_arr</a> <a class="code hl_variable" href="classPenningTrap.html#ae9b5afdaa5cd366e94bd294452a1eed4">k_v</a>;</div>
|
||||
<div class="line"><a id="l00048" name="l00048"></a><span class="lineno"> 48</span> </div>
|
||||
<div class="line"><a id="l00054" name="l00054"></a><span class="lineno"> 54</span> arma::vec <a class="code hl_function" href="classPenningTrap.html#a4790f41e4fbc6ede4991aa7bbda92182">force_on_particle</a>(<span class="keywordtype">int</span> i, <span class="keywordtype">int</span> j);</div>
|
||||
<div class="line"><a id="l00055" name="l00055"></a><span class="lineno"> 55</span> </div>
|
||||
<div class="line"><a id="l00061" name="l00061"></a><span class="lineno"> 61</span> arma::vec <a class="code hl_function" href="classPenningTrap.html#a045adb85e97a8e0c38fb36d2fd74eeee">total_force_external</a>(<span class="keywordtype">int</span> i);</div>
|
||||
<div class="line"><a id="l00062" name="l00062"></a><span class="lineno"> 62</span> </div>
|
||||
<div class="line"><a id="l00065" name="l00065"></a><span class="lineno"> 65</span> arma::vec <a class="code hl_function" href="classPenningTrap.html#a135db7d991d9b88b00fde4edee71f78d">total_force_particles</a>(<span class="keywordtype">int</span> i);</div>
|
||||
<div class="line"><a id="l00066" name="l00066"></a><span class="lineno"> 66</span> </div>
|
||||
<div class="line"><a id="l00069" name="l00069"></a><span class="lineno"> 69</span> arma::vec <a class="code hl_function" href="classPenningTrap.html#a83cc7a04dae009ed8e75453c38fdf8be">total_force</a>(<span class="keywordtype">int</span> i);</div>
|
||||
<div class="line"><a id="l00070" name="l00070"></a><span class="lineno"> 70</span> </div>
|
||||
<div class="line"><a id="l00073" name="l00073"></a><span class="lineno"> 73</span> <span class="keywordtype">void</span> <a class="code hl_function" href="classPenningTrap.html#ab891b839c40eeb38d8a2a636c70090a9">evolve_RK4</a>(<span class="keywordtype">double</span> dt);</div>
|
||||
<div class="line"><a id="l00074" name="l00074"></a><span class="lineno"> 74</span> </div>
|
||||
<div class="line"><a id="l00077" name="l00077"></a><span class="lineno"> 77</span> <span class="keywordtype">void</span> <a class="code hl_function" href="classPenningTrap.html#a56544b6f4befb42984e9650cf2a40965">evolve_forward_euler</a>(<span class="keywordtype">double</span> dt);</div>
|
||||
<div class="line"><a id="l00078" name="l00078"></a><span class="lineno"> 78</span>};</div>
|
||||
<div class="line"><a id="l00079" name="l00079"></a><span class="lineno"> 79</span> </div>
|
||||
<div class="line"><a id="l00080" name="l00080"></a><span class="lineno"> 80</span><span class="preprocessor">#endif</span></div>
|
||||
<div class="line"><a id="l00052" name="l00052"></a><span class="lineno"><a class="line" href="classPenningTrap.html#a2f168622587709b9e3c49077f0b9a640"> 52</a></span> <a class="code hl_typedef" href="typedefs_8hpp.html#aec69d34220fff45de238b9e01f2686af">sim_arr</a> <a class="code hl_variable" href="classPenningTrap.html#a2f168622587709b9e3c49077f0b9a640">k_r</a>;</div>
|
||||
<div class="line"><a id="l00053" name="l00053"></a><span class="lineno"> 53</span> </div>
|
||||
<div class="line"><a id="l00064" name="l00064"></a><span class="lineno"> 64</span> <a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> <a class="code hl_function" href="classPenningTrap.html#a3c0a44e4e0a94366ff609e81fe463fa2">v_func</a>(uint i, uint j, <span class="keywordtype">double</span> dt);</div>
|
||||
<div class="line"><a id="l00065" name="l00065"></a><span class="lineno"> 65</span> </div>
|
||||
<div class="line"><a id="l00076" name="l00076"></a><span class="lineno"> 76</span> <a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> <a class="code hl_function" href="classPenningTrap.html#a826b7fa8e709d481eb1dee7d0c2cdc08">r_func</a>(uint i, uint j, <span class="keywordtype">double</span> dt);</div>
|
||||
<div class="line"><a id="l00077" name="l00077"></a><span class="lineno"> 77</span> </div>
|
||||
<div class="line"><a id="l00084" name="l00084"></a><span class="lineno"> 84</span> <a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> <a class="code hl_function" href="classPenningTrap.html#a5846c8f75cdc543fd9cf0b2185a3ef22">external_E_field</a>(<a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> r);</div>
|
||||
<div class="line"><a id="l00085" name="l00085"></a><span class="lineno"> 85</span> </div>
|
||||
<div class="line"><a id="l00092" name="l00092"></a><span class="lineno"> 92</span> <a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> <a class="code hl_function" href="classPenningTrap.html#a361f2c4862c90b5e8e2a2f50c6a95655">external_B_field</a>(<a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> r);</div>
|
||||
<div class="line"><a id="l00093" name="l00093"></a><span class="lineno"> 93</span> </div>
|
||||
<div class="line"><a id="l00104" name="l00104"></a><span class="lineno"> 104</span> <a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> <a class="code hl_function" href="classPenningTrap.html#a7f210bb2768a5d79ced4b0df0df97598">force_on_particle</a>(uint i, uint j);</div>
|
||||
<div class="line"><a id="l00105" name="l00105"></a><span class="lineno"> 105</span> </div>
|
||||
<div class="line"><a id="l00115" name="l00115"></a><span class="lineno"> 115</span> <a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> <a class="code hl_function" href="classPenningTrap.html#a2c01108b52c8e2a003cf9170da9e7682">total_force_external</a>(uint i);</div>
|
||||
<div class="line"><a id="l00116" name="l00116"></a><span class="lineno"> 116</span> </div>
|
||||
<div class="line"><a id="l00124" name="l00124"></a><span class="lineno"> 124</span> <a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> <a class="code hl_function" href="classPenningTrap.html#a2fe1cefbae18fa5808155ee0d2df713c">total_force_particles</a>(uint i);</div>
|
||||
<div class="line"><a id="l00125" name="l00125"></a><span class="lineno"> 125</span> </div>
|
||||
<div class="line"><a id="l00132" name="l00132"></a><span class="lineno"> 132</span> <a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> <a class="code hl_function" href="classPenningTrap.html#a9a301b0540078c36697880ef204afdf3">total_force</a>(uint i);</div>
|
||||
<div class="line"><a id="l00133" name="l00133"></a><span class="lineno"> 133</span> </div>
|
||||
<div class="line"><a id="l00134" name="l00134"></a><span class="lineno"> 134</span><span class="keyword">public</span>:</div>
|
||||
<div class="line"><a id="l00142" name="l00142"></a><span class="lineno"> 142</span> <a class="code hl_class" href="classPenningTrap.html">PenningTrap</a>(<span class="keywordtype">double</span> <a class="code hl_variable" href="classPenningTrap.html#a0cac3509aa96e71a26d3b2c902e27716">B_0</a> = <a class="code hl_define" href="constants_8hpp.html#a0acb682b8260ab1c60b918599864e2e5">T</a>, <span class="keywordtype">double</span> <a class="code hl_variable" href="classPenningTrap.html#a715329844d75ec4c04f8391421fb4e89">V_0</a> = (25. * <a class="code hl_define" href="constants_8hpp.html#af40a326b23c68a27cebe60f16634a2cb">V</a>) / 1000., <span class="keywordtype">double</span> <a class="code hl_variable" href="classPenningTrap.html#a66dfe89c68716b9502927b97f59c27d2">d</a> = 500.,</div>
|
||||
<div class="line"><a id="l00143" name="l00143"></a><span class="lineno"> 143</span> <span class="keywordtype">double</span> <a class="code hl_variable" href="classPenningTrap.html#a8ca4e21291f60fde619c14099d8c4e8e">t</a> = 0.);</div>
|
||||
<div class="line"><a id="l00144" name="l00144"></a><span class="lineno"> 144</span> </div>
|
||||
<div class="line"><a id="l00153" name="l00153"></a><span class="lineno"> 153</span> <a class="code hl_class" href="classPenningTrap.html">PenningTrap</a>(uint i, <span class="keywordtype">double</span> <a class="code hl_variable" href="classPenningTrap.html#a0cac3509aa96e71a26d3b2c902e27716">B_0</a> = <a class="code hl_define" href="constants_8hpp.html#a0acb682b8260ab1c60b918599864e2e5">T</a>, <span class="keywordtype">double</span> <a class="code hl_variable" href="classPenningTrap.html#a715329844d75ec4c04f8391421fb4e89">V_0</a> = (25. * <a class="code hl_define" href="constants_8hpp.html#af40a326b23c68a27cebe60f16634a2cb">V</a>) / 1000.,</div>
|
||||
<div class="line"><a id="l00154" name="l00154"></a><span class="lineno"> 154</span> <span class="keywordtype">double</span> <a class="code hl_variable" href="classPenningTrap.html#a66dfe89c68716b9502927b97f59c27d2">d</a> = 500., <span class="keywordtype">double</span> <a class="code hl_variable" href="classPenningTrap.html#a8ca4e21291f60fde619c14099d8c4e8e">t</a> = 0.);</div>
|
||||
<div class="line"><a id="l00155" name="l00155"></a><span class="lineno"> 155</span> </div>
|
||||
<div class="line"><a id="l00164" name="l00164"></a><span class="lineno"> 164</span> <a class="code hl_class" href="classPenningTrap.html">PenningTrap</a>(std::vector<Particle> <a class="code hl_variable" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">particles</a>, <span class="keywordtype">double</span> <a class="code hl_variable" href="classPenningTrap.html#a0cac3509aa96e71a26d3b2c902e27716">B_0</a> = <a class="code hl_define" href="constants_8hpp.html#a0acb682b8260ab1c60b918599864e2e5">T</a>,</div>
|
||||
<div class="line"><a id="l00165" name="l00165"></a><span class="lineno"> 165</span> <span class="keywordtype">double</span> <a class="code hl_variable" href="classPenningTrap.html#a715329844d75ec4c04f8391421fb4e89">V_0</a> = (25. * <a class="code hl_define" href="constants_8hpp.html#af40a326b23c68a27cebe60f16634a2cb">V</a>) / 1000., <span class="keywordtype">double</span> <a class="code hl_variable" href="classPenningTrap.html#a66dfe89c68716b9502927b97f59c27d2">d</a> = 500., <span class="keywordtype">double</span> <a class="code hl_variable" href="classPenningTrap.html#a8ca4e21291f60fde619c14099d8c4e8e">t</a> = 0.);</div>
|
||||
<div class="line"><a id="l00166" name="l00166"></a><span class="lineno"> 166</span> </div>
|
||||
<div class="line"><a id="l00172" name="l00172"></a><span class="lineno"> 172</span> <span class="keywordtype">void</span> <a class="code hl_function" href="classPenningTrap.html#a9d1d8e90ca839b928aee1ad0cd4aff43">set_pertubation</a>(<span class="keywordtype">double</span> f, <span class="keywordtype">double</span> omega_V);</div>
|
||||
<div class="line"><a id="l00173" name="l00173"></a><span class="lineno"> 173</span> </div>
|
||||
<div class="line"><a id="l00180" name="l00180"></a><span class="lineno"> 180</span> <span class="keywordtype">void</span> <a class="code hl_function" href="classPenningTrap.html#aaee129f177657455348d0c8ae1441dea">reinitialize</a>(<span class="keywordtype">double</span> f, <span class="keywordtype">double</span> omega_V, <span class="keywordtype">double</span> <a class="code hl_variable" href="classPenningTrap.html#a8ca4e21291f60fde619c14099d8c4e8e">t</a> = 0.);</div>
|
||||
<div class="line"><a id="l00181" name="l00181"></a><span class="lineno"> 181</span> </div>
|
||||
<div class="line"><a id="l00186" name="l00186"></a><span class="lineno"> 186</span> <span class="keywordtype">void</span> <a class="code hl_function" href="classPenningTrap.html#a6e9776ff5b149f01080800716455d7c8">add_particle</a>(<a class="code hl_class" href="classParticle.html">Particle</a> particle);</div>
|
||||
<div class="line"><a id="l00187" name="l00187"></a><span class="lineno"> 187</span> </div>
|
||||
<div class="line"><a id="l00193" name="l00193"></a><span class="lineno"> 193</span> <span class="keywordtype">void</span> <a class="code hl_function" href="classPenningTrap.html#a36946152fd951b1f7c346c51ff900d8e">evolve_RK4</a>(<span class="keywordtype">double</span> dt, <span class="keywordtype">bool</span> particle_interaction = <span class="keyword">true</span>);</div>
|
||||
<div class="line"><a id="l00194" name="l00194"></a><span class="lineno"> 194</span> </div>
|
||||
<div class="line"><a id="l00200" name="l00200"></a><span class="lineno"> 200</span> <span class="keywordtype">void</span> <a class="code hl_function" href="classPenningTrap.html#ab9ea97a406534bbe621a95215144875e">evolve_forward_euler</a>(<span class="keywordtype">double</span> dt, <span class="keywordtype">bool</span> particle_interaction = <span class="keyword">true</span>);</div>
|
||||
<div class="line"><a id="l00201" name="l00201"></a><span class="lineno"> 201</span> </div>
|
||||
<div class="line"><a id="l00212" name="l00212"></a><span class="lineno"> 212</span> <a class="code hl_struct" href="structsimulation.html">simulation_t</a> <a class="code hl_function" href="classPenningTrap.html#a7a1d9f0528a12308de25bc30718da20a">simulate</a>(<span class="keywordtype">double</span> time, uint steps, std::string method = <span class="stringliteral">"rk4"</span>,</div>
|
||||
<div class="line"><a id="l00213" name="l00213"></a><span class="lineno"> 213</span> <span class="keywordtype">bool</span> particle_interaction = <span class="keyword">true</span>);</div>
|
||||
<div class="line"><a id="l00214" name="l00214"></a><span class="lineno"> 214</span> </div>
|
||||
<div class="line"><a id="l00223" name="l00223"></a><span class="lineno"> 223</span> <span class="keywordtype">void</span> <a class="code hl_function" href="classPenningTrap.html#ad8bc4df7ab3eed53b16cfdff38e7760b">write_simulation_to_dir</a>(std::string path, <span class="keywordtype">double</span> time, uint steps,</div>
|
||||
<div class="line"><a id="l00224" name="l00224"></a><span class="lineno"> 224</span> std::string method = <span class="stringliteral">"rk4"</span>,</div>
|
||||
<div class="line"><a id="l00225" name="l00225"></a><span class="lineno"> 225</span> <span class="keywordtype">bool</span> particle_interaction = <span class="keyword">true</span>);</div>
|
||||
<div class="line"><a id="l00226" name="l00226"></a><span class="lineno"> 226</span> </div>
|
||||
<div class="line"><a id="l00237" name="l00237"></a><span class="lineno"> 237</span> <span class="keywordtype">double</span> <a class="code hl_function" href="classPenningTrap.html#ac529aa26c288f34eae184a67e6bac41f">fraction_of_particles_left</a>(<span class="keywordtype">double</span> time, uint steps,</div>
|
||||
<div class="line"><a id="l00238" name="l00238"></a><span class="lineno"> 238</span> std::string method = <span class="stringliteral">"rk4"</span>,</div>
|
||||
<div class="line"><a id="l00239" name="l00239"></a><span class="lineno"> 239</span> <span class="keywordtype">bool</span> particle_interaction = <span class="keyword">true</span>);</div>
|
||||
<div class="line"><a id="l00240" name="l00240"></a><span class="lineno"> 240</span> </div>
|
||||
<div class="line"><a id="l00241" name="l00241"></a><span class="lineno"> 241</span>};</div>
|
||||
<div class="line"><a id="l00242" name="l00242"></a><span class="lineno"> 242</span> </div>
|
||||
<div class="line"><a id="l00243" name="l00243"></a><span class="lineno"> 243</span><span class="preprocessor">#endif</span></div>
|
||||
<div class="ttc" id="aParticle_8hpp_html"><div class="ttname"><a href="Particle_8hpp.html">Particle.hpp</a></div><div class="ttdoc">A class that holds the properties of a particle.</div></div>
|
||||
<div class="ttc" id="aclassParticle_html"><div class="ttname"><a href="classParticle.html">Particle</a></div><div class="ttdoc">A class that holds attributes of a particle.</div><div class="ttdef"><b>Definition:</b> <a href="Particle_8hpp_source.html#l00019">Particle.hpp:19</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html"><div class="ttname"><a href="classPenningTrap.html">PenningTrap</a></div><div class="ttdoc">A class that simulates a Penning trap.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8hpp_source.html#l00025">PenningTrap.hpp:25</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a0112525d9e79a472e761f8ef402a339f"><div class="ttname"><a href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">PenningTrap::particles</a></div><div class="ttdeci">std::vector< Particle > particles</div><div class="ttdoc">The particles in the Penning trap.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8hpp_source.html#l00030">PenningTrap.hpp:30</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a045adb85e97a8e0c38fb36d2fd74eeee"><div class="ttname"><a href="classPenningTrap.html#a045adb85e97a8e0c38fb36d2fd74eeee">PenningTrap::total_force_external</a></div><div class="ttdeci">arma::vec total_force_external(int i)</div><div class="ttdoc">Calculate the total external force on a particle.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00051">PenningTrap.cpp:51</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a0cac3509aa96e71a26d3b2c902e27716"><div class="ttname"><a href="classPenningTrap.html#a0cac3509aa96e71a26d3b2c902e27716">PenningTrap::B_0</a></div><div class="ttdeci">double B_0</div><div class="ttdoc">Magnetic field strength.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8hpp_source.html#l00027">PenningTrap.hpp:27</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a135db7d991d9b88b00fde4edee71f78d"><div class="ttname"><a href="classPenningTrap.html#a135db7d991d9b88b00fde4edee71f78d">PenningTrap::total_force_particles</a></div><div class="ttdeci">arma::vec total_force_particles(int i)</div><div class="ttdoc">Calculate the total force on a particle from other particles.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00056">PenningTrap.cpp:56</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a2a3e7f480ba52e9f24d4c50c3981a784"><div class="ttname"><a href="classPenningTrap.html#a2a3e7f480ba52e9f24d4c50c3981a784">PenningTrap::external_B_field</a></div><div class="ttdeci">arma::vec external_B_field(arma::vec r)</div><div class="ttdoc">Calculate B at point r.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00041">PenningTrap.cpp:41</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a4790f41e4fbc6ede4991aa7bbda92182"><div class="ttname"><a href="classPenningTrap.html#a4790f41e4fbc6ede4991aa7bbda92182">PenningTrap::force_on_particle</a></div><div class="ttdeci">arma::vec force_on_particle(int i, int j)</div><div class="ttdoc">Calculate the force between 2 particles.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00046">PenningTrap.cpp:46</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a56544b6f4befb42984e9650cf2a40965"><div class="ttname"><a href="classPenningTrap.html#a56544b6f4befb42984e9650cf2a40965">PenningTrap::evolve_forward_euler</a></div><div class="ttdeci">void evolve_forward_euler(double dt)</div><div class="ttdoc">Go forward one timestep using the forward Euler method.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00071">PenningTrap.cpp:71</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a66dfe89c68716b9502927b97f59c27d2"><div class="ttname"><a href="classPenningTrap.html#a66dfe89c68716b9502927b97f59c27d2">PenningTrap::d</a></div><div class="ttdeci">double d</div><div class="ttdoc">Characteristic dimension.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8hpp_source.html#l00029">PenningTrap.hpp:29</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a6e9776ff5b149f01080800716455d7c8"><div class="ttname"><a href="classPenningTrap.html#a6e9776ff5b149f01080800716455d7c8">PenningTrap::add_particle</a></div><div class="ttdeci">void add_particle(Particle particle)</div><div class="ttdoc">Add a particle to the system.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00031">PenningTrap.cpp:31</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a715329844d75ec4c04f8391421fb4e89"><div class="ttname"><a href="classPenningTrap.html#a715329844d75ec4c04f8391421fb4e89">PenningTrap::V_0</a></div><div class="ttdeci">double V_0</div><div class="ttdoc">Applied potential.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8hpp_source.html#l00028">PenningTrap.hpp:28</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a83cc7a04dae009ed8e75453c38fdf8be"><div class="ttname"><a href="classPenningTrap.html#a83cc7a04dae009ed8e75453c38fdf8be">PenningTrap::total_force</a></div><div class="ttdeci">arma::vec total_force(int i)</div><div class="ttdoc">calculate the total force on a particle.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00061">PenningTrap.cpp:61</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a978a2e2026a4b5308d5184712f81704b"><div class="ttname"><a href="classPenningTrap.html#a978a2e2026a4b5308d5184712f81704b">PenningTrap::external_E_field</a></div><div class="ttdeci">arma::vec external_E_field(arma::vec r)</div><div class="ttdoc">Calculate E at point r.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00036">PenningTrap.cpp:36</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_ab891b839c40eeb38d8a2a636c70090a9"><div class="ttname"><a href="classPenningTrap.html#ab891b839c40eeb38d8a2a636c70090a9">PenningTrap::evolve_RK4</a></div><div class="ttdeci">void evolve_RK4(double dt)</div><div class="ttdoc">Go forward one timestep using the RK4 method.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00066">PenningTrap.cpp:66</a></div></div>
|
||||
<div class="ttc" id="aclassParticle_html"><div class="ttname"><a href="classParticle.html">Particle</a></div><div class="ttdoc">A class that holds attributes of a particle.</div><div class="ttdef"><b>Definition:</b> <a href="Particle_8hpp_source.html#l00022">Particle.hpp:23</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrapTest_html"><div class="ttname"><a href="classPenningTrapTest.html">PenningTrapTest</a></div><div class="ttdoc">Test class for the Penning trap.</div><div class="ttdef"><b>Definition:</b> <a href="test__suite_8cpp_source.html#l00023">test_suite.cpp:24</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html"><div class="ttname"><a href="classPenningTrap.html">PenningTrap</a></div><div class="ttdoc">A class that simulates a Penning trap.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8hpp_source.html#l00031">PenningTrap.hpp:32</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a0112525d9e79a472e761f8ef402a339f"><div class="ttname"><a href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">PenningTrap::particles</a></div><div class="ttdeci">std::vector< Particle > particles</div><div class="ttdoc">The particles in the Penning trap.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8hpp_source.html#l00042">PenningTrap.hpp:42</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a0cac3509aa96e71a26d3b2c902e27716"><div class="ttname"><a href="classPenningTrap.html#a0cac3509aa96e71a26d3b2c902e27716">PenningTrap::B_0</a></div><div class="ttdeci">double B_0</div><div class="ttdoc">Magnetic field strength.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8hpp_source.html#l00037">PenningTrap.hpp:37</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a2c01108b52c8e2a003cf9170da9e7682"><div class="ttname"><a href="classPenningTrap.html#a2c01108b52c8e2a003cf9170da9e7682">PenningTrap::total_force_external</a></div><div class="ttdeci">vec3 total_force_external(uint i)</div><div class="ttdoc">Calculate the total external force on a particle.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00082">PenningTrap.cpp:82</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a2f168622587709b9e3c49077f0b9a640"><div class="ttname"><a href="classPenningTrap.html#a2f168622587709b9e3c49077f0b9a640">PenningTrap::k_r</a></div><div class="ttdeci">sim_arr k_r</div><div class="ttdoc">A 2D vector containing all where is the index of a particle.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8hpp_source.html#l00052">PenningTrap.hpp:52</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a2fe1cefbae18fa5808155ee0d2df713c"><div class="ttname"><a href="classPenningTrap.html#a2fe1cefbae18fa5808155ee0d2df713c">PenningTrap::total_force_particles</a></div><div class="ttdeci">vec3 total_force_particles(uint i)</div><div class="ttdoc">Calculate the total force on a particle p_i from other particles.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00095">PenningTrap.cpp:95</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a361f2c4862c90b5e8e2a2f50c6a95655"><div class="ttname"><a href="classPenningTrap.html#a361f2c4862c90b5e8e2a2f50c6a95655">PenningTrap::external_B_field</a></div><div class="ttdeci">vec3 external_B_field(vec3 r)</div><div class="ttdoc">Calculate B at point r.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00066">PenningTrap.cpp:66</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a36946152fd951b1f7c346c51ff900d8e"><div class="ttname"><a href="classPenningTrap.html#a36946152fd951b1f7c346c51ff900d8e">PenningTrap::evolve_RK4</a></div><div class="ttdeci">void evolve_RK4(double dt, bool particle_interaction=true)</div><div class="ttdoc">Go forward one timestep using the RK4 method.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00163">PenningTrap.cpp:163</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a3c0a44e4e0a94366ff609e81fe463fa2"><div class="ttname"><a href="classPenningTrap.html#a3c0a44e4e0a94366ff609e81fe463fa2">PenningTrap::v_func</a></div><div class="ttdeci">vec3 v_func(uint i, uint j, double dt)</div><div class="ttdoc">Helper for evolve_RK4 when calculating values.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00020">PenningTrap.cpp:20</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a5846c8f75cdc543fd9cf0b2185a3ef22"><div class="ttname"><a href="classPenningTrap.html#a5846c8f75cdc543fd9cf0b2185a3ef22">PenningTrap::external_E_field</a></div><div class="ttdeci">vec3 external_E_field(vec3 r)</div><div class="ttdoc">Calculate E at point r.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00058">PenningTrap.cpp:58</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a66dfe89c68716b9502927b97f59c27d2"><div class="ttname"><a href="classPenningTrap.html#a66dfe89c68716b9502927b97f59c27d2">PenningTrap::d</a></div><div class="ttdeci">double d</div><div class="ttdoc">Characteristic dimension.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8hpp_source.html#l00040">PenningTrap.hpp:40</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a6e9776ff5b149f01080800716455d7c8"><div class="ttname"><a href="classPenningTrap.html#a6e9776ff5b149f01080800716455d7c8">PenningTrap::add_particle</a></div><div class="ttdeci">void add_particle(Particle particle)</div><div class="ttdoc">Add a particle to the system.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00158">PenningTrap.cpp:158</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a715329844d75ec4c04f8391421fb4e89"><div class="ttname"><a href="classPenningTrap.html#a715329844d75ec4c04f8391421fb4e89">PenningTrap::V_0</a></div><div class="ttdeci">double V_0</div><div class="ttdoc">Applied potential.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8hpp_source.html#l00038">PenningTrap.hpp:38</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a7a1d9f0528a12308de25bc30718da20a"><div class="ttname"><a href="classPenningTrap.html#a7a1d9f0528a12308de25bc30718da20a">PenningTrap::simulate</a></div><div class="ttdeci">simulation_t simulate(double time, uint steps, std::string method="rk4", bool particle_interaction=true)</div><div class="ttdoc">Simulate the particle system inside the Penning trap over a certain amount of time.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00228">PenningTrap.cpp:228</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a7f210bb2768a5d79ced4b0df0df97598"><div class="ttname"><a href="classPenningTrap.html#a7f210bb2768a5d79ced4b0df0df97598">PenningTrap::force_on_particle</a></div><div class="ttdeci">vec3 force_on_particle(uint i, uint j)</div><div class="ttdoc">Calculate the force between 2 particles.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00071">PenningTrap.cpp:71</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a826b7fa8e709d481eb1dee7d0c2cdc08"><div class="ttname"><a href="classPenningTrap.html#a826b7fa8e709d481eb1dee7d0c2cdc08">PenningTrap::r_func</a></div><div class="ttdeci">vec3 r_func(uint i, uint j, double dt)</div><div class="ttdoc">Helper for evolve_RK4 when calculating values.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00039">PenningTrap.cpp:39</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a8ca4e21291f60fde619c14099d8c4e8e"><div class="ttname"><a href="classPenningTrap.html#a8ca4e21291f60fde619c14099d8c4e8e">PenningTrap::t</a></div><div class="ttdeci">double t</div><div class="ttdoc">Current time.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8hpp_source.html#l00041">PenningTrap.hpp:41</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a9a301b0540078c36697880ef204afdf3"><div class="ttname"><a href="classPenningTrap.html#a9a301b0540078c36697880ef204afdf3">PenningTrap::total_force</a></div><div class="ttdeci">vec3 total_force(uint i)</div><div class="ttdoc">calculate the total force on a particle p_i.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00107">PenningTrap.cpp:107</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_a9d1d8e90ca839b928aee1ad0cd4aff43"><div class="ttname"><a href="classPenningTrap.html#a9d1d8e90ca839b928aee1ad0cd4aff43">PenningTrap::set_pertubation</a></div><div class="ttdeci">void set_pertubation(double f, double omega_V)</div><div class="ttdoc">Time dependent perturbation to V_0.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00141">PenningTrap.cpp:141</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_aaee129f177657455348d0c8ae1441dea"><div class="ttname"><a href="classPenningTrap.html#aaee129f177657455348d0c8ae1441dea">PenningTrap::reinitialize</a></div><div class="ttdeci">void reinitialize(double f, double omega_V, double t=0.)</div><div class="ttdoc">Give all particles new positions and velocities, and change t and V_0.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00148">PenningTrap.cpp:148</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_ab9ea97a406534bbe621a95215144875e"><div class="ttname"><a href="classPenningTrap.html#ab9ea97a406534bbe621a95215144875e">PenningTrap::evolve_forward_euler</a></div><div class="ttdeci">void evolve_forward_euler(double dt, bool particle_interaction=true)</div><div class="ttdoc">Go forward one timestep using the forward Euler method.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00201">PenningTrap.cpp:201</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_ac529aa26c288f34eae184a67e6bac41f"><div class="ttname"><a href="classPenningTrap.html#ac529aa26c288f34eae184a67e6bac41f">PenningTrap::fraction_of_particles_left</a></div><div class="ttdeci">double fraction_of_particles_left(double time, uint steps, std::string method="rk4", bool particle_interaction=true)</div><div class="ttdoc">Simulate and calculate what fraction of particles are still left inside the Penning trap after the si...</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00297">PenningTrap.cpp:297</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_ad8bc4df7ab3eed53b16cfdff38e7760b"><div class="ttname"><a href="classPenningTrap.html#ad8bc4df7ab3eed53b16cfdff38e7760b">PenningTrap::write_simulation_to_dir</a></div><div class="ttdeci">void write_simulation_to_dir(std::string path, double time, uint steps, std::string method="rk4", bool particle_interaction=true)</div><div class="ttdoc">Simulate and write the displacement of all particles to files.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00259">PenningTrap.cpp:259</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_ae915f6ad0eef1fb46530e836b6e071e5"><div class="ttname"><a href="classPenningTrap.html#ae915f6ad0eef1fb46530e836b6e071e5">PenningTrap::perturbation</a></div><div class="ttdeci">std::function< double(double)> perturbation</div><div class="ttdoc">Time-dependent perturbation.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8hpp_source.html#l00039">PenningTrap.hpp:39</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_ae9b5afdaa5cd366e94bd294452a1eed4"><div class="ttname"><a href="classPenningTrap.html#ae9b5afdaa5cd366e94bd294452a1eed4">PenningTrap::k_v</a></div><div class="ttdeci">sim_arr k_v</div><div class="ttdoc">A 2D vector containing all where is the index of a particle.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8hpp_source.html#l00047">PenningTrap.hpp:47</a></div></div>
|
||||
<div class="ttc" id="aconstants_8hpp_html"><div class="ttname"><a href="constants_8hpp.html">constants.hpp</a></div><div class="ttdoc">Library of constants.</div></div>
|
||||
<div class="ttc" id="aconstants_8hpp_html_a0acb682b8260ab1c60b918599864e2e5"><div class="ttname"><a href="constants_8hpp.html#a0acb682b8260ab1c60b918599864e2e5">T</a></div><div class="ttdeci">#define T</div><div class="ttdoc">1 Tesla. unit:</div><div class="ttdef"><b>Definition:</b> <a href="constants_8hpp_source.html#l00017">constants.hpp:17</a></div></div>
|
||||
<div class="ttc" id="aconstants_8hpp_html_af40a326b23c68a27cebe60f16634a2cb"><div class="ttname"><a href="constants_8hpp.html#af40a326b23c68a27cebe60f16634a2cb">V</a></div><div class="ttdeci">#define V</div><div class="ttdoc">1 Volt. unit:</div><div class="ttdef"><b>Definition:</b> <a href="constants_8hpp_source.html#l00019">constants.hpp:19</a></div></div>
|
||||
<div class="ttc" id="aconstants_8hpp_html_a0acb682b8260ab1c60b918599864e2e5"><div class="ttname"><a href="constants_8hpp.html#a0acb682b8260ab1c60b918599864e2e5">T</a></div><div class="ttdeci">#define T</div><div class="ttdoc">1 Tesla. unit:</div><div class="ttdef"><b>Definition:</b> <a href="constants_8hpp_source.html#l00021">constants.hpp:21</a></div></div>
|
||||
<div class="ttc" id="aconstants_8hpp_html_af40a326b23c68a27cebe60f16634a2cb"><div class="ttname"><a href="constants_8hpp.html#af40a326b23c68a27cebe60f16634a2cb">V</a></div><div class="ttdeci">#define V</div><div class="ttdoc">1 Volt. unit:</div><div class="ttdef"><b>Definition:</b> <a href="constants_8hpp_source.html#l00025">constants.hpp:25</a></div></div>
|
||||
<div class="ttc" id="astructsimulation_html"><div class="ttname"><a href="structsimulation.html">simulation</a></div><div class="ttdoc">Typedef for PenningTrap::simulation return value.</div><div class="ttdef"><b>Definition:</b> <a href="typedefs_8hpp_source.html#l00040">typedefs.hpp:40</a></div></div>
|
||||
<div class="ttc" id="atypedefs_8hpp_html"><div class="ttname"><a href="typedefs_8hpp.html">typedefs.hpp</a></div><div class="ttdoc">Useful typedefs for cleaner code.</div></div>
|
||||
<div class="ttc" id="atypedefs_8hpp_html_a3bdfb73a02f88ae32b6128ef747c4aea"><div class="ttname"><a href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a></div><div class="ttdeci">arma::vec::fixed< 3 > vec3</div><div class="ttdoc">Typedef for a fixed 3d arma vector.</div><div class="ttdef"><b>Definition:</b> <a href="typedefs_8hpp_source.html#l00023">typedefs.hpp:23</a></div></div>
|
||||
<div class="ttc" id="atypedefs_8hpp_html_aec69d34220fff45de238b9e01f2686af"><div class="ttname"><a href="typedefs_8hpp.html#aec69d34220fff45de238b9e01f2686af">sim_arr</a></div><div class="ttdeci">std::vector< sim_cols > sim_arr</div><div class="ttdoc">Typedef for the result of the simulate method.</div><div class="ttdef"><b>Definition:</b> <a href="typedefs_8hpp_source.html#l00036">typedefs.hpp:36</a></div></div>
|
||||
<div class="ttc" id="autils_8hpp_html"><div class="ttname"><a href="utils_8hpp.html">utils.hpp</a></div><div class="ttdoc">Function prototypes and macros that are useful.</div></div>
|
||||
</div><!-- fragment --></div><!-- contents -->
|
||||
</div><!-- doc-content -->
|
||||
<!-- start footer part -->
|
||||
|
||||
185
docs/animate__100__particles_8py_source.html
Normal file
185
docs/animate__100__particles_8py_source.html
Normal file
@@ -0,0 +1,185 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=11"/>
|
||||
<meta name="generator" content="Doxygen 1.9.6"/>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1"/>
|
||||
<title>Penning Trap Simulation: src/scripts/animate_100_particles.py Source File</title>
|
||||
<link href="tabs.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="jquery.js"></script>
|
||||
<script type="text/javascript" src="dynsections.js"></script>
|
||||
<link href="navtree.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="resize.js"></script>
|
||||
<script type="text/javascript" src="navtreedata.js"></script>
|
||||
<script type="text/javascript" src="navtree.js"></script>
|
||||
<link href="search/search.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="search/searchdata.js"></script>
|
||||
<script type="text/javascript" src="search/search.js"></script>
|
||||
<script type="text/x-mathjax-config">
|
||||
MathJax.Hub.Config({
|
||||
extensions: ["tex2jax.js"],
|
||||
jax: ["input/TeX","output/HTML-CSS"],
|
||||
});
|
||||
</script>
|
||||
<script type="text/javascript" async="async" src="https://cdn.jsdelivr.net/npm/mathjax@2/MathJax.js"></script>
|
||||
<link href="doxygen.css" rel="stylesheet" type="text/css" />
|
||||
<link href="doxygen-awesome.css" rel="stylesheet" type="text/css"/>
|
||||
</head>
|
||||
<body>
|
||||
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
|
||||
<div id="titlearea">
|
||||
<table cellspacing="0" cellpadding="0">
|
||||
<tbody>
|
||||
<tr id="projectrow">
|
||||
<td id="projectalign">
|
||||
<div id="projectname">Penning Trap Simulation
|
||||
</div>
|
||||
<div id="projectbrief">Simulate particle behavior inside a Penning Trap</div>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
<!-- end header part -->
|
||||
<!-- Generated by Doxygen 1.9.6 -->
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
||||
var searchBox = new SearchBox("searchBox", "search/",'.html');
|
||||
/* @license-end */
|
||||
</script>
|
||||
<script type="text/javascript" src="menudata.js"></script>
|
||||
<script type="text/javascript" src="menu.js"></script>
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
||||
$(function() {
|
||||
initMenu('',true,false,'search.php','Search');
|
||||
$(document).ready(function() { init_search(); });
|
||||
});
|
||||
/* @license-end */
|
||||
</script>
|
||||
<div id="main-nav"></div>
|
||||
</div><!-- top -->
|
||||
<div id="side-nav" class="ui-resizable side-nav-resizable">
|
||||
<div id="nav-tree">
|
||||
<div id="nav-tree-contents">
|
||||
<div id="nav-sync" class="sync"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="splitbar" style="-moz-user-select:none;"
|
||||
class="ui-resizable-handle">
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
||||
$(document).ready(function(){initNavTree('animate__100__particles_8py_source.html',''); initResizable(); });
|
||||
/* @license-end */
|
||||
</script>
|
||||
<div id="doc-content">
|
||||
<!-- window showing the filter options -->
|
||||
<div id="MSearchSelectWindow"
|
||||
onmouseover="return searchBox.OnSearchSelectShow()"
|
||||
onmouseout="return searchBox.OnSearchSelectHide()"
|
||||
onkeydown="return searchBox.OnSearchSelectKey(event)">
|
||||
</div>
|
||||
|
||||
<!-- iframe showing the search results (closed by default) -->
|
||||
<div id="MSearchResultsWindow">
|
||||
<div id="MSearchResults">
|
||||
<div class="SRPage">
|
||||
<div id="SRIndex">
|
||||
<div id="SRResults"></div>
|
||||
<div class="SRStatus" id="Loading">Loading...</div>
|
||||
<div class="SRStatus" id="Searching">Searching...</div>
|
||||
<div class="SRStatus" id="NoMatches">No Matches</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="header">
|
||||
<div class="headertitle"><div class="title">animate_100_particles.py</div></div>
|
||||
</div><!--header-->
|
||||
<div class="contents">
|
||||
<div class="fragment"><div class="line"><a id="l00001" name="l00001"></a><span class="lineno"> 1</span><span class="keyword">import</span> matplotlib.pyplot <span class="keyword">as</span> plt</div>
|
||||
<div class="line"><a id="l00002" name="l00002"></a><span class="lineno"> 2</span><span class="keyword">import</span> numpy <span class="keyword">as</span> np</div>
|
||||
<div class="line"><a id="l00003" name="l00003"></a><span class="lineno"> 3</span><span class="keyword">from</span> matplotlib <span class="keyword">import</span> animation</div>
|
||||
<div class="line"><a id="l00004" name="l00004"></a><span class="lineno"> 4</span><span class="keyword">from</span> mpl_toolkits.mplot3d <span class="keyword">import</span> Axes3D</div>
|
||||
<div class="line"><a id="l00005" name="l00005"></a><span class="lineno"> 5</span> </div>
|
||||
<div class="line"><a id="l00006" name="l00006"></a><span class="lineno"> 6</span> </div>
|
||||
<div class="line"><a id="l00007" name="l00007"></a><span class="lineno"> 7</span><span class="keyword">def </span>get_data(files):</div>
|
||||
<div class="line"><a id="l00008" name="l00008"></a><span class="lineno"> 8</span> res = []</div>
|
||||
<div class="line"><a id="l00009" name="l00009"></a><span class="lineno"> 9</span> <span class="keywordflow">for</span> file <span class="keywordflow">in</span> files:</div>
|
||||
<div class="line"><a id="l00010" name="l00010"></a><span class="lineno"> 10</span> arr = [[], [], []]</div>
|
||||
<div class="line"><a id="l00011" name="l00011"></a><span class="lineno"> 11</span> <span class="keyword">with</span> open(file, encoding=<span class="stringliteral">"utf8"</span>) <span class="keyword">as</span> f:</div>
|
||||
<div class="line"><a id="l00012" name="l00012"></a><span class="lineno"> 12</span> lines = f.readlines()</div>
|
||||
<div class="line"><a id="l00013" name="l00013"></a><span class="lineno"> 13</span> </div>
|
||||
<div class="line"><a id="l00014" name="l00014"></a><span class="lineno"> 14</span> <span class="keywordflow">for</span> line <span class="keywordflow">in</span> lines:</div>
|
||||
<div class="line"><a id="l00015" name="l00015"></a><span class="lineno"> 15</span> xi, yi, zi = map(float, line.strip().split(<span class="stringliteral">","</span>))</div>
|
||||
<div class="line"><a id="l00016" name="l00016"></a><span class="lineno"> 16</span> arr[0].append(xi)</div>
|
||||
<div class="line"><a id="l00017" name="l00017"></a><span class="lineno"> 17</span> arr[1].append(yi)</div>
|
||||
<div class="line"><a id="l00018" name="l00018"></a><span class="lineno"> 18</span> arr[2].append(zi)</div>
|
||||
<div class="line"><a id="l00019" name="l00019"></a><span class="lineno"> 19</span> res.append(arr)</div>
|
||||
<div class="line"><a id="l00020" name="l00020"></a><span class="lineno"> 20</span> </div>
|
||||
<div class="line"><a id="l00021" name="l00021"></a><span class="lineno"> 21</span> <span class="keywordflow">return</span> np.array(res)</div>
|
||||
<div class="line"><a id="l00022" name="l00022"></a><span class="lineno"> 22</span> </div>
|
||||
<div class="line"><a id="l00023" name="l00023"></a><span class="lineno"> 23</span> </div>
|
||||
<div class="line"><a id="l00024" name="l00024"></a><span class="lineno"> 24</span><span class="keyword">def </span>update(num, lines, arr):</div>
|
||||
<div class="line"><a id="l00025" name="l00025"></a><span class="lineno"> 25</span> <span class="keywordflow">for</span> line, a <span class="keywordflow">in</span> zip(lines, arr):</div>
|
||||
<div class="line"><a id="l00026" name="l00026"></a><span class="lineno"> 26</span> line.set_data(a[:2, num - 1 : num])</div>
|
||||
<div class="line"><a id="l00027" name="l00027"></a><span class="lineno"> 27</span> line.set_3d_properties(a[2, num])</div>
|
||||
<div class="line"><a id="l00028" name="l00028"></a><span class="lineno"> 28</span> </div>
|
||||
<div class="line"><a id="l00029" name="l00029"></a><span class="lineno"> 29</span> </div>
|
||||
<div class="line"><a id="l00030" name="l00030"></a><span class="lineno"> 30</span><span class="keyword">def </span>animate():</div>
|
||||
<div class="line"><a id="l00031" name="l00031"></a><span class="lineno"> 31</span> plt.style.use(<span class="stringliteral">"dark_background"</span>)</div>
|
||||
<div class="line"><a id="l00032" name="l00032"></a><span class="lineno"> 32</span> fig = plt.figure()</div>
|
||||
<div class="line"><a id="l00033" name="l00033"></a><span class="lineno"> 33</span> ax = fig.add_subplot(projection=<span class="stringliteral">"3d"</span>)</div>
|
||||
<div class="line"><a id="l00034" name="l00034"></a><span class="lineno"> 34</span> </div>
|
||||
<div class="line"><a id="l00035" name="l00035"></a><span class="lineno"> 35</span> arr = get_data([f<span class="stringliteral">"output/simulate_100_particles/particle_{i}_r.txt"</span> <span class="keywordflow">for</span> i <span class="keywordflow">in</span> range(100)])</div>
|
||||
<div class="line"><a id="l00036" name="l00036"></a><span class="lineno"> 36</span> </div>
|
||||
<div class="line"><a id="l00037" name="l00037"></a><span class="lineno"> 37</span> arr = arr[:, :, ::10]</div>
|
||||
<div class="line"><a id="l00038" name="l00038"></a><span class="lineno"> 38</span> </div>
|
||||
<div class="line"><a id="l00039" name="l00039"></a><span class="lineno"> 39</span> N = len(arr[0][0])</div>
|
||||
<div class="line"><a id="l00040" name="l00040"></a><span class="lineno"> 40</span> </div>
|
||||
<div class="line"><a id="l00041" name="l00041"></a><span class="lineno"> 41</span> lines = [ax.plot(*a[:, 1], <span class="stringliteral">"o"</span>)[0] <span class="keywordflow">for</span> a <span class="keywordflow">in</span> arr]</div>
|
||||
<div class="line"><a id="l00042" name="l00042"></a><span class="lineno"> 42</span> </div>
|
||||
<div class="line"><a id="l00043" name="l00043"></a><span class="lineno"> 43</span> ax.set_title(<span class="stringliteral">"100 particles inside a Penning trap"</span>)</div>
|
||||
<div class="line"><a id="l00044" name="l00044"></a><span class="lineno"> 44</span> plt.figtext(</div>
|
||||
<div class="line"><a id="l00045" name="l00045"></a><span class="lineno"> 45</span> 0.5,</div>
|
||||
<div class="line"><a id="l00046" name="l00046"></a><span class="lineno"> 46</span> 0.01,</div>
|
||||
<div class="line"><a id="l00047" name="l00047"></a><span class="lineno"> 47</span> <span class="stringliteral">"100 randomly generated particles "</span></div>
|
||||
<div class="line"><a id="l00048" name="l00048"></a><span class="lineno"> 48</span> <span class="stringliteral">"evolving over a time of 50 microseconds."</span>,</div>
|
||||
<div class="line"><a id="l00049" name="l00049"></a><span class="lineno"> 49</span> fontsize=12,</div>
|
||||
<div class="line"><a id="l00050" name="l00050"></a><span class="lineno"> 50</span> horizontalalignment=<span class="stringliteral">"center"</span>,</div>
|
||||
<div class="line"><a id="l00051" name="l00051"></a><span class="lineno"> 51</span> )</div>
|
||||
<div class="line"><a id="l00052" name="l00052"></a><span class="lineno"> 52</span> </div>
|
||||
<div class="line"><a id="l00053" name="l00053"></a><span class="lineno"> 53</span> ax.set_xlim3d([-500.0, 500.0])</div>
|
||||
<div class="line"><a id="l00054" name="l00054"></a><span class="lineno"> 54</span> ax.set_xlabel(<span class="stringliteral">"X (micrometers)"</span>)</div>
|
||||
<div class="line"><a id="l00055" name="l00055"></a><span class="lineno"> 55</span> </div>
|
||||
<div class="line"><a id="l00056" name="l00056"></a><span class="lineno"> 56</span> ax.set_ylim3d([-500.0, 500.0])</div>
|
||||
<div class="line"><a id="l00057" name="l00057"></a><span class="lineno"> 57</span> ax.set_ylabel(<span class="stringliteral">"Y (micrometers)"</span>)</div>
|
||||
<div class="line"><a id="l00058" name="l00058"></a><span class="lineno"> 58</span> </div>
|
||||
<div class="line"><a id="l00059" name="l00059"></a><span class="lineno"> 59</span> ax.set_zlim3d([-500.0, 500.0])</div>
|
||||
<div class="line"><a id="l00060" name="l00060"></a><span class="lineno"> 60</span> ax.set_zlabel(<span class="stringliteral">"Z (micrometers)"</span>)</div>
|
||||
<div class="line"><a id="l00061" name="l00061"></a><span class="lineno"> 61</span> </div>
|
||||
<div class="line"><a id="l00062" name="l00062"></a><span class="lineno"> 62</span> ani = animation.FuncAnimation(</div>
|
||||
<div class="line"><a id="l00063" name="l00063"></a><span class="lineno"> 63</span> fig, update, N, fargs=(lines, arr), interval=1, blit=<span class="keyword">False</span></div>
|
||||
<div class="line"><a id="l00064" name="l00064"></a><span class="lineno"> 64</span> )</div>
|
||||
<div class="line"><a id="l00065" name="l00065"></a><span class="lineno"> 65</span> </div>
|
||||
<div class="line"><a id="l00066" name="l00066"></a><span class="lineno"> 66</span> <span class="comment"># ani.save("../images/100_particles.gif", writer=animation.FFMpegFileWriter(fps=50))</span></div>
|
||||
<div class="line"><a id="l00067" name="l00067"></a><span class="lineno"> 67</span> plt.show()</div>
|
||||
<div class="line"><a id="l00068" name="l00068"></a><span class="lineno"> 68</span> </div>
|
||||
<div class="line"><a id="l00069" name="l00069"></a><span class="lineno"> 69</span> </div>
|
||||
<div class="line"><a id="l00070" name="l00070"></a><span class="lineno"> 70</span><span class="keywordflow">if</span> __name__ == <span class="stringliteral">"__main__"</span>:</div>
|
||||
<div class="line"><a id="l00071" name="l00071"></a><span class="lineno"> 71</span> animate()</div>
|
||||
</div><!-- fragment --></div><!-- contents -->
|
||||
</div><!-- doc-content -->
|
||||
<!-- start footer part -->
|
||||
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
|
||||
<ul>
|
||||
<li class="navelem"><a class="el" href="dir_68267d1309a1af8e8297ef4c3efbcdba.html">src</a></li><li class="navelem"><a class="el" href="dir_634e799a3947388232110823971192a8.html">scripts</a></li><li class="navelem"><b>animate_100_particles.py</b></li>
|
||||
<li class="footer">Generated by <a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.9.6 </li>
|
||||
</ul>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
@@ -105,6 +105,8 @@ $(document).ready(function(){initNavTree('annotated.html',''); initResizable();
|
||||
<table class="directory">
|
||||
<tr id="row_0_" class="even"><td class="entry"><span style="width:16px;display:inline-block;"> </span><span class="icona"><span class="icon">C</span></span><a class="el" href="classParticle.html" target="_self">Particle</a></td><td class="desc">A class that holds attributes of a particle </td></tr>
|
||||
<tr id="row_1_" class="odd"><td class="entry"><span style="width:16px;display:inline-block;"> </span><span class="icona"><span class="icon">C</span></span><a class="el" href="classPenningTrap.html" target="_self">PenningTrap</a></td><td class="desc">A class that simulates a Penning trap </td></tr>
|
||||
<tr id="row_2_" class="even"><td class="entry"><span style="width:16px;display:inline-block;"> </span><span class="icona"><span class="icon">C</span></span><a class="el" href="classPenningTrapTest.html" target="_self">PenningTrapTest</a></td><td class="desc">Test class for the Penning trap </td></tr>
|
||||
<tr id="row_3_" class="odd"><td class="entry"><span style="width:16px;display:inline-block;"> </span><span class="icona"><span class="icon">C</span></span><a class="el" href="structsimulation.html" target="_self">simulation</a></td><td class="desc">Typedef for PenningTrap::simulation return value </td></tr>
|
||||
</table>
|
||||
</div><!-- directory -->
|
||||
</div><!-- contents -->
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
var annotated_dup =
|
||||
[
|
||||
[ "Particle", "classParticle.html", "classParticle" ],
|
||||
[ "PenningTrap", "classPenningTrap.html", "classPenningTrap" ]
|
||||
[ "PenningTrap", "classPenningTrap.html", "classPenningTrap" ],
|
||||
[ "PenningTrapTest", "classPenningTrapTest.html", "classPenningTrapTest" ],
|
||||
[ "simulation", "structsimulation.html", null ]
|
||||
];
|
||||
@@ -105,21 +105,23 @@ $(document).ready(function(){initNavTree('bug.html',''); initResizable(); });
|
||||
<dt>File <a class="el" href="constants_8hpp.html">constants.hpp</a> </dt>
|
||||
<dd><a class="anchor" id="_bug000001"></a>No known bugs </dd>
|
||||
<dt>File <a class="el" href="main_8cpp.html">main.cpp</a> </dt>
|
||||
<dd><a class="anchor" id="_bug000005"></a>No known bugs </dd>
|
||||
<dt>File <a class="el" href="Particle_8cpp.html">Particle.cpp</a> </dt>
|
||||
<dd><a class="anchor" id="_bug000006"></a>No known bugs </dd>
|
||||
<dt>File <a class="el" href="Particle_8cpp.html">Particle.cpp</a> </dt>
|
||||
<dd><a class="anchor" id="_bug000007"></a>No known bugs </dd>
|
||||
<dt>File <a class="el" href="Particle_8hpp.html">Particle.hpp</a> </dt>
|
||||
<dd><a class="anchor" id="_bug000002"></a>No known bugs </dd>
|
||||
<dt>File <a class="el" href="PenningTrap_8cpp.html">PenningTrap.cpp</a> </dt>
|
||||
<dd><a class="anchor" id="_bug000007"></a>No known bugs </dd>
|
||||
<dd><a class="anchor" id="_bug000008"></a>No known bugs </dd>
|
||||
<dt>File <a class="el" href="PenningTrap_8hpp.html">PenningTrap.hpp</a> </dt>
|
||||
<dd><a class="anchor" id="_bug000003"></a>No known bugs </dd>
|
||||
<dt>File <a class="el" href="test__suite_8cpp.html">test_suite.cpp</a> </dt>
|
||||
<dd><a class="anchor" id="_bug000008"></a>No known bugs </dd>
|
||||
<dt>File <a class="el" href="utils_8cpp.html">utils.cpp</a> </dt>
|
||||
<dd><a class="anchor" id="_bug000009"></a>No known bugs </dd>
|
||||
<dt>File <a class="el" href="utils_8hpp.html">utils.hpp</a> </dt>
|
||||
<dt>File <a class="el" href="typedefs_8hpp.html">typedefs.hpp</a> </dt>
|
||||
<dd><a class="anchor" id="_bug000004"></a>No known bugs </dd>
|
||||
<dt>File <a class="el" href="utils_8cpp.html">utils.cpp</a> </dt>
|
||||
<dd><a class="anchor" id="_bug000010"></a>No known bugs </dd>
|
||||
<dt>File <a class="el" href="utils_8hpp.html">utils.hpp</a> </dt>
|
||||
<dd><a class="anchor" id="_bug000005"></a>No known bugs </dd>
|
||||
</dl>
|
||||
</div></div><!-- contents -->
|
||||
</div><!-- PageDoc -->
|
||||
|
||||
@@ -105,11 +105,11 @@ $(document).ready(function(){initNavTree('classParticle.html',''); initResizable
|
||||
<p>This is the complete list of members for <a class="el" href="classParticle.html">Particle</a>, including all inherited members.</p>
|
||||
<table class="directory">
|
||||
<tr class="even"><td class="entry"><a class="el" href="classParticle.html#aedcc7e1bc53b0e2b1a4a07c9a1b47563">m</a></td><td class="entry"><a class="el" href="classParticle.html">Particle</a></td><td class="entry"><span class="mlabel">private</span></td></tr>
|
||||
<tr class="odd"><td class="entry"><a class="el" href="classParticle.html#a00e108823877a25513ccae7cac011b4c">Particle</a>(double q, double m, arma::vec::fixed< 3 > r_vec, arma::vec::fixed< 3 > v_vec)</td><td class="entry"><a class="el" href="classParticle.html">Particle</a></td><td class="entry"></td></tr>
|
||||
<tr class="odd"><td class="entry"><a class="el" href="classParticle.html#af1d7535fb8311eaa77d2b7b345882ec4">Particle</a>(vec3 r_vec, vec3 v_vec, double q=CA_CHARGE, double m=CA_MASS)</td><td class="entry"><a class="el" href="classParticle.html">Particle</a></td><td class="entry"></td></tr>
|
||||
<tr class="even"><td class="entry"><a class="el" href="classParticle.html#aa797d319549dc2a0beb06cdbfd430232">PenningTrap</a></td><td class="entry"><a class="el" href="classParticle.html">Particle</a></td><td class="entry"><span class="mlabel">friend</span></td></tr>
|
||||
<tr class="odd"><td class="entry"><a class="el" href="classParticle.html#a566dcc1de4bdc01251776948798ea8e1">q</a></td><td class="entry"><a class="el" href="classParticle.html">Particle</a></td><td class="entry"><span class="mlabel">private</span></td></tr>
|
||||
<tr class="even"><td class="entry"><a class="el" href="classParticle.html#acf1a0f3c978b06d76df5bb4279594467">r_vec</a></td><td class="entry"><a class="el" href="classParticle.html">Particle</a></td><td class="entry"><span class="mlabel">private</span></td></tr>
|
||||
<tr class="odd"><td class="entry"><a class="el" href="classParticle.html#a4a5d22c7aeca66f67d083f270cba25df">v_vec</a></td><td class="entry"><a class="el" href="classParticle.html">Particle</a></td><td class="entry"><span class="mlabel">private</span></td></tr>
|
||||
<tr class="even"><td class="entry"><a class="el" href="classParticle.html#a1c59101411db43624828b766f87ad460">r_vec</a></td><td class="entry"><a class="el" href="classParticle.html">Particle</a></td><td class="entry"><span class="mlabel">private</span></td></tr>
|
||||
<tr class="odd"><td class="entry"><a class="el" href="classParticle.html#a3a10400add8dd22b8031330c2aafb6fe">v_vec</a></td><td class="entry"><a class="el" href="classParticle.html">Particle</a></td><td class="entry"><span class="mlabel">private</span></td></tr>
|
||||
</table></div><!-- contents -->
|
||||
</div><!-- doc-content -->
|
||||
<!-- start footer part -->
|
||||
|
||||
@@ -114,24 +114,24 @@ $(document).ready(function(){initNavTree('classParticle.html',''); initResizable
|
||||
<table class="memberdecls">
|
||||
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="pub-methods" name="pub-methods"></a>
|
||||
Public Member Functions</h2></td></tr>
|
||||
<tr class="memitem:a00e108823877a25513ccae7cac011b4c"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classParticle.html#a00e108823877a25513ccae7cac011b4c">Particle</a> (double <a class="el" href="classParticle.html#a566dcc1de4bdc01251776948798ea8e1">q</a>, double <a class="el" href="classParticle.html#aedcc7e1bc53b0e2b1a4a07c9a1b47563">m</a>, arma::vec::fixed< 3 > <a class="el" href="classParticle.html#acf1a0f3c978b06d76df5bb4279594467">r_vec</a>, arma::vec::fixed< 3 > <a class="el" href="classParticle.html#a4a5d22c7aeca66f67d083f270cba25df">v_vec</a>)</td></tr>
|
||||
<tr class="memdesc:a00e108823877a25513ccae7cac011b4c"><td class="mdescLeft"> </td><td class="mdescRight">Initialize the particle. <br /></td></tr>
|
||||
<tr class="separator:a00e108823877a25513ccae7cac011b4c"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:af1d7535fb8311eaa77d2b7b345882ec4"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classParticle.html#af1d7535fb8311eaa77d2b7b345882ec4">Particle</a> (<a class="el" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> <a class="el" href="classParticle.html#a1c59101411db43624828b766f87ad460">r_vec</a>, <a class="el" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> <a class="el" href="classParticle.html#a3a10400add8dd22b8031330c2aafb6fe">v_vec</a>, double <a class="el" href="classParticle.html#a566dcc1de4bdc01251776948798ea8e1">q</a>=<a class="el" href="constants_8hpp.html#af7602a3a314957137ad1cd719aa23789">CA_CHARGE</a>, double <a class="el" href="classParticle.html#aedcc7e1bc53b0e2b1a4a07c9a1b47563">m</a>=<a class="el" href="constants_8hpp.html#a2ff491cc7958ffd5e749c518a4a60ec8">CA_MASS</a>)</td></tr>
|
||||
<tr class="memdesc:af1d7535fb8311eaa77d2b7b345882ec4"><td class="mdescLeft"> </td><td class="mdescRight">Initialize the particle. <br /></td></tr>
|
||||
<tr class="separator:af1d7535fb8311eaa77d2b7b345882ec4"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
</table><table class="memberdecls">
|
||||
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="pri-attribs" name="pri-attribs"></a>
|
||||
Private Attributes</h2></td></tr>
|
||||
<tr class="memitem:a1c59101411db43624828b766f87ad460"><td class="memItemLeft" align="right" valign="top"><a class="el" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classParticle.html#a1c59101411db43624828b766f87ad460">r_vec</a></td></tr>
|
||||
<tr class="memdesc:a1c59101411db43624828b766f87ad460"><td class="mdescLeft"> </td><td class="mdescRight">position <br /></td></tr>
|
||||
<tr class="separator:a1c59101411db43624828b766f87ad460"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:a3a10400add8dd22b8031330c2aafb6fe"><td class="memItemLeft" align="right" valign="top"><a class="el" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classParticle.html#a3a10400add8dd22b8031330c2aafb6fe">v_vec</a></td></tr>
|
||||
<tr class="memdesc:a3a10400add8dd22b8031330c2aafb6fe"><td class="mdescLeft"> </td><td class="mdescRight">velocity <br /></td></tr>
|
||||
<tr class="separator:a3a10400add8dd22b8031330c2aafb6fe"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:a566dcc1de4bdc01251776948798ea8e1"><td class="memItemLeft" align="right" valign="top">double </td><td class="memItemRight" valign="bottom"><a class="el" href="classParticle.html#a566dcc1de4bdc01251776948798ea8e1">q</a></td></tr>
|
||||
<tr class="memdesc:a566dcc1de4bdc01251776948798ea8e1"><td class="mdescLeft"> </td><td class="mdescRight">Charge. <br /></td></tr>
|
||||
<tr class="separator:a566dcc1de4bdc01251776948798ea8e1"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:aedcc7e1bc53b0e2b1a4a07c9a1b47563"><td class="memItemLeft" align="right" valign="top">double </td><td class="memItemRight" valign="bottom"><a class="el" href="classParticle.html#aedcc7e1bc53b0e2b1a4a07c9a1b47563">m</a></td></tr>
|
||||
<tr class="memdesc:aedcc7e1bc53b0e2b1a4a07c9a1b47563"><td class="mdescLeft"> </td><td class="mdescRight">Mass. <br /></td></tr>
|
||||
<tr class="separator:aedcc7e1bc53b0e2b1a4a07c9a1b47563"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:acf1a0f3c978b06d76df5bb4279594467"><td class="memItemLeft" align="right" valign="top">arma::vec::fixed< 3 > </td><td class="memItemRight" valign="bottom"><a class="el" href="classParticle.html#acf1a0f3c978b06d76df5bb4279594467">r_vec</a></td></tr>
|
||||
<tr class="memdesc:acf1a0f3c978b06d76df5bb4279594467"><td class="mdescLeft"> </td><td class="mdescRight">position <br /></td></tr>
|
||||
<tr class="separator:acf1a0f3c978b06d76df5bb4279594467"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:a4a5d22c7aeca66f67d083f270cba25df"><td class="memItemLeft" align="right" valign="top">arma::vec::fixed< 3 > </td><td class="memItemRight" valign="bottom"><a class="el" href="classParticle.html#a4a5d22c7aeca66f67d083f270cba25df">v_vec</a></td></tr>
|
||||
<tr class="memdesc:a4a5d22c7aeca66f67d083f270cba25df"><td class="mdescLeft"> </td><td class="mdescRight">velocity <br /></td></tr>
|
||||
<tr class="separator:a4a5d22c7aeca66f67d083f270cba25df"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
</table><table class="memberdecls">
|
||||
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="friends" name="friends"></a>
|
||||
Friends</h2></td></tr>
|
||||
@@ -142,10 +142,10 @@ Friends</h2></td></tr>
|
||||
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
|
||||
<div class="textblock"><p>A class that holds attributes of a particle. </p>
|
||||
|
||||
<p class="definition">Definition at line <a class="el" href="Particle_8hpp_source.html#l00019">19</a> of file <a class="el" href="Particle_8hpp_source.html">Particle.hpp</a>.</p>
|
||||
<p class="definition">Definition at line <a class="el" href="Particle_8hpp_source.html#l00022">22</a> of file <a class="el" href="Particle_8hpp_source.html">Particle.hpp</a>.</p>
|
||||
</div><h2 class="groupheader">Constructor & Destructor Documentation</h2>
|
||||
<a id="a00e108823877a25513ccae7cac011b4c" name="a00e108823877a25513ccae7cac011b4c"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#a00e108823877a25513ccae7cac011b4c">◆ </a></span>Particle()</h2>
|
||||
<a id="af1d7535fb8311eaa77d2b7b345882ec4" name="af1d7535fb8311eaa77d2b7b345882ec4"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#af1d7535fb8311eaa77d2b7b345882ec4">◆ </a></span>Particle()</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
@@ -153,26 +153,26 @@ Friends</h2></td></tr>
|
||||
<tr>
|
||||
<td class="memname">Particle::Particle </td>
|
||||
<td>(</td>
|
||||
<td class="paramtype">double </td>
|
||||
<td class="paramname"><em>q</em>, </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="paramkey"></td>
|
||||
<td></td>
|
||||
<td class="paramtype">double </td>
|
||||
<td class="paramname"><em>m</em>, </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="paramkey"></td>
|
||||
<td></td>
|
||||
<td class="paramtype">arma::vec::fixed< 3 > </td>
|
||||
<td class="paramtype"><a class="el" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> </td>
|
||||
<td class="paramname"><em>r_vec</em>, </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="paramkey"></td>
|
||||
<td></td>
|
||||
<td class="paramtype">arma::vec::fixed< 3 > </td>
|
||||
<td class="paramname"><em>v_vec</em> </td>
|
||||
<td class="paramtype"><a class="el" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> </td>
|
||||
<td class="paramname"><em>v_vec</em>, </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="paramkey"></td>
|
||||
<td></td>
|
||||
<td class="paramtype">double </td>
|
||||
<td class="paramname"><em>q</em> = <code><a class="el" href="constants_8hpp.html#af7602a3a314957137ad1cd719aa23789">CA_CHARGE</a></code>, </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="paramkey"></td>
|
||||
<td></td>
|
||||
<td class="paramtype">double </td>
|
||||
<td class="paramname"><em>m</em> = <code><a class="el" href="constants_8hpp.html#a2ff491cc7958ffd5e749c518a4a60ec8">CA_MASS</a></code> </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td></td>
|
||||
@@ -183,9 +183,18 @@ Friends</h2></td></tr>
|
||||
</div><div class="memdoc">
|
||||
|
||||
<p>Initialize the particle. </p>
|
||||
<p>Initialize the particle with a charge, mass, position and velocity. </p>
|
||||
<p>Initialize the particle with a charge, mass, position and velocity.</p>
|
||||
<dl class="params"><dt>Parameters</dt><dd>
|
||||
<table class="params">
|
||||
<tr><td class="paramname">q</td><td>The charge of the particle </td></tr>
|
||||
<tr><td class="paramname">m</td><td>The mass of the particle </td></tr>
|
||||
<tr><td class="paramname">r_vec</td><td>The initial position of the particle </td></tr>
|
||||
<tr><td class="paramname">v_vec</td><td>The initial velocity of the particle </td></tr>
|
||||
</table>
|
||||
</dd>
|
||||
</dl>
|
||||
|
||||
<p class="definition">Definition at line <a class="el" href="Particle_8cpp_source.html#l00016">16</a> of file <a class="el" href="Particle_8cpp_source.html">Particle.cpp</a>.</p>
|
||||
<p class="definition">Definition at line <a class="el" href="Particle_8cpp_source.html#l00015">15</a> of file <a class="el" href="Particle_8cpp_source.html">Particle.cpp</a>.</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
@@ -212,7 +221,7 @@ Friends</h2></td></tr>
|
||||
|
||||
<p>Make private attributes available for <a class="el" href="classPenningTrap.html" title="A class that simulates a Penning trap.">PenningTrap</a>. </p>
|
||||
|
||||
<p class="definition">Definition at line <a class="el" href="Particle_8hpp_source.html#l00038">38</a> of file <a class="el" href="Particle_8hpp_source.html">Particle.hpp</a>.</p>
|
||||
<p class="definition">Definition at line <a class="el" href="Particle_8hpp_source.html#l00045">45</a> of file <a class="el" href="Particle_8hpp_source.html">Particle.hpp</a>.</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
@@ -239,7 +248,7 @@ Friends</h2></td></tr>
|
||||
|
||||
<p>Mass. </p>
|
||||
|
||||
<p class="definition">Definition at line <a class="el" href="Particle_8hpp_source.html#l00022">22</a> of file <a class="el" href="Particle_8hpp_source.html">Particle.hpp</a>.</p>
|
||||
<p class="definition">Definition at line <a class="el" href="Particle_8hpp_source.html#l00028">28</a> of file <a class="el" href="Particle_8hpp_source.html">Particle.hpp</a>.</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
@@ -265,12 +274,12 @@ Friends</h2></td></tr>
|
||||
|
||||
<p>Charge. </p>
|
||||
|
||||
<p class="definition">Definition at line <a class="el" href="Particle_8hpp_source.html#l00021">21</a> of file <a class="el" href="Particle_8hpp_source.html">Particle.hpp</a>.</p>
|
||||
<p class="definition">Definition at line <a class="el" href="Particle_8hpp_source.html#l00027">27</a> of file <a class="el" href="Particle_8hpp_source.html">Particle.hpp</a>.</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<a id="acf1a0f3c978b06d76df5bb4279594467" name="acf1a0f3c978b06d76df5bb4279594467"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#acf1a0f3c978b06d76df5bb4279594467">◆ </a></span>r_vec</h2>
|
||||
<a id="a1c59101411db43624828b766f87ad460" name="a1c59101411db43624828b766f87ad460"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#a1c59101411db43624828b766f87ad460">◆ </a></span>r_vec</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
@@ -279,7 +288,7 @@ Friends</h2></td></tr>
|
||||
<td class="mlabels-left">
|
||||
<table class="memname">
|
||||
<tr>
|
||||
<td class="memname">arma::vec::fixed<3> Particle::r_vec</td>
|
||||
<td class="memname"><a class="el" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> Particle::r_vec</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
@@ -291,12 +300,12 @@ Friends</h2></td></tr>
|
||||
|
||||
<p>position </p>
|
||||
|
||||
<p class="definition">Definition at line <a class="el" href="Particle_8hpp_source.html#l00023">23</a> of file <a class="el" href="Particle_8hpp_source.html">Particle.hpp</a>.</p>
|
||||
<p class="definition">Definition at line <a class="el" href="Particle_8hpp_source.html#l00025">25</a> of file <a class="el" href="Particle_8hpp_source.html">Particle.hpp</a>.</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<a id="a4a5d22c7aeca66f67d083f270cba25df" name="a4a5d22c7aeca66f67d083f270cba25df"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#a4a5d22c7aeca66f67d083f270cba25df">◆ </a></span>v_vec</h2>
|
||||
<a id="a3a10400add8dd22b8031330c2aafb6fe" name="a3a10400add8dd22b8031330c2aafb6fe"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#a3a10400add8dd22b8031330c2aafb6fe">◆ </a></span>v_vec</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
@@ -305,7 +314,7 @@ Friends</h2></td></tr>
|
||||
<td class="mlabels-left">
|
||||
<table class="memname">
|
||||
<tr>
|
||||
<td class="memname">arma::vec::fixed<3> Particle::v_vec</td>
|
||||
<td class="memname"><a class="el" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> Particle::v_vec</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
@@ -317,7 +326,7 @@ Friends</h2></td></tr>
|
||||
|
||||
<p>velocity </p>
|
||||
|
||||
<p class="definition">Definition at line <a class="el" href="Particle_8hpp_source.html#l00024">24</a> of file <a class="el" href="Particle_8hpp_source.html">Particle.hpp</a>.</p>
|
||||
<p class="definition">Definition at line <a class="el" href="Particle_8hpp_source.html#l00026">26</a> of file <a class="el" href="Particle_8hpp_source.html">Particle.hpp</a>.</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
var classParticle =
|
||||
[
|
||||
[ "Particle", "classParticle.html#a00e108823877a25513ccae7cac011b4c", null ],
|
||||
[ "Particle", "classParticle.html#af1d7535fb8311eaa77d2b7b345882ec4", null ],
|
||||
[ "PenningTrap", "classParticle.html#aa797d319549dc2a0beb06cdbfd430232", null ],
|
||||
[ "m", "classParticle.html#aedcc7e1bc53b0e2b1a4a07c9a1b47563", null ],
|
||||
[ "q", "classParticle.html#a566dcc1de4bdc01251776948798ea8e1", null ],
|
||||
[ "r_vec", "classParticle.html#acf1a0f3c978b06d76df5bb4279594467", null ],
|
||||
[ "v_vec", "classParticle.html#a4a5d22c7aeca66f67d083f270cba25df", null ]
|
||||
[ "r_vec", "classParticle.html#a1c59101411db43624828b766f87ad460", null ],
|
||||
[ "v_vec", "classParticle.html#a3a10400add8dd22b8031330c2aafb6fe", null ]
|
||||
];
|
||||
@@ -107,17 +107,31 @@ $(document).ready(function(){initNavTree('classPenningTrap.html',''); initResiza
|
||||
<tr class="even"><td class="entry"><a class="el" href="classPenningTrap.html#a6e9776ff5b149f01080800716455d7c8">add_particle</a>(Particle particle)</td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"></td></tr>
|
||||
<tr class="odd"><td class="entry"><a class="el" href="classPenningTrap.html#a0cac3509aa96e71a26d3b2c902e27716">B_0</a></td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"><span class="mlabel">private</span></td></tr>
|
||||
<tr class="even"><td class="entry"><a class="el" href="classPenningTrap.html#a66dfe89c68716b9502927b97f59c27d2">d</a></td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"><span class="mlabel">private</span></td></tr>
|
||||
<tr class="odd"><td class="entry"><a class="el" href="classPenningTrap.html#a56544b6f4befb42984e9650cf2a40965">evolve_forward_euler</a>(double dt)</td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"></td></tr>
|
||||
<tr class="even"><td class="entry"><a class="el" href="classPenningTrap.html#ab891b839c40eeb38d8a2a636c70090a9">evolve_RK4</a>(double dt)</td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"></td></tr>
|
||||
<tr class="odd"><td class="entry"><a class="el" href="classPenningTrap.html#a2a3e7f480ba52e9f24d4c50c3981a784">external_B_field</a>(arma::vec r)</td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"></td></tr>
|
||||
<tr class="even"><td class="entry"><a class="el" href="classPenningTrap.html#a978a2e2026a4b5308d5184712f81704b">external_E_field</a>(arma::vec r)</td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"></td></tr>
|
||||
<tr class="odd"><td class="entry"><a class="el" href="classPenningTrap.html#a4790f41e4fbc6ede4991aa7bbda92182">force_on_particle</a>(int i, int j)</td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"></td></tr>
|
||||
<tr class="even"><td class="entry"><a class="el" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">particles</a></td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"><span class="mlabel">private</span></td></tr>
|
||||
<tr class="odd"><td class="entry"><a class="el" href="classPenningTrap.html#a81add5063bd5f29d77f0b5c299c6c560">PenningTrap</a>(double B_0=T, double V_0=25.*V/1000., double d=500.)</td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"></td></tr>
|
||||
<tr class="even"><td class="entry"><a class="el" href="classPenningTrap.html#a83cc7a04dae009ed8e75453c38fdf8be">total_force</a>(int i)</td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"></td></tr>
|
||||
<tr class="odd"><td class="entry"><a class="el" href="classPenningTrap.html#a045adb85e97a8e0c38fb36d2fd74eeee">total_force_external</a>(int i)</td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"></td></tr>
|
||||
<tr class="even"><td class="entry"><a class="el" href="classPenningTrap.html#a135db7d991d9b88b00fde4edee71f78d">total_force_particles</a>(int i)</td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"></td></tr>
|
||||
<tr class="odd"><td class="entry"><a class="el" href="classPenningTrap.html#ab9ea97a406534bbe621a95215144875e">evolve_forward_euler</a>(double dt, bool particle_interaction=true)</td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"></td></tr>
|
||||
<tr class="even"><td class="entry"><a class="el" href="classPenningTrap.html#a36946152fd951b1f7c346c51ff900d8e">evolve_RK4</a>(double dt, bool particle_interaction=true)</td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"></td></tr>
|
||||
<tr class="odd"><td class="entry"><a class="el" href="classPenningTrap.html#a361f2c4862c90b5e8e2a2f50c6a95655">external_B_field</a>(vec3 r)</td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"><span class="mlabel">private</span></td></tr>
|
||||
<tr class="even"><td class="entry"><a class="el" href="classPenningTrap.html#a5846c8f75cdc543fd9cf0b2185a3ef22">external_E_field</a>(vec3 r)</td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"><span class="mlabel">private</span></td></tr>
|
||||
<tr class="odd"><td class="entry"><a class="el" href="classPenningTrap.html#a7f210bb2768a5d79ced4b0df0df97598">force_on_particle</a>(uint i, uint j)</td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"><span class="mlabel">private</span></td></tr>
|
||||
<tr class="even"><td class="entry"><a class="el" href="classPenningTrap.html#ac529aa26c288f34eae184a67e6bac41f">fraction_of_particles_left</a>(double time, uint steps, std::string method="rk4", bool particle_interaction=true)</td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"></td></tr>
|
||||
<tr class="odd"><td class="entry"><a class="el" href="classPenningTrap.html#a2f168622587709b9e3c49077f0b9a640">k_r</a></td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"><span class="mlabel">private</span></td></tr>
|
||||
<tr class="even"><td class="entry"><a class="el" href="classPenningTrap.html#ae9b5afdaa5cd366e94bd294452a1eed4">k_v</a></td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"><span class="mlabel">private</span></td></tr>
|
||||
<tr class="odd"><td class="entry"><a class="el" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">particles</a></td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"><span class="mlabel">private</span></td></tr>
|
||||
<tr class="even"><td class="entry"><a class="el" href="classPenningTrap.html#a5b6c6d4636f3a6e279ccde59d4a345e8">PenningTrap</a>(double B_0=T, double V_0=(25. *V)/1000., double d=500., double t=0.)</td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"></td></tr>
|
||||
<tr class="odd"><td class="entry"><a class="el" href="classPenningTrap.html#a830be1b8cbf59664e060b6edbeaa302f">PenningTrap</a>(uint i, double B_0=T, double V_0=(25. *V)/1000., double d=500., double t=0.)</td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"></td></tr>
|
||||
<tr class="even"><td class="entry"><a class="el" href="classPenningTrap.html#addc96789dcfec07b75156e19fee82f4f">PenningTrap</a>(std::vector< Particle > particles, double B_0=T, double V_0=(25. *V)/1000., double d=500., double t=0.)</td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"></td></tr>
|
||||
<tr class="odd"><td class="entry"><a class="el" href="classPenningTrap.html#a869f032f37d0569ed16f224b4c4356ae">PenningTrapTest</a></td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"><span class="mlabel">friend</span></td></tr>
|
||||
<tr class="even"><td class="entry"><a class="el" href="classPenningTrap.html#ae915f6ad0eef1fb46530e836b6e071e5">perturbation</a></td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"><span class="mlabel">private</span></td></tr>
|
||||
<tr class="odd"><td class="entry"><a class="el" href="classPenningTrap.html#a826b7fa8e709d481eb1dee7d0c2cdc08">r_func</a>(uint i, uint j, double dt)</td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"><span class="mlabel">private</span></td></tr>
|
||||
<tr class="even"><td class="entry"><a class="el" href="classPenningTrap.html#aaee129f177657455348d0c8ae1441dea">reinitialize</a>(double f, double omega_V, double t=0.)</td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"></td></tr>
|
||||
<tr class="odd"><td class="entry"><a class="el" href="classPenningTrap.html#a9d1d8e90ca839b928aee1ad0cd4aff43">set_pertubation</a>(double f, double omega_V)</td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"></td></tr>
|
||||
<tr class="even"><td class="entry"><a class="el" href="classPenningTrap.html#a7a1d9f0528a12308de25bc30718da20a">simulate</a>(double time, uint steps, std::string method="rk4", bool particle_interaction=true)</td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"></td></tr>
|
||||
<tr class="odd"><td class="entry"><a class="el" href="classPenningTrap.html#a8ca4e21291f60fde619c14099d8c4e8e">t</a></td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"><span class="mlabel">private</span></td></tr>
|
||||
<tr class="even"><td class="entry"><a class="el" href="classPenningTrap.html#a9a301b0540078c36697880ef204afdf3">total_force</a>(uint i)</td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"><span class="mlabel">private</span></td></tr>
|
||||
<tr class="odd"><td class="entry"><a class="el" href="classPenningTrap.html#a2c01108b52c8e2a003cf9170da9e7682">total_force_external</a>(uint i)</td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"><span class="mlabel">private</span></td></tr>
|
||||
<tr class="even"><td class="entry"><a class="el" href="classPenningTrap.html#a2fe1cefbae18fa5808155ee0d2df713c">total_force_particles</a>(uint i)</td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"><span class="mlabel">private</span></td></tr>
|
||||
<tr class="odd"><td class="entry"><a class="el" href="classPenningTrap.html#a715329844d75ec4c04f8391421fb4e89">V_0</a></td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"><span class="mlabel">private</span></td></tr>
|
||||
<tr class="even"><td class="entry"><a class="el" href="classPenningTrap.html#a3c0a44e4e0a94366ff609e81fe463fa2">v_func</a>(uint i, uint j, double dt)</td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"><span class="mlabel">private</span></td></tr>
|
||||
<tr class="odd"><td class="entry"><a class="el" href="classPenningTrap.html#ad8bc4df7ab3eed53b16cfdff38e7760b">write_simulation_to_dir</a>(std::string path, double time, uint steps, std::string method="rk4", bool particle_interaction=true)</td><td class="entry"><a class="el" href="classPenningTrap.html">PenningTrap</a></td><td class="entry"></td></tr>
|
||||
</table></div><!-- contents -->
|
||||
</div><!-- doc-content -->
|
||||
<!-- start footer part -->
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -1,17 +1,31 @@
|
||||
var classPenningTrap =
|
||||
[
|
||||
[ "PenningTrap", "classPenningTrap.html#a81add5063bd5f29d77f0b5c299c6c560", null ],
|
||||
[ "PenningTrap", "classPenningTrap.html#a5b6c6d4636f3a6e279ccde59d4a345e8", null ],
|
||||
[ "PenningTrap", "classPenningTrap.html#a830be1b8cbf59664e060b6edbeaa302f", null ],
|
||||
[ "PenningTrap", "classPenningTrap.html#addc96789dcfec07b75156e19fee82f4f", null ],
|
||||
[ "add_particle", "classPenningTrap.html#a6e9776ff5b149f01080800716455d7c8", null ],
|
||||
[ "evolve_forward_euler", "classPenningTrap.html#a56544b6f4befb42984e9650cf2a40965", null ],
|
||||
[ "evolve_RK4", "classPenningTrap.html#ab891b839c40eeb38d8a2a636c70090a9", null ],
|
||||
[ "external_B_field", "classPenningTrap.html#a2a3e7f480ba52e9f24d4c50c3981a784", null ],
|
||||
[ "external_E_field", "classPenningTrap.html#a978a2e2026a4b5308d5184712f81704b", null ],
|
||||
[ "force_on_particle", "classPenningTrap.html#a4790f41e4fbc6ede4991aa7bbda92182", null ],
|
||||
[ "total_force", "classPenningTrap.html#a83cc7a04dae009ed8e75453c38fdf8be", null ],
|
||||
[ "total_force_external", "classPenningTrap.html#a045adb85e97a8e0c38fb36d2fd74eeee", null ],
|
||||
[ "total_force_particles", "classPenningTrap.html#a135db7d991d9b88b00fde4edee71f78d", null ],
|
||||
[ "evolve_forward_euler", "classPenningTrap.html#ab9ea97a406534bbe621a95215144875e", null ],
|
||||
[ "evolve_RK4", "classPenningTrap.html#a36946152fd951b1f7c346c51ff900d8e", null ],
|
||||
[ "external_B_field", "classPenningTrap.html#a361f2c4862c90b5e8e2a2f50c6a95655", null ],
|
||||
[ "external_E_field", "classPenningTrap.html#a5846c8f75cdc543fd9cf0b2185a3ef22", null ],
|
||||
[ "force_on_particle", "classPenningTrap.html#a7f210bb2768a5d79ced4b0df0df97598", null ],
|
||||
[ "fraction_of_particles_left", "classPenningTrap.html#ac529aa26c288f34eae184a67e6bac41f", null ],
|
||||
[ "r_func", "classPenningTrap.html#a826b7fa8e709d481eb1dee7d0c2cdc08", null ],
|
||||
[ "reinitialize", "classPenningTrap.html#aaee129f177657455348d0c8ae1441dea", null ],
|
||||
[ "set_pertubation", "classPenningTrap.html#a9d1d8e90ca839b928aee1ad0cd4aff43", null ],
|
||||
[ "simulate", "classPenningTrap.html#a7a1d9f0528a12308de25bc30718da20a", null ],
|
||||
[ "total_force", "classPenningTrap.html#a9a301b0540078c36697880ef204afdf3", null ],
|
||||
[ "total_force_external", "classPenningTrap.html#a2c01108b52c8e2a003cf9170da9e7682", null ],
|
||||
[ "total_force_particles", "classPenningTrap.html#a2fe1cefbae18fa5808155ee0d2df713c", null ],
|
||||
[ "v_func", "classPenningTrap.html#a3c0a44e4e0a94366ff609e81fe463fa2", null ],
|
||||
[ "write_simulation_to_dir", "classPenningTrap.html#ad8bc4df7ab3eed53b16cfdff38e7760b", null ],
|
||||
[ "PenningTrapTest", "classPenningTrap.html#a869f032f37d0569ed16f224b4c4356ae", null ],
|
||||
[ "B_0", "classPenningTrap.html#a0cac3509aa96e71a26d3b2c902e27716", null ],
|
||||
[ "d", "classPenningTrap.html#a66dfe89c68716b9502927b97f59c27d2", null ],
|
||||
[ "k_r", "classPenningTrap.html#a2f168622587709b9e3c49077f0b9a640", null ],
|
||||
[ "k_v", "classPenningTrap.html#ae9b5afdaa5cd366e94bd294452a1eed4", null ],
|
||||
[ "particles", "classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f", null ],
|
||||
[ "perturbation", "classPenningTrap.html#ae915f6ad0eef1fb46530e836b6e071e5", null ],
|
||||
[ "t", "classPenningTrap.html#a8ca4e21291f60fde619c14099d8c4e8e", null ],
|
||||
[ "V_0", "classPenningTrap.html#a715329844d75ec4c04f8391421fb4e89", null ]
|
||||
];
|
||||
121
docs/classPenningTrapTest-members.html
Normal file
121
docs/classPenningTrapTest-members.html
Normal file
@@ -0,0 +1,121 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=11"/>
|
||||
<meta name="generator" content="Doxygen 1.9.6"/>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1"/>
|
||||
<title>Penning Trap Simulation: Member List</title>
|
||||
<link href="tabs.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="jquery.js"></script>
|
||||
<script type="text/javascript" src="dynsections.js"></script>
|
||||
<link href="navtree.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="resize.js"></script>
|
||||
<script type="text/javascript" src="navtreedata.js"></script>
|
||||
<script type="text/javascript" src="navtree.js"></script>
|
||||
<link href="search/search.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="search/searchdata.js"></script>
|
||||
<script type="text/javascript" src="search/search.js"></script>
|
||||
<script type="text/x-mathjax-config">
|
||||
MathJax.Hub.Config({
|
||||
extensions: ["tex2jax.js"],
|
||||
jax: ["input/TeX","output/HTML-CSS"],
|
||||
});
|
||||
</script>
|
||||
<script type="text/javascript" async="async" src="https://cdn.jsdelivr.net/npm/mathjax@2/MathJax.js"></script>
|
||||
<link href="doxygen.css" rel="stylesheet" type="text/css" />
|
||||
<link href="doxygen-awesome.css" rel="stylesheet" type="text/css"/>
|
||||
</head>
|
||||
<body>
|
||||
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
|
||||
<div id="titlearea">
|
||||
<table cellspacing="0" cellpadding="0">
|
||||
<tbody>
|
||||
<tr id="projectrow">
|
||||
<td id="projectalign">
|
||||
<div id="projectname">Penning Trap Simulation
|
||||
</div>
|
||||
<div id="projectbrief">Simulate particle behavior inside a Penning Trap</div>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
<!-- end header part -->
|
||||
<!-- Generated by Doxygen 1.9.6 -->
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
||||
var searchBox = new SearchBox("searchBox", "search/",'.html');
|
||||
/* @license-end */
|
||||
</script>
|
||||
<script type="text/javascript" src="menudata.js"></script>
|
||||
<script type="text/javascript" src="menu.js"></script>
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
||||
$(function() {
|
||||
initMenu('',true,false,'search.php','Search');
|
||||
$(document).ready(function() { init_search(); });
|
||||
});
|
||||
/* @license-end */
|
||||
</script>
|
||||
<div id="main-nav"></div>
|
||||
</div><!-- top -->
|
||||
<div id="side-nav" class="ui-resizable side-nav-resizable">
|
||||
<div id="nav-tree">
|
||||
<div id="nav-tree-contents">
|
||||
<div id="nav-sync" class="sync"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="splitbar" style="-moz-user-select:none;"
|
||||
class="ui-resizable-handle">
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
||||
$(document).ready(function(){initNavTree('classPenningTrapTest.html',''); initResizable(); });
|
||||
/* @license-end */
|
||||
</script>
|
||||
<div id="doc-content">
|
||||
<!-- window showing the filter options -->
|
||||
<div id="MSearchSelectWindow"
|
||||
onmouseover="return searchBox.OnSearchSelectShow()"
|
||||
onmouseout="return searchBox.OnSearchSelectHide()"
|
||||
onkeydown="return searchBox.OnSearchSelectKey(event)">
|
||||
</div>
|
||||
|
||||
<!-- iframe showing the search results (closed by default) -->
|
||||
<div id="MSearchResultsWindow">
|
||||
<div id="MSearchResults">
|
||||
<div class="SRPage">
|
||||
<div id="SRIndex">
|
||||
<div id="SRResults"></div>
|
||||
<div class="SRStatus" id="Loading">Loading...</div>
|
||||
<div class="SRStatus" id="Searching">Searching...</div>
|
||||
<div class="SRStatus" id="NoMatches">No Matches</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="header">
|
||||
<div class="headertitle"><div class="title">PenningTrapTest Member List</div></div>
|
||||
</div><!--header-->
|
||||
<div class="contents">
|
||||
|
||||
<p>This is the complete list of members for <a class="el" href="classPenningTrapTest.html">PenningTrapTest</a>, including all inherited members.</p>
|
||||
<table class="directory">
|
||||
<tr class="even"><td class="entry"><a class="el" href="classPenningTrapTest.html#ad668d7d875bdc1909a42426bf9dead9e">test_external_B_field</a>()</td><td class="entry"><a class="el" href="classPenningTrapTest.html">PenningTrapTest</a></td><td class="entry"><span class="mlabel">inline</span></td></tr>
|
||||
<tr class="odd"><td class="entry"><a class="el" href="classPenningTrapTest.html#a6a303be62039ca2ecccd8252744d4dc8">test_external_E_field</a>()</td><td class="entry"><a class="el" href="classPenningTrapTest.html">PenningTrapTest</a></td><td class="entry"><span class="mlabel">inline</span></td></tr>
|
||||
<tr class="even"><td class="entry"><a class="el" href="classPenningTrapTest.html#a5f4f0b150e54ce463bb29f76d49883f9">test_force_on_particle</a>()</td><td class="entry"><a class="el" href="classPenningTrapTest.html">PenningTrapTest</a></td><td class="entry"><span class="mlabel">inline</span></td></tr>
|
||||
<tr class="odd"><td class="entry"><a class="el" href="classPenningTrapTest.html#ae6d0c8e0d80338fb7c7edefc97331046">test_total_force_external</a>()</td><td class="entry"><a class="el" href="classPenningTrapTest.html">PenningTrapTest</a></td><td class="entry"><span class="mlabel">inline</span></td></tr>
|
||||
<tr class="even"><td class="entry"><a class="el" href="classPenningTrapTest.html#a68449d508e66205bc8b27fa5f60db508">test_total_force_particles</a>()</td><td class="entry"><a class="el" href="classPenningTrapTest.html">PenningTrapTest</a></td><td class="entry"><span class="mlabel">inline</span></td></tr>
|
||||
</table></div><!-- contents -->
|
||||
</div><!-- doc-content -->
|
||||
<!-- start footer part -->
|
||||
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
|
||||
<ul>
|
||||
<li class="footer">Generated by <a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.9.6 </li>
|
||||
</ul>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
292
docs/classPenningTrapTest.html
Normal file
292
docs/classPenningTrapTest.html
Normal file
@@ -0,0 +1,292 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=11"/>
|
||||
<meta name="generator" content="Doxygen 1.9.6"/>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1"/>
|
||||
<title>Penning Trap Simulation: PenningTrapTest Class Reference</title>
|
||||
<link href="tabs.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="jquery.js"></script>
|
||||
<script type="text/javascript" src="dynsections.js"></script>
|
||||
<link href="navtree.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="resize.js"></script>
|
||||
<script type="text/javascript" src="navtreedata.js"></script>
|
||||
<script type="text/javascript" src="navtree.js"></script>
|
||||
<link href="search/search.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="search/searchdata.js"></script>
|
||||
<script type="text/javascript" src="search/search.js"></script>
|
||||
<script type="text/x-mathjax-config">
|
||||
MathJax.Hub.Config({
|
||||
extensions: ["tex2jax.js"],
|
||||
jax: ["input/TeX","output/HTML-CSS"],
|
||||
});
|
||||
</script>
|
||||
<script type="text/javascript" async="async" src="https://cdn.jsdelivr.net/npm/mathjax@2/MathJax.js"></script>
|
||||
<link href="doxygen.css" rel="stylesheet" type="text/css" />
|
||||
<link href="doxygen-awesome.css" rel="stylesheet" type="text/css"/>
|
||||
</head>
|
||||
<body>
|
||||
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
|
||||
<div id="titlearea">
|
||||
<table cellspacing="0" cellpadding="0">
|
||||
<tbody>
|
||||
<tr id="projectrow">
|
||||
<td id="projectalign">
|
||||
<div id="projectname">Penning Trap Simulation
|
||||
</div>
|
||||
<div id="projectbrief">Simulate particle behavior inside a Penning Trap</div>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
<!-- end header part -->
|
||||
<!-- Generated by Doxygen 1.9.6 -->
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
||||
var searchBox = new SearchBox("searchBox", "search/",'.html');
|
||||
/* @license-end */
|
||||
</script>
|
||||
<script type="text/javascript" src="menudata.js"></script>
|
||||
<script type="text/javascript" src="menu.js"></script>
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
||||
$(function() {
|
||||
initMenu('',true,false,'search.php','Search');
|
||||
$(document).ready(function() { init_search(); });
|
||||
});
|
||||
/* @license-end */
|
||||
</script>
|
||||
<div id="main-nav"></div>
|
||||
</div><!-- top -->
|
||||
<div id="side-nav" class="ui-resizable side-nav-resizable">
|
||||
<div id="nav-tree">
|
||||
<div id="nav-tree-contents">
|
||||
<div id="nav-sync" class="sync"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="splitbar" style="-moz-user-select:none;"
|
||||
class="ui-resizable-handle">
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
||||
$(document).ready(function(){initNavTree('classPenningTrapTest.html',''); initResizable(); });
|
||||
/* @license-end */
|
||||
</script>
|
||||
<div id="doc-content">
|
||||
<!-- window showing the filter options -->
|
||||
<div id="MSearchSelectWindow"
|
||||
onmouseover="return searchBox.OnSearchSelectShow()"
|
||||
onmouseout="return searchBox.OnSearchSelectHide()"
|
||||
onkeydown="return searchBox.OnSearchSelectKey(event)">
|
||||
</div>
|
||||
|
||||
<!-- iframe showing the search results (closed by default) -->
|
||||
<div id="MSearchResultsWindow">
|
||||
<div id="MSearchResults">
|
||||
<div class="SRPage">
|
||||
<div id="SRIndex">
|
||||
<div id="SRResults"></div>
|
||||
<div class="SRStatus" id="Loading">Loading...</div>
|
||||
<div class="SRStatus" id="Searching">Searching...</div>
|
||||
<div class="SRStatus" id="NoMatches">No Matches</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="header">
|
||||
<div class="summary">
|
||||
<a href="#pub-methods">Public Member Functions</a> |
|
||||
<a href="classPenningTrapTest-members.html">List of all members</a> </div>
|
||||
<div class="headertitle"><div class="title">PenningTrapTest Class Reference</div></div>
|
||||
</div><!--header-->
|
||||
<div class="contents">
|
||||
|
||||
<p>Test class for the Penning trap.
|
||||
<a href="classPenningTrapTest.html#details">More...</a></p>
|
||||
<table class="memberdecls">
|
||||
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="pub-methods" name="pub-methods"></a>
|
||||
Public Member Functions</h2></td></tr>
|
||||
<tr class="memitem:a6a303be62039ca2ecccd8252744d4dc8"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classPenningTrapTest.html#a6a303be62039ca2ecccd8252744d4dc8">test_external_E_field</a> ()</td></tr>
|
||||
<tr class="memdesc:a6a303be62039ca2ecccd8252744d4dc8"><td class="mdescLeft"> </td><td class="mdescRight">Test that the external E field gives correct values. <br /></td></tr>
|
||||
<tr class="separator:a6a303be62039ca2ecccd8252744d4dc8"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:ad668d7d875bdc1909a42426bf9dead9e"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classPenningTrapTest.html#ad668d7d875bdc1909a42426bf9dead9e">test_external_B_field</a> ()</td></tr>
|
||||
<tr class="memdesc:ad668d7d875bdc1909a42426bf9dead9e"><td class="mdescLeft"> </td><td class="mdescRight">Test that the external B field gives correct values. <br /></td></tr>
|
||||
<tr class="separator:ad668d7d875bdc1909a42426bf9dead9e"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:a5f4f0b150e54ce463bb29f76d49883f9"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classPenningTrapTest.html#a5f4f0b150e54ce463bb29f76d49883f9">test_force_on_particle</a> ()</td></tr>
|
||||
<tr class="memdesc:a5f4f0b150e54ce463bb29f76d49883f9"><td class="mdescLeft"> </td><td class="mdescRight">Test that the force between particles gives expected results. <br /></td></tr>
|
||||
<tr class="separator:a5f4f0b150e54ce463bb29f76d49883f9"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:ae6d0c8e0d80338fb7c7edefc97331046"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classPenningTrapTest.html#ae6d0c8e0d80338fb7c7edefc97331046">test_total_force_external</a> ()</td></tr>
|
||||
<tr class="memdesc:ae6d0c8e0d80338fb7c7edefc97331046"><td class="mdescLeft"> </td><td class="mdescRight">Test that the total external force returns expected results. <br /></td></tr>
|
||||
<tr class="separator:ae6d0c8e0d80338fb7c7edefc97331046"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:a68449d508e66205bc8b27fa5f60db508"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classPenningTrapTest.html#a68449d508e66205bc8b27fa5f60db508">test_total_force_particles</a> ()</td></tr>
|
||||
<tr class="memdesc:a68449d508e66205bc8b27fa5f60db508"><td class="mdescLeft"> </td><td class="mdescRight">Test that the total force of all particles on a single particle returns expected results. <br /></td></tr>
|
||||
<tr class="separator:a68449d508e66205bc8b27fa5f60db508"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
</table>
|
||||
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
|
||||
<div class="textblock"><p>Test class for the Penning trap. </p>
|
||||
|
||||
<p class="definition">Definition at line <a class="el" href="test__suite_8cpp_source.html#l00023">23</a> of file <a class="el" href="test__suite_8cpp_source.html">test_suite.cpp</a>.</p>
|
||||
</div><h2 class="groupheader">Member Function Documentation</h2>
|
||||
<a id="ad668d7d875bdc1909a42426bf9dead9e" name="ad668d7d875bdc1909a42426bf9dead9e"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#ad668d7d875bdc1909a42426bf9dead9e">◆ </a></span>test_external_B_field()</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
<table class="mlabels">
|
||||
<tr>
|
||||
<td class="mlabels-left">
|
||||
<table class="memname">
|
||||
<tr>
|
||||
<td class="memname">void PenningTrapTest::test_external_B_field </td>
|
||||
<td>(</td>
|
||||
<td class="paramname"></td><td>)</td>
|
||||
<td></td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
<td class="mlabels-right">
|
||||
<span class="mlabels"><span class="mlabel">inline</span></span> </td>
|
||||
</tr>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
|
||||
<p>Test that the external B field gives correct values. </p>
|
||||
|
||||
<p class="definition">Definition at line <a class="el" href="test__suite_8cpp_source.html#l00066">66</a> of file <a class="el" href="test__suite_8cpp_source.html">test_suite.cpp</a>.</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<a id="a6a303be62039ca2ecccd8252744d4dc8" name="a6a303be62039ca2ecccd8252744d4dc8"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#a6a303be62039ca2ecccd8252744d4dc8">◆ </a></span>test_external_E_field()</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
<table class="mlabels">
|
||||
<tr>
|
||||
<td class="mlabels-left">
|
||||
<table class="memname">
|
||||
<tr>
|
||||
<td class="memname">void PenningTrapTest::test_external_E_field </td>
|
||||
<td>(</td>
|
||||
<td class="paramname"></td><td>)</td>
|
||||
<td></td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
<td class="mlabels-right">
|
||||
<span class="mlabels"><span class="mlabel">inline</span></span> </td>
|
||||
</tr>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
|
||||
<p>Test that the external E field gives correct values. </p>
|
||||
|
||||
<p class="definition">Definition at line <a class="el" href="test__suite_8cpp_source.html#l00028">28</a> of file <a class="el" href="test__suite_8cpp_source.html">test_suite.cpp</a>.</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<a id="a5f4f0b150e54ce463bb29f76d49883f9" name="a5f4f0b150e54ce463bb29f76d49883f9"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#a5f4f0b150e54ce463bb29f76d49883f9">◆ </a></span>test_force_on_particle()</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
<table class="mlabels">
|
||||
<tr>
|
||||
<td class="mlabels-left">
|
||||
<table class="memname">
|
||||
<tr>
|
||||
<td class="memname">void PenningTrapTest::test_force_on_particle </td>
|
||||
<td>(</td>
|
||||
<td class="paramname"></td><td>)</td>
|
||||
<td></td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
<td class="mlabels-right">
|
||||
<span class="mlabels"><span class="mlabel">inline</span></span> </td>
|
||||
</tr>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
|
||||
<p>Test that the force between particles gives expected results. </p>
|
||||
|
||||
<p class="definition">Definition at line <a class="el" href="test__suite_8cpp_source.html#l00080">80</a> of file <a class="el" href="test__suite_8cpp_source.html">test_suite.cpp</a>.</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<a id="ae6d0c8e0d80338fb7c7edefc97331046" name="ae6d0c8e0d80338fb7c7edefc97331046"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#ae6d0c8e0d80338fb7c7edefc97331046">◆ </a></span>test_total_force_external()</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
<table class="mlabels">
|
||||
<tr>
|
||||
<td class="mlabels-left">
|
||||
<table class="memname">
|
||||
<tr>
|
||||
<td class="memname">void PenningTrapTest::test_total_force_external </td>
|
||||
<td>(</td>
|
||||
<td class="paramname"></td><td>)</td>
|
||||
<td></td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
<td class="mlabels-right">
|
||||
<span class="mlabels"><span class="mlabel">inline</span></span> </td>
|
||||
</tr>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
|
||||
<p>Test that the total external force returns expected results. </p>
|
||||
|
||||
<p class="definition">Definition at line <a class="el" href="test__suite_8cpp_source.html#l00107">107</a> of file <a class="el" href="test__suite_8cpp_source.html">test_suite.cpp</a>.</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<a id="a68449d508e66205bc8b27fa5f60db508" name="a68449d508e66205bc8b27fa5f60db508"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#a68449d508e66205bc8b27fa5f60db508">◆ </a></span>test_total_force_particles()</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
<table class="mlabels">
|
||||
<tr>
|
||||
<td class="mlabels-left">
|
||||
<table class="memname">
|
||||
<tr>
|
||||
<td class="memname">void PenningTrapTest::test_total_force_particles </td>
|
||||
<td>(</td>
|
||||
<td class="paramname"></td><td>)</td>
|
||||
<td></td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
<td class="mlabels-right">
|
||||
<span class="mlabels"><span class="mlabel">inline</span></span> </td>
|
||||
</tr>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
|
||||
<p>Test that the total force of all particles on a single particle returns expected results. </p>
|
||||
|
||||
<p class="definition">Definition at line <a class="el" href="test__suite_8cpp_source.html#l00122">122</a> of file <a class="el" href="test__suite_8cpp_source.html">test_suite.cpp</a>.</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<hr/>The documentation for this class was generated from the following file:<ul>
|
||||
<li>src/<a class="el" href="test__suite_8cpp_source.html">test_suite.cpp</a></li>
|
||||
</ul>
|
||||
</div><!-- contents -->
|
||||
</div><!-- doc-content -->
|
||||
<!-- start footer part -->
|
||||
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
|
||||
<ul>
|
||||
<li class="navelem"><a class="el" href="classPenningTrapTest.html">PenningTrapTest</a></li>
|
||||
<li class="footer">Generated by <a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.9.6 </li>
|
||||
</ul>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
8
docs/classPenningTrapTest.js
Normal file
8
docs/classPenningTrapTest.js
Normal file
@@ -0,0 +1,8 @@
|
||||
var classPenningTrapTest =
|
||||
[
|
||||
[ "test_external_B_field", "classPenningTrapTest.html#ad668d7d875bdc1909a42426bf9dead9e", null ],
|
||||
[ "test_external_E_field", "classPenningTrapTest.html#a6a303be62039ca2ecccd8252744d4dc8", null ],
|
||||
[ "test_force_on_particle", "classPenningTrapTest.html#a5f4f0b150e54ce463bb29f76d49883f9", null ],
|
||||
[ "test_total_force_external", "classPenningTrapTest.html#ae6d0c8e0d80338fb7c7edefc97331046", null ],
|
||||
[ "test_total_force_particles", "classPenningTrapTest.html#a68449d508e66205bc8b27fa5f60db508", null ]
|
||||
];
|
||||
@@ -101,11 +101,14 @@ $(document).ready(function(){initNavTree('classes.html',''); initResizable(); })
|
||||
<div class="headertitle"><div class="title">Class Index</div></div>
|
||||
</div><!--header-->
|
||||
<div class="contents">
|
||||
<div class="qindex"><a class="qindex" href="#letter_P">P</a></div>
|
||||
<div class="qindex"><a class="qindex" href="#letter_P">P</a> | <a class="qindex" href="#letter_S">S</a></div>
|
||||
<div class="classindex">
|
||||
<dl class="classindex even">
|
||||
<dt class="alphachar"><a id="letter_P" name="letter_P">P</a></dt>
|
||||
<dd><a class="el" href="classParticle.html">Particle</a></dd><dd><a class="el" href="classPenningTrap.html">PenningTrap</a></dd></dl>
|
||||
<dd><a class="el" href="classParticle.html">Particle</a></dd><dd><a class="el" href="classPenningTrap.html">PenningTrap</a></dd><dd><a class="el" href="classPenningTrapTest.html">PenningTrapTest</a></dd></dl>
|
||||
<dl class="classindex odd">
|
||||
<dt class="alphachar"><a id="letter_S" name="letter_S">S</a></dt>
|
||||
<dd><a class="el" href="structsimulation.html">simulation</a></dd></dl>
|
||||
</div>
|
||||
</div><!-- contents -->
|
||||
</div><!-- doc-content -->
|
||||
|
||||
@@ -111,26 +111,68 @@ $(document).ready(function(){initNavTree('constants_8hpp.html',''); initResizabl
|
||||
<table class="memberdecls">
|
||||
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="define-members" name="define-members"></a>
|
||||
Macros</h2></td></tr>
|
||||
<tr class="memitem:a4e451456ad7e9276ed0afa42826e7ccb"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="constants_8hpp.html#a4e451456ad7e9276ed0afa42826e7ccb">K_E</a>   138935.333</td></tr>
|
||||
<tr class="memitem:a4e451456ad7e9276ed0afa42826e7ccb"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="constants_8hpp.html#a4e451456ad7e9276ed0afa42826e7ccb">K_E</a>   1.38935333 * 1e5</td></tr>
|
||||
<tr class="memdesc:a4e451456ad7e9276ed0afa42826e7ccb"><td class="mdescLeft"> </td><td class="mdescRight">Coulomb constant. unit: \(\frac{u(\mu m)^3}{(\mu s)^2 e^2}\). <br /></td></tr>
|
||||
<tr class="separator:a4e451456ad7e9276ed0afa42826e7ccb"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:a0acb682b8260ab1c60b918599864e2e5"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="constants_8hpp.html#a0acb682b8260ab1c60b918599864e2e5">T</a>   96.4852558</td></tr>
|
||||
<tr class="memitem:a0acb682b8260ab1c60b918599864e2e5"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="constants_8hpp.html#a0acb682b8260ab1c60b918599864e2e5">T</a>   9.64852558 * 1e1</td></tr>
|
||||
<tr class="memdesc:a0acb682b8260ab1c60b918599864e2e5"><td class="mdescLeft"> </td><td class="mdescRight">1 Tesla. unit: \( \frac{u}{(\mu s) e} \) <br /></td></tr>
|
||||
<tr class="separator:a0acb682b8260ab1c60b918599864e2e5"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:af40a326b23c68a27cebe60f16634a2cb"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="constants_8hpp.html#af40a326b23c68a27cebe60f16634a2cb">V</a>   96485255.8</td></tr>
|
||||
<tr class="memitem:af40a326b23c68a27cebe60f16634a2cb"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="constants_8hpp.html#af40a326b23c68a27cebe60f16634a2cb">V</a>   9.64852558 * 1e7</td></tr>
|
||||
<tr class="memdesc:af40a326b23c68a27cebe60f16634a2cb"><td class="mdescLeft"> </td><td class="mdescRight">1 Volt. unit: \( \frac{u (\mu m)^2}{(\mu s)^2 e} \) <br /></td></tr>
|
||||
<tr class="separator:af40a326b23c68a27cebe60f16634a2cb"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:a2ff491cc7958ffd5e749c518a4a60ec8"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="constants_8hpp.html#a2ff491cc7958ffd5e749c518a4a60ec8">CA_MASS</a>   40.078</td></tr>
|
||||
<tr class="memdesc:a2ff491cc7958ffd5e749c518a4a60ec8"><td class="mdescLeft"> </td><td class="mdescRight">Mass of a single calcium ion. unit: amu. <br /></td></tr>
|
||||
<tr class="separator:a2ff491cc7958ffd5e749c518a4a60ec8"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:af7602a3a314957137ad1cd719aa23789"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="constants_8hpp.html#af7602a3a314957137ad1cd719aa23789">CA_CHARGE</a>   1.</td></tr>
|
||||
<tr class="memdesc:af7602a3a314957137ad1cd719aa23789"><td class="mdescLeft"> </td><td class="mdescRight">Charge of a singly charged calcium ion. unit: e. <br /></td></tr>
|
||||
<tr class="separator:af7602a3a314957137ad1cd719aa23789"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
</table>
|
||||
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
|
||||
<div class="textblock"><p>Library of constants. </p>
|
||||
<dl class="section author"><dt>Author</dt><dd>Cory Alexander Balaton (coryab) </dd>
|
||||
<dd>
|
||||
Janita Ovidie Sandtrøen Willumsen (janitaws)</dd></dl>
|
||||
<dl class="section version"><dt>Version</dt><dd>0.1</dd></dl>
|
||||
<dl class="section version"><dt>Version</dt><dd>1.0</dd></dl>
|
||||
<dl class="bug"><dt><b><a class="el" href="bug.html#_bug000001">Bug:</a></b></dt><dd>No known bugs </dd></dl>
|
||||
|
||||
<p class="definition">Definition in file <a class="el" href="constants_8hpp_source.html">constants.hpp</a>.</p>
|
||||
</div><h2 class="groupheader">Macro Definition Documentation</h2>
|
||||
<a id="af7602a3a314957137ad1cd719aa23789" name="af7602a3a314957137ad1cd719aa23789"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#af7602a3a314957137ad1cd719aa23789">◆ </a></span>CA_CHARGE</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
<table class="memname">
|
||||
<tr>
|
||||
<td class="memname">#define CA_CHARGE   1.</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
|
||||
<p>Charge of a singly charged calcium ion. unit: e. </p>
|
||||
|
||||
<p class="definition">Definition at line <a class="el" href="constants_8hpp_source.html#l00033">33</a> of file <a class="el" href="constants_8hpp_source.html">constants.hpp</a>.</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<a id="a2ff491cc7958ffd5e749c518a4a60ec8" name="a2ff491cc7958ffd5e749c518a4a60ec8"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#a2ff491cc7958ffd5e749c518a4a60ec8">◆ </a></span>CA_MASS</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
<table class="memname">
|
||||
<tr>
|
||||
<td class="memname">#define CA_MASS   40.078</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
|
||||
<p>Mass of a single calcium ion. unit: amu. </p>
|
||||
|
||||
<p class="definition">Definition at line <a class="el" href="constants_8hpp_source.html#l00029">29</a> of file <a class="el" href="constants_8hpp_source.html">constants.hpp</a>.</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<a id="a4e451456ad7e9276ed0afa42826e7ccb" name="a4e451456ad7e9276ed0afa42826e7ccb"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#a4e451456ad7e9276ed0afa42826e7ccb">◆ </a></span>K_E</h2>
|
||||
|
||||
@@ -138,14 +180,14 @@ Janita Ovidie Sandtrøen Willumsen (janitaws)</dd></dl>
|
||||
<div class="memproto">
|
||||
<table class="memname">
|
||||
<tr>
|
||||
<td class="memname">#define K_E   138935.333</td>
|
||||
<td class="memname">#define K_E   1.38935333 * 1e5</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
|
||||
<p>Coulomb constant. unit: \(\frac{u(\mu m)^3}{(\mu s)^2 e^2}\). </p>
|
||||
|
||||
<p class="definition">Definition at line <a class="el" href="constants_8hpp_source.html#l00015">15</a> of file <a class="el" href="constants_8hpp_source.html">constants.hpp</a>.</p>
|
||||
<p class="definition">Definition at line <a class="el" href="constants_8hpp_source.html#l00017">17</a> of file <a class="el" href="constants_8hpp_source.html">constants.hpp</a>.</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
@@ -156,14 +198,14 @@ Janita Ovidie Sandtrøen Willumsen (janitaws)</dd></dl>
|
||||
<div class="memproto">
|
||||
<table class="memname">
|
||||
<tr>
|
||||
<td class="memname">#define T   96.4852558</td>
|
||||
<td class="memname">#define T   9.64852558 * 1e1</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
|
||||
<p>1 Tesla. unit: \( \frac{u}{(\mu s) e} \) </p>
|
||||
|
||||
<p class="definition">Definition at line <a class="el" href="constants_8hpp_source.html#l00017">17</a> of file <a class="el" href="constants_8hpp_source.html">constants.hpp</a>.</p>
|
||||
<p class="definition">Definition at line <a class="el" href="constants_8hpp_source.html#l00021">21</a> of file <a class="el" href="constants_8hpp_source.html">constants.hpp</a>.</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
@@ -174,14 +216,14 @@ Janita Ovidie Sandtrøen Willumsen (janitaws)</dd></dl>
|
||||
<div class="memproto">
|
||||
<table class="memname">
|
||||
<tr>
|
||||
<td class="memname">#define V   96485255.8</td>
|
||||
<td class="memname">#define V   9.64852558 * 1e7</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
|
||||
<p>1 Volt. unit: \( \frac{u (\mu m)^2}{(\mu s)^2 e} \) </p>
|
||||
|
||||
<p class="definition">Definition at line <a class="el" href="constants_8hpp_source.html#l00019">19</a> of file <a class="el" href="constants_8hpp_source.html">constants.hpp</a>.</p>
|
||||
<p class="definition">Definition at line <a class="el" href="constants_8hpp_source.html#l00025">25</a> of file <a class="el" href="constants_8hpp_source.html">constants.hpp</a>.</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
var constants_8hpp =
|
||||
[
|
||||
[ "CA_CHARGE", "constants_8hpp.html#af7602a3a314957137ad1cd719aa23789", null ],
|
||||
[ "CA_MASS", "constants_8hpp.html#a2ff491cc7958ffd5e749c518a4a60ec8", null ],
|
||||
[ "K_E", "constants_8hpp.html#a4e451456ad7e9276ed0afa42826e7ccb", null ],
|
||||
[ "T", "constants_8hpp.html#a0acb682b8260ab1c60b918599864e2e5", null ],
|
||||
[ "V", "constants_8hpp.html#af40a326b23c68a27cebe60f16634a2cb", null ]
|
||||
|
||||
@@ -105,13 +105,17 @@ $(document).ready(function(){initNavTree('constants_8hpp_source.html',''); initR
|
||||
<div class="line"><a id="l00012" name="l00012"></a><span class="lineno"> 12</span><span class="preprocessor">#ifndef __CONST__</span></div>
|
||||
<div class="line"><a id="l00013" name="l00013"></a><span class="lineno"> 13</span><span class="preprocessor">#define __CONST__</span></div>
|
||||
<div class="line"><a id="l00014" name="l00014"></a><span class="lineno"> 14</span> </div>
|
||||
<div class="line"><a id="l00015" name="l00015"></a><span class="lineno"><a class="line" href="constants_8hpp.html#a4e451456ad7e9276ed0afa42826e7ccb"> 15</a></span><span class="preprocessor">#define K_E 138935.333 </span></div>
|
||||
<div class="line"><a id="l00016" name="l00016"></a><span class="lineno"> 16</span> </div>
|
||||
<div class="line"><a id="l00017" name="l00017"></a><span class="lineno"><a class="line" href="constants_8hpp.html#a0acb682b8260ab1c60b918599864e2e5"> 17</a></span><span class="preprocessor">#define T 96.4852558 </span></div>
|
||||
<div class="line"><a id="l00017" name="l00017"></a><span class="lineno"><a class="line" href="constants_8hpp.html#a4e451456ad7e9276ed0afa42826e7ccb"> 17</a></span><span class="preprocessor">#define K_E 1.38935333 * 1e5</span></div>
|
||||
<div class="line"><a id="l00018" name="l00018"></a><span class="lineno"> 18</span> </div>
|
||||
<div class="line"><a id="l00019" name="l00019"></a><span class="lineno"><a class="line" href="constants_8hpp.html#af40a326b23c68a27cebe60f16634a2cb"> 19</a></span><span class="preprocessor">#define V 96485255.8 </span></div>
|
||||
<div class="line"><a id="l00020" name="l00020"></a><span class="lineno"> 20</span> </div>
|
||||
<div class="line"><a id="l00021" name="l00021"></a><span class="lineno"> 21</span><span class="preprocessor">#endif</span></div>
|
||||
<div class="line"><a id="l00021" name="l00021"></a><span class="lineno"><a class="line" href="constants_8hpp.html#a0acb682b8260ab1c60b918599864e2e5"> 21</a></span><span class="preprocessor">#define T 9.64852558 * 1e1</span></div>
|
||||
<div class="line"><a id="l00022" name="l00022"></a><span class="lineno"> 22</span> </div>
|
||||
<div class="line"><a id="l00025" name="l00025"></a><span class="lineno"><a class="line" href="constants_8hpp.html#af40a326b23c68a27cebe60f16634a2cb"> 25</a></span><span class="preprocessor">#define V 9.64852558 * 1e7</span></div>
|
||||
<div class="line"><a id="l00026" name="l00026"></a><span class="lineno"> 26</span> </div>
|
||||
<div class="line"><a id="l00029" name="l00029"></a><span class="lineno"><a class="line" href="constants_8hpp.html#a2ff491cc7958ffd5e749c518a4a60ec8"> 29</a></span><span class="preprocessor">#define CA_MASS 40.078</span></div>
|
||||
<div class="line"><a id="l00030" name="l00030"></a><span class="lineno"> 30</span> </div>
|
||||
<div class="line"><a id="l00033" name="l00033"></a><span class="lineno"><a class="line" href="constants_8hpp.html#af7602a3a314957137ad1cd719aa23789"> 33</a></span><span class="preprocessor">#define CA_CHARGE 1.</span></div>
|
||||
<div class="line"><a id="l00034" name="l00034"></a><span class="lineno"> 34</span> </div>
|
||||
<div class="line"><a id="l00035" name="l00035"></a><span class="lineno"> 35</span><span class="preprocessor">#endif</span></div>
|
||||
</div><!-- fragment --></div><!-- contents -->
|
||||
</div><!-- doc-content -->
|
||||
<!-- start footer part -->
|
||||
|
||||
132
docs/dir_634e799a3947388232110823971192a8.html
Normal file
132
docs/dir_634e799a3947388232110823971192a8.html
Normal file
@@ -0,0 +1,132 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=11"/>
|
||||
<meta name="generator" content="Doxygen 1.9.6"/>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1"/>
|
||||
<title>Penning Trap Simulation: src/scripts Directory Reference</title>
|
||||
<link href="tabs.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="jquery.js"></script>
|
||||
<script type="text/javascript" src="dynsections.js"></script>
|
||||
<link href="navtree.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="resize.js"></script>
|
||||
<script type="text/javascript" src="navtreedata.js"></script>
|
||||
<script type="text/javascript" src="navtree.js"></script>
|
||||
<link href="search/search.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="search/searchdata.js"></script>
|
||||
<script type="text/javascript" src="search/search.js"></script>
|
||||
<script type="text/x-mathjax-config">
|
||||
MathJax.Hub.Config({
|
||||
extensions: ["tex2jax.js"],
|
||||
jax: ["input/TeX","output/HTML-CSS"],
|
||||
});
|
||||
</script>
|
||||
<script type="text/javascript" async="async" src="https://cdn.jsdelivr.net/npm/mathjax@2/MathJax.js"></script>
|
||||
<link href="doxygen.css" rel="stylesheet" type="text/css" />
|
||||
<link href="doxygen-awesome.css" rel="stylesheet" type="text/css"/>
|
||||
</head>
|
||||
<body>
|
||||
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
|
||||
<div id="titlearea">
|
||||
<table cellspacing="0" cellpadding="0">
|
||||
<tbody>
|
||||
<tr id="projectrow">
|
||||
<td id="projectalign">
|
||||
<div id="projectname">Penning Trap Simulation
|
||||
</div>
|
||||
<div id="projectbrief">Simulate particle behavior inside a Penning Trap</div>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
<!-- end header part -->
|
||||
<!-- Generated by Doxygen 1.9.6 -->
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
||||
var searchBox = new SearchBox("searchBox", "search/",'.html');
|
||||
/* @license-end */
|
||||
</script>
|
||||
<script type="text/javascript" src="menudata.js"></script>
|
||||
<script type="text/javascript" src="menu.js"></script>
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
||||
$(function() {
|
||||
initMenu('',true,false,'search.php','Search');
|
||||
$(document).ready(function() { init_search(); });
|
||||
});
|
||||
/* @license-end */
|
||||
</script>
|
||||
<div id="main-nav"></div>
|
||||
</div><!-- top -->
|
||||
<div id="side-nav" class="ui-resizable side-nav-resizable">
|
||||
<div id="nav-tree">
|
||||
<div id="nav-tree-contents">
|
||||
<div id="nav-sync" class="sync"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="splitbar" style="-moz-user-select:none;"
|
||||
class="ui-resizable-handle">
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
||||
$(document).ready(function(){initNavTree('dir_634e799a3947388232110823971192a8.html',''); initResizable(); });
|
||||
/* @license-end */
|
||||
</script>
|
||||
<div id="doc-content">
|
||||
<!-- window showing the filter options -->
|
||||
<div id="MSearchSelectWindow"
|
||||
onmouseover="return searchBox.OnSearchSelectShow()"
|
||||
onmouseout="return searchBox.OnSearchSelectHide()"
|
||||
onkeydown="return searchBox.OnSearchSelectKey(event)">
|
||||
</div>
|
||||
|
||||
<!-- iframe showing the search results (closed by default) -->
|
||||
<div id="MSearchResultsWindow">
|
||||
<div id="MSearchResults">
|
||||
<div class="SRPage">
|
||||
<div id="SRIndex">
|
||||
<div id="SRResults"></div>
|
||||
<div class="SRStatus" id="Loading">Loading...</div>
|
||||
<div class="SRStatus" id="Searching">Searching...</div>
|
||||
<div class="SRStatus" id="NoMatches">No Matches</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="header">
|
||||
<div class="headertitle"><div class="title">scripts Directory Reference</div></div>
|
||||
</div><!--header-->
|
||||
<div class="contents">
|
||||
<table class="memberdecls">
|
||||
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="files" name="files"></a>
|
||||
Files</h2></td></tr>
|
||||
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">file  </td><td class="memItemRight" valign="bottom"><b>animate_100_particles.py</b> <a href="animate__100__particles_8py_source.html">[code]</a></td></tr>
|
||||
<tr class="separator:"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">file  </td><td class="memItemRight" valign="bottom"><b>plot_2_particles.py</b> <a href="plot__2__particles_8py_source.html">[code]</a></td></tr>
|
||||
<tr class="separator:"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">file  </td><td class="memItemRight" valign="bottom"><b>plot_3d.py</b> <a href="plot__3d_8py_source.html">[code]</a></td></tr>
|
||||
<tr class="separator:"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">file  </td><td class="memItemRight" valign="bottom"><b>plot_particles_left.py</b> <a href="plot__particles__left_8py_source.html">[code]</a></td></tr>
|
||||
<tr class="separator:"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">file  </td><td class="memItemRight" valign="bottom"><b>plot_phase_space.py</b> <a href="plot__phase__space_8py_source.html">[code]</a></td></tr>
|
||||
<tr class="separator:"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">file  </td><td class="memItemRight" valign="bottom"><b>plot_relative_error.py</b> <a href="plot__relative__error_8py_source.html">[code]</a></td></tr>
|
||||
<tr class="separator:"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">file  </td><td class="memItemRight" valign="bottom"><b>plot_single_particle.py</b> <a href="plot__single__particle_8py_source.html">[code]</a></td></tr>
|
||||
<tr class="separator:"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
</table>
|
||||
</div><!-- contents -->
|
||||
</div><!-- doc-content -->
|
||||
<!-- start footer part -->
|
||||
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
|
||||
<ul>
|
||||
<li class="navelem"><a class="el" href="dir_68267d1309a1af8e8297ef4c3efbcdba.html">src</a></li><li class="navelem"><a class="el" href="dir_634e799a3947388232110823971192a8.html">scripts</a></li>
|
||||
<li class="footer">Generated by <a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.9.6 </li>
|
||||
</ul>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
10
docs/dir_634e799a3947388232110823971192a8.js
Normal file
10
docs/dir_634e799a3947388232110823971192a8.js
Normal file
@@ -0,0 +1,10 @@
|
||||
var dir_634e799a3947388232110823971192a8 =
|
||||
[
|
||||
[ "animate_100_particles.py", "animate__100__particles_8py_source.html", null ],
|
||||
[ "plot_2_particles.py", "plot__2__particles_8py_source.html", null ],
|
||||
[ "plot_3d.py", "plot__3d_8py_source.html", null ],
|
||||
[ "plot_particles_left.py", "plot__particles__left_8py_source.html", null ],
|
||||
[ "plot_phase_space.py", "plot__phase__space_8py_source.html", null ],
|
||||
[ "plot_relative_error.py", "plot__relative__error_8py_source.html", null ],
|
||||
[ "plot_single_particle.py", "plot__single__particle_8py_source.html", null ]
|
||||
];
|
||||
@@ -102,6 +102,11 @@ $(document).ready(function(){initNavTree('dir_68267d1309a1af8e8297ef4c3efbcdba.h
|
||||
</div><!--header-->
|
||||
<div class="contents">
|
||||
<table class="memberdecls">
|
||||
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="subdirs" name="subdirs"></a>
|
||||
Directories</h2></td></tr>
|
||||
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">directory  </td><td class="memItemRight" valign="bottom"><a class="el" href="dir_634e799a3947388232110823971192a8.html">scripts</a></td></tr>
|
||||
<tr class="separator:"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
</table><table class="memberdecls">
|
||||
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="files" name="files"></a>
|
||||
Files</h2></td></tr>
|
||||
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">file  </td><td class="memItemRight" valign="bottom"><a class="el" href="main_8cpp.html">main.cpp</a> <a href="main_8cpp_source.html">[code]</a></td></tr>
|
||||
|
||||
@@ -1,8 +1,9 @@
|
||||
var dir_68267d1309a1af8e8297ef4c3efbcdba =
|
||||
[
|
||||
[ "main.cpp", "main_8cpp.html", null ],
|
||||
[ "scripts", "dir_634e799a3947388232110823971192a8.html", "dir_634e799a3947388232110823971192a8" ],
|
||||
[ "main.cpp", "main_8cpp.html", "main_8cpp" ],
|
||||
[ "Particle.cpp", "Particle_8cpp.html", null ],
|
||||
[ "PenningTrap.cpp", "PenningTrap_8cpp.html", null ],
|
||||
[ "test_suite.cpp", "test__suite_8cpp.html", null ],
|
||||
[ "test_suite.cpp", "test__suite_8cpp.html", "test__suite_8cpp" ],
|
||||
[ "utils.cpp", "utils_8cpp.html", "utils_8cpp" ]
|
||||
];
|
||||
@@ -113,6 +113,9 @@ Files</h2></td></tr>
|
||||
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">file  </td><td class="memItemRight" valign="bottom"><a class="el" href="PenningTrap_8hpp.html">PenningTrap.hpp</a> <a href="PenningTrap_8hpp_source.html">[code]</a></td></tr>
|
||||
<tr class="memdesc:PenningTrap_8hpp"><td class="mdescLeft"> </td><td class="mdescRight">A class for simulating a Penning trap. <br /></td></tr>
|
||||
<tr class="separator:"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">file  </td><td class="memItemRight" valign="bottom"><a class="el" href="typedefs_8hpp.html">typedefs.hpp</a> <a href="typedefs_8hpp_source.html">[code]</a></td></tr>
|
||||
<tr class="memdesc:typedefs_8hpp"><td class="mdescLeft"> </td><td class="mdescRight">Useful typedefs for cleaner code. <br /></td></tr>
|
||||
<tr class="separator:"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">file  </td><td class="memItemRight" valign="bottom"><a class="el" href="utils_8hpp.html">utils.hpp</a> <a href="utils_8hpp_source.html">[code]</a></td></tr>
|
||||
<tr class="memdesc:utils_8hpp"><td class="mdescLeft"> </td><td class="mdescRight">Function prototypes and macros that are useful. <br /></td></tr>
|
||||
<tr class="separator:"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
|
||||
@@ -3,5 +3,6 @@ var dir_d44c64559bbebec7f509842c48db8b23 =
|
||||
[ "constants.hpp", "constants_8hpp.html", "constants_8hpp" ],
|
||||
[ "Particle.hpp", "Particle_8hpp.html", "Particle_8hpp" ],
|
||||
[ "PenningTrap.hpp", "PenningTrap_8hpp.html", "PenningTrap_8hpp" ],
|
||||
[ "typedefs.hpp", "typedefs_8hpp.html", "typedefs_8hpp" ],
|
||||
[ "utils.hpp", "utils_8hpp.html", "utils_8hpp" ]
|
||||
];
|
||||
@@ -102,18 +102,27 @@ $(document).ready(function(){initNavTree('files.html',''); initResizable(); });
|
||||
</div><!--header-->
|
||||
<div class="contents">
|
||||
<div class="textblock">Here is a list of all documented files with brief descriptions:</div><div class="directory">
|
||||
<div class="levels">[detail level <span onclick="javascript:toggleLevel(1);">1</span><span onclick="javascript:toggleLevel(2);">2</span>]</div><table class="directory">
|
||||
<div class="levels">[detail level <span onclick="javascript:toggleLevel(1);">1</span><span onclick="javascript:toggleLevel(2);">2</span><span onclick="javascript:toggleLevel(3);">3</span>]</div><table class="directory">
|
||||
<tr id="row_0_" class="even"><td class="entry"><span style="width:0px;display:inline-block;"> </span><span id="arr_0_" class="arrow" onclick="toggleFolder('0_')">▼</span><span id="img_0_" class="iconfopen" onclick="toggleFolder('0_')"> </span><a class="el" href="dir_d44c64559bbebec7f509842c48db8b23.html" target="_self">include</a></td><td class="desc"></td></tr>
|
||||
<tr id="row_0_0_" class="odd"><td class="entry"><span style="width:32px;display:inline-block;"> </span><a href="constants_8hpp_source.html"><span class="icondoc"></span></a><a class="el" href="constants_8hpp.html" target="_self">constants.hpp</a></td><td class="desc">Library of constants </td></tr>
|
||||
<tr id="row_0_1_" class="even"><td class="entry"><span style="width:32px;display:inline-block;"> </span><a href="Particle_8hpp_source.html"><span class="icondoc"></span></a><a class="el" href="Particle_8hpp.html" target="_self">Particle.hpp</a></td><td class="desc">A class that holds the properties of a particle </td></tr>
|
||||
<tr id="row_0_2_" class="odd"><td class="entry"><span style="width:32px;display:inline-block;"> </span><a href="PenningTrap_8hpp_source.html"><span class="icondoc"></span></a><a class="el" href="PenningTrap_8hpp.html" target="_self">PenningTrap.hpp</a></td><td class="desc">A class for simulating a Penning trap </td></tr>
|
||||
<tr id="row_0_3_" class="even"><td class="entry"><span style="width:32px;display:inline-block;"> </span><a href="utils_8hpp_source.html"><span class="icondoc"></span></a><a class="el" href="utils_8hpp.html" target="_self">utils.hpp</a></td><td class="desc">Function prototypes and macros that are useful </td></tr>
|
||||
<tr id="row_1_" class="odd"><td class="entry"><span style="width:0px;display:inline-block;"> </span><span id="arr_1_" class="arrow" onclick="toggleFolder('1_')">▼</span><span id="img_1_" class="iconfopen" onclick="toggleFolder('1_')"> </span><a class="el" href="dir_68267d1309a1af8e8297ef4c3efbcdba.html" target="_self">src</a></td><td class="desc"></td></tr>
|
||||
<tr id="row_1_0_" class="even"><td class="entry"><span style="width:32px;display:inline-block;"> </span><a href="main_8cpp_source.html"><span class="icondoc"></span></a><a class="el" href="main_8cpp.html" target="_self">main.cpp</a></td><td class="desc">The main program for this project </td></tr>
|
||||
<tr id="row_1_1_" class="odd"><td class="entry"><span style="width:32px;display:inline-block;"> </span><a href="Particle_8cpp_source.html"><span class="icondoc"></span></a><a class="el" href="Particle_8cpp.html" target="_self">Particle.cpp</a></td><td class="desc">The implementation of the <a class="el" href="classParticle.html" title="A class that holds attributes of a particle.">Particle</a> class </td></tr>
|
||||
<tr id="row_1_2_" class="even"><td class="entry"><span style="width:32px;display:inline-block;"> </span><a href="PenningTrap_8cpp_source.html"><span class="icondoc"></span></a><a class="el" href="PenningTrap_8cpp.html" target="_self">PenningTrap.cpp</a></td><td class="desc">The implementation of the <a class="el" href="classPenningTrap.html" title="A class that simulates a Penning trap.">PenningTrap</a> class </td></tr>
|
||||
<tr id="row_1_3_" class="odd"><td class="entry"><span style="width:32px;display:inline-block;"> </span><a href="test__suite_8cpp_source.html"><span class="icondoc"></span></a><a class="el" href="test__suite_8cpp.html" target="_self">test_suite.cpp</a></td><td class="desc">The test suite for the project </td></tr>
|
||||
<tr id="row_1_4_" class="even"><td class="entry"><span style="width:32px;display:inline-block;"> </span><a href="utils_8cpp_source.html"><span class="icondoc"></span></a><a class="el" href="utils_8cpp.html" target="_self">utils.cpp</a></td><td class="desc">Implementation of the utils </td></tr>
|
||||
<tr id="row_0_3_" class="even"><td class="entry"><span style="width:32px;display:inline-block;"> </span><a href="typedefs_8hpp_source.html"><span class="icondoc"></span></a><a class="el" href="typedefs_8hpp.html" target="_self">typedefs.hpp</a></td><td class="desc">Useful typedefs for cleaner code </td></tr>
|
||||
<tr id="row_0_4_" class="odd"><td class="entry"><span style="width:32px;display:inline-block;"> </span><a href="utils_8hpp_source.html"><span class="icondoc"></span></a><a class="el" href="utils_8hpp.html" target="_self">utils.hpp</a></td><td class="desc">Function prototypes and macros that are useful </td></tr>
|
||||
<tr id="row_1_" class="even"><td class="entry"><span style="width:0px;display:inline-block;"> </span><span id="arr_1_" class="arrow" onclick="toggleFolder('1_')">▼</span><span id="img_1_" class="iconfopen" onclick="toggleFolder('1_')"> </span><a class="el" href="dir_68267d1309a1af8e8297ef4c3efbcdba.html" target="_self">src</a></td><td class="desc"></td></tr>
|
||||
<tr id="row_1_0_" class="odd"><td class="entry"><span style="width:16px;display:inline-block;"> </span><span id="arr_1_0_" class="arrow" onclick="toggleFolder('1_0_')">▼</span><span id="img_1_0_" class="iconfopen" onclick="toggleFolder('1_0_')"> </span><a class="el" href="dir_634e799a3947388232110823971192a8.html" target="_self">scripts</a></td><td class="desc"></td></tr>
|
||||
<tr id="row_1_0_0_" class="even"><td class="entry"><span style="width:48px;display:inline-block;"> </span><a href="animate__100__particles_8py_source.html"><span class="icondoc"></span></a><b>animate_100_particles.py</b></td><td class="desc"></td></tr>
|
||||
<tr id="row_1_0_1_" class="odd"><td class="entry"><span style="width:48px;display:inline-block;"> </span><a href="plot__2__particles_8py_source.html"><span class="icondoc"></span></a><b>plot_2_particles.py</b></td><td class="desc"></td></tr>
|
||||
<tr id="row_1_0_2_" class="even"><td class="entry"><span style="width:48px;display:inline-block;"> </span><a href="plot__3d_8py_source.html"><span class="icondoc"></span></a><b>plot_3d.py</b></td><td class="desc"></td></tr>
|
||||
<tr id="row_1_0_3_" class="odd"><td class="entry"><span style="width:48px;display:inline-block;"> </span><a href="plot__particles__left_8py_source.html"><span class="icondoc"></span></a><b>plot_particles_left.py</b></td><td class="desc"></td></tr>
|
||||
<tr id="row_1_0_4_" class="even"><td class="entry"><span style="width:48px;display:inline-block;"> </span><a href="plot__phase__space_8py_source.html"><span class="icondoc"></span></a><b>plot_phase_space.py</b></td><td class="desc"></td></tr>
|
||||
<tr id="row_1_0_5_" class="odd"><td class="entry"><span style="width:48px;display:inline-block;"> </span><a href="plot__relative__error_8py_source.html"><span class="icondoc"></span></a><b>plot_relative_error.py</b></td><td class="desc"></td></tr>
|
||||
<tr id="row_1_0_6_" class="even"><td class="entry"><span style="width:48px;display:inline-block;"> </span><a href="plot__single__particle_8py_source.html"><span class="icondoc"></span></a><b>plot_single_particle.py</b></td><td class="desc"></td></tr>
|
||||
<tr id="row_1_1_" class="odd"><td class="entry"><span style="width:32px;display:inline-block;"> </span><a href="main_8cpp_source.html"><span class="icondoc"></span></a><a class="el" href="main_8cpp.html" target="_self">main.cpp</a></td><td class="desc">The main program for this project </td></tr>
|
||||
<tr id="row_1_2_" class="even"><td class="entry"><span style="width:32px;display:inline-block;"> </span><a href="Particle_8cpp_source.html"><span class="icondoc"></span></a><a class="el" href="Particle_8cpp.html" target="_self">Particle.cpp</a></td><td class="desc">The implementation of the <a class="el" href="classParticle.html" title="A class that holds attributes of a particle.">Particle</a> class </td></tr>
|
||||
<tr id="row_1_3_" class="odd"><td class="entry"><span style="width:32px;display:inline-block;"> </span><a href="PenningTrap_8cpp_source.html"><span class="icondoc"></span></a><a class="el" href="PenningTrap_8cpp.html" target="_self">PenningTrap.cpp</a></td><td class="desc">The implementation of the <a class="el" href="classPenningTrap.html" title="A class that simulates a Penning trap.">PenningTrap</a> class </td></tr>
|
||||
<tr id="row_1_4_" class="even"><td class="entry"><span style="width:32px;display:inline-block;"> </span><a href="test__suite_8cpp_source.html"><span class="icondoc"></span></a><a class="el" href="test__suite_8cpp.html" target="_self">test_suite.cpp</a></td><td class="desc">The test suite for the project </td></tr>
|
||||
<tr id="row_1_5_" class="odd"><td class="entry"><span style="width:32px;display:inline-block;"> </span><a href="utils_8cpp_source.html"><span class="icondoc"></span></a><a class="el" href="utils_8cpp.html" target="_self">utils.cpp</a></td><td class="desc">Implementation of the utils </td></tr>
|
||||
</table>
|
||||
</div><!-- directory -->
|
||||
</div><!-- contents -->
|
||||
|
||||
@@ -98,26 +98,97 @@ $(document).ready(function(){initNavTree('functions.html',''); initResizable();
|
||||
</div>
|
||||
|
||||
<div class="contents">
|
||||
<div class="textblock">Here is a list of all documented class members with links to the class documentation for each member:</div><ul>
|
||||
<div class="textblock">Here is a list of all documented class members with links to the class documentation for each member:</div>
|
||||
|
||||
<h3><a id="index_a" name="index_a"></a>- a -</h3><ul>
|
||||
<li>add_particle() : <a class="el" href="classPenningTrap.html#a6e9776ff5b149f01080800716455d7c8">PenningTrap</a></li>
|
||||
</ul>
|
||||
|
||||
|
||||
<h3><a id="index_b" name="index_b"></a>- b -</h3><ul>
|
||||
<li>B_0 : <a class="el" href="classPenningTrap.html#a0cac3509aa96e71a26d3b2c902e27716">PenningTrap</a></li>
|
||||
</ul>
|
||||
|
||||
|
||||
<h3><a id="index_d" name="index_d"></a>- d -</h3><ul>
|
||||
<li>d : <a class="el" href="classPenningTrap.html#a66dfe89c68716b9502927b97f59c27d2">PenningTrap</a></li>
|
||||
<li>evolve_forward_euler() : <a class="el" href="classPenningTrap.html#a56544b6f4befb42984e9650cf2a40965">PenningTrap</a></li>
|
||||
<li>evolve_RK4() : <a class="el" href="classPenningTrap.html#ab891b839c40eeb38d8a2a636c70090a9">PenningTrap</a></li>
|
||||
<li>external_B_field() : <a class="el" href="classPenningTrap.html#a2a3e7f480ba52e9f24d4c50c3981a784">PenningTrap</a></li>
|
||||
<li>external_E_field() : <a class="el" href="classPenningTrap.html#a978a2e2026a4b5308d5184712f81704b">PenningTrap</a></li>
|
||||
<li>force_on_particle() : <a class="el" href="classPenningTrap.html#a4790f41e4fbc6ede4991aa7bbda92182">PenningTrap</a></li>
|
||||
</ul>
|
||||
|
||||
|
||||
<h3><a id="index_e" name="index_e"></a>- e -</h3><ul>
|
||||
<li>evolve_forward_euler() : <a class="el" href="classPenningTrap.html#ab9ea97a406534bbe621a95215144875e">PenningTrap</a></li>
|
||||
<li>evolve_RK4() : <a class="el" href="classPenningTrap.html#a36946152fd951b1f7c346c51ff900d8e">PenningTrap</a></li>
|
||||
<li>external_B_field() : <a class="el" href="classPenningTrap.html#a361f2c4862c90b5e8e2a2f50c6a95655">PenningTrap</a></li>
|
||||
<li>external_E_field() : <a class="el" href="classPenningTrap.html#a5846c8f75cdc543fd9cf0b2185a3ef22">PenningTrap</a></li>
|
||||
</ul>
|
||||
|
||||
|
||||
<h3><a id="index_f" name="index_f"></a>- f -</h3><ul>
|
||||
<li>force_on_particle() : <a class="el" href="classPenningTrap.html#a7f210bb2768a5d79ced4b0df0df97598">PenningTrap</a></li>
|
||||
<li>fraction_of_particles_left() : <a class="el" href="classPenningTrap.html#ac529aa26c288f34eae184a67e6bac41f">PenningTrap</a></li>
|
||||
</ul>
|
||||
|
||||
|
||||
<h3><a id="index_k" name="index_k"></a>- k -</h3><ul>
|
||||
<li>k_r : <a class="el" href="classPenningTrap.html#a2f168622587709b9e3c49077f0b9a640">PenningTrap</a></li>
|
||||
<li>k_v : <a class="el" href="classPenningTrap.html#ae9b5afdaa5cd366e94bd294452a1eed4">PenningTrap</a></li>
|
||||
</ul>
|
||||
|
||||
|
||||
<h3><a id="index_m" name="index_m"></a>- m -</h3><ul>
|
||||
<li>m : <a class="el" href="classParticle.html#aedcc7e1bc53b0e2b1a4a07c9a1b47563">Particle</a></li>
|
||||
<li>Particle() : <a class="el" href="classParticle.html#a00e108823877a25513ccae7cac011b4c">Particle</a></li>
|
||||
</ul>
|
||||
|
||||
|
||||
<h3><a id="index_p" name="index_p"></a>- p -</h3><ul>
|
||||
<li>Particle() : <a class="el" href="classParticle.html#af1d7535fb8311eaa77d2b7b345882ec4">Particle</a></li>
|
||||
<li>particles : <a class="el" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">PenningTrap</a></li>
|
||||
<li>PenningTrap : <a class="el" href="classParticle.html#aa797d319549dc2a0beb06cdbfd430232">Particle</a>, <a class="el" href="classPenningTrap.html#a81add5063bd5f29d77f0b5c299c6c560">PenningTrap</a></li>
|
||||
<li>PenningTrap : <a class="el" href="classParticle.html#aa797d319549dc2a0beb06cdbfd430232">Particle</a>, <a class="el" href="classPenningTrap.html#a5b6c6d4636f3a6e279ccde59d4a345e8">PenningTrap</a></li>
|
||||
<li>PenningTrapTest : <a class="el" href="classPenningTrap.html#a869f032f37d0569ed16f224b4c4356ae">PenningTrap</a></li>
|
||||
<li>perturbation : <a class="el" href="classPenningTrap.html#ae915f6ad0eef1fb46530e836b6e071e5">PenningTrap</a></li>
|
||||
</ul>
|
||||
|
||||
|
||||
<h3><a id="index_q" name="index_q"></a>- q -</h3><ul>
|
||||
<li>q : <a class="el" href="classParticle.html#a566dcc1de4bdc01251776948798ea8e1">Particle</a></li>
|
||||
<li>r_vec : <a class="el" href="classParticle.html#acf1a0f3c978b06d76df5bb4279594467">Particle</a></li>
|
||||
<li>total_force() : <a class="el" href="classPenningTrap.html#a83cc7a04dae009ed8e75453c38fdf8be">PenningTrap</a></li>
|
||||
<li>total_force_external() : <a class="el" href="classPenningTrap.html#a045adb85e97a8e0c38fb36d2fd74eeee">PenningTrap</a></li>
|
||||
<li>total_force_particles() : <a class="el" href="classPenningTrap.html#a135db7d991d9b88b00fde4edee71f78d">PenningTrap</a></li>
|
||||
</ul>
|
||||
|
||||
|
||||
<h3><a id="index_r" name="index_r"></a>- r -</h3><ul>
|
||||
<li>r_func() : <a class="el" href="classPenningTrap.html#a826b7fa8e709d481eb1dee7d0c2cdc08">PenningTrap</a></li>
|
||||
<li>r_vec : <a class="el" href="classParticle.html#a1c59101411db43624828b766f87ad460">Particle</a></li>
|
||||
<li>reinitialize() : <a class="el" href="classPenningTrap.html#aaee129f177657455348d0c8ae1441dea">PenningTrap</a></li>
|
||||
</ul>
|
||||
|
||||
|
||||
<h3><a id="index_s" name="index_s"></a>- s -</h3><ul>
|
||||
<li>set_pertubation() : <a class="el" href="classPenningTrap.html#a9d1d8e90ca839b928aee1ad0cd4aff43">PenningTrap</a></li>
|
||||
<li>simulate() : <a class="el" href="classPenningTrap.html#a7a1d9f0528a12308de25bc30718da20a">PenningTrap</a></li>
|
||||
</ul>
|
||||
|
||||
|
||||
<h3><a id="index_t" name="index_t"></a>- t -</h3><ul>
|
||||
<li>t : <a class="el" href="classPenningTrap.html#a8ca4e21291f60fde619c14099d8c4e8e">PenningTrap</a></li>
|
||||
<li>test_external_B_field() : <a class="el" href="classPenningTrapTest.html#ad668d7d875bdc1909a42426bf9dead9e">PenningTrapTest</a></li>
|
||||
<li>test_external_E_field() : <a class="el" href="classPenningTrapTest.html#a6a303be62039ca2ecccd8252744d4dc8">PenningTrapTest</a></li>
|
||||
<li>test_force_on_particle() : <a class="el" href="classPenningTrapTest.html#a5f4f0b150e54ce463bb29f76d49883f9">PenningTrapTest</a></li>
|
||||
<li>test_total_force_external() : <a class="el" href="classPenningTrapTest.html#ae6d0c8e0d80338fb7c7edefc97331046">PenningTrapTest</a></li>
|
||||
<li>test_total_force_particles() : <a class="el" href="classPenningTrapTest.html#a68449d508e66205bc8b27fa5f60db508">PenningTrapTest</a></li>
|
||||
<li>total_force() : <a class="el" href="classPenningTrap.html#a9a301b0540078c36697880ef204afdf3">PenningTrap</a></li>
|
||||
<li>total_force_external() : <a class="el" href="classPenningTrap.html#a2c01108b52c8e2a003cf9170da9e7682">PenningTrap</a></li>
|
||||
<li>total_force_particles() : <a class="el" href="classPenningTrap.html#a2fe1cefbae18fa5808155ee0d2df713c">PenningTrap</a></li>
|
||||
</ul>
|
||||
|
||||
|
||||
<h3><a id="index_v" name="index_v"></a>- v -</h3><ul>
|
||||
<li>V_0 : <a class="el" href="classPenningTrap.html#a715329844d75ec4c04f8391421fb4e89">PenningTrap</a></li>
|
||||
<li>v_vec : <a class="el" href="classParticle.html#a4a5d22c7aeca66f67d083f270cba25df">Particle</a></li>
|
||||
<li>v_func() : <a class="el" href="classPenningTrap.html#a3c0a44e4e0a94366ff609e81fe463fa2">PenningTrap</a></li>
|
||||
<li>v_vec : <a class="el" href="classParticle.html#a3a10400add8dd22b8031330c2aafb6fe">Particle</a></li>
|
||||
</ul>
|
||||
|
||||
|
||||
<h3><a id="index_w" name="index_w"></a>- w -</h3><ul>
|
||||
<li>write_simulation_to_dir() : <a class="el" href="classPenningTrap.html#ad8bc4df7ab3eed53b16cfdff38e7760b">PenningTrap</a></li>
|
||||
</ul>
|
||||
</div><!-- contents -->
|
||||
</div><!-- doc-content -->
|
||||
|
||||
@@ -100,16 +100,28 @@ $(document).ready(function(){initNavTree('functions_func.html',''); initResizabl
|
||||
<div class="contents">
|
||||
 <ul>
|
||||
<li>add_particle() : <a class="el" href="classPenningTrap.html#a6e9776ff5b149f01080800716455d7c8">PenningTrap</a></li>
|
||||
<li>evolve_forward_euler() : <a class="el" href="classPenningTrap.html#a56544b6f4befb42984e9650cf2a40965">PenningTrap</a></li>
|
||||
<li>evolve_RK4() : <a class="el" href="classPenningTrap.html#ab891b839c40eeb38d8a2a636c70090a9">PenningTrap</a></li>
|
||||
<li>external_B_field() : <a class="el" href="classPenningTrap.html#a2a3e7f480ba52e9f24d4c50c3981a784">PenningTrap</a></li>
|
||||
<li>external_E_field() : <a class="el" href="classPenningTrap.html#a978a2e2026a4b5308d5184712f81704b">PenningTrap</a></li>
|
||||
<li>force_on_particle() : <a class="el" href="classPenningTrap.html#a4790f41e4fbc6ede4991aa7bbda92182">PenningTrap</a></li>
|
||||
<li>Particle() : <a class="el" href="classParticle.html#a00e108823877a25513ccae7cac011b4c">Particle</a></li>
|
||||
<li>PenningTrap() : <a class="el" href="classPenningTrap.html#a81add5063bd5f29d77f0b5c299c6c560">PenningTrap</a></li>
|
||||
<li>total_force() : <a class="el" href="classPenningTrap.html#a83cc7a04dae009ed8e75453c38fdf8be">PenningTrap</a></li>
|
||||
<li>total_force_external() : <a class="el" href="classPenningTrap.html#a045adb85e97a8e0c38fb36d2fd74eeee">PenningTrap</a></li>
|
||||
<li>total_force_particles() : <a class="el" href="classPenningTrap.html#a135db7d991d9b88b00fde4edee71f78d">PenningTrap</a></li>
|
||||
<li>evolve_forward_euler() : <a class="el" href="classPenningTrap.html#ab9ea97a406534bbe621a95215144875e">PenningTrap</a></li>
|
||||
<li>evolve_RK4() : <a class="el" href="classPenningTrap.html#a36946152fd951b1f7c346c51ff900d8e">PenningTrap</a></li>
|
||||
<li>external_B_field() : <a class="el" href="classPenningTrap.html#a361f2c4862c90b5e8e2a2f50c6a95655">PenningTrap</a></li>
|
||||
<li>external_E_field() : <a class="el" href="classPenningTrap.html#a5846c8f75cdc543fd9cf0b2185a3ef22">PenningTrap</a></li>
|
||||
<li>force_on_particle() : <a class="el" href="classPenningTrap.html#a7f210bb2768a5d79ced4b0df0df97598">PenningTrap</a></li>
|
||||
<li>fraction_of_particles_left() : <a class="el" href="classPenningTrap.html#ac529aa26c288f34eae184a67e6bac41f">PenningTrap</a></li>
|
||||
<li>Particle() : <a class="el" href="classParticle.html#af1d7535fb8311eaa77d2b7b345882ec4">Particle</a></li>
|
||||
<li>PenningTrap() : <a class="el" href="classPenningTrap.html#a5b6c6d4636f3a6e279ccde59d4a345e8">PenningTrap</a></li>
|
||||
<li>r_func() : <a class="el" href="classPenningTrap.html#a826b7fa8e709d481eb1dee7d0c2cdc08">PenningTrap</a></li>
|
||||
<li>reinitialize() : <a class="el" href="classPenningTrap.html#aaee129f177657455348d0c8ae1441dea">PenningTrap</a></li>
|
||||
<li>set_pertubation() : <a class="el" href="classPenningTrap.html#a9d1d8e90ca839b928aee1ad0cd4aff43">PenningTrap</a></li>
|
||||
<li>simulate() : <a class="el" href="classPenningTrap.html#a7a1d9f0528a12308de25bc30718da20a">PenningTrap</a></li>
|
||||
<li>test_external_B_field() : <a class="el" href="classPenningTrapTest.html#ad668d7d875bdc1909a42426bf9dead9e">PenningTrapTest</a></li>
|
||||
<li>test_external_E_field() : <a class="el" href="classPenningTrapTest.html#a6a303be62039ca2ecccd8252744d4dc8">PenningTrapTest</a></li>
|
||||
<li>test_force_on_particle() : <a class="el" href="classPenningTrapTest.html#a5f4f0b150e54ce463bb29f76d49883f9">PenningTrapTest</a></li>
|
||||
<li>test_total_force_external() : <a class="el" href="classPenningTrapTest.html#ae6d0c8e0d80338fb7c7edefc97331046">PenningTrapTest</a></li>
|
||||
<li>test_total_force_particles() : <a class="el" href="classPenningTrapTest.html#a68449d508e66205bc8b27fa5f60db508">PenningTrapTest</a></li>
|
||||
<li>total_force() : <a class="el" href="classPenningTrap.html#a9a301b0540078c36697880ef204afdf3">PenningTrap</a></li>
|
||||
<li>total_force_external() : <a class="el" href="classPenningTrap.html#a2c01108b52c8e2a003cf9170da9e7682">PenningTrap</a></li>
|
||||
<li>total_force_particles() : <a class="el" href="classPenningTrap.html#a2fe1cefbae18fa5808155ee0d2df713c">PenningTrap</a></li>
|
||||
<li>v_func() : <a class="el" href="classPenningTrap.html#a3c0a44e4e0a94366ff609e81fe463fa2">PenningTrap</a></li>
|
||||
<li>write_simulation_to_dir() : <a class="el" href="classPenningTrap.html#ad8bc4df7ab3eed53b16cfdff38e7760b">PenningTrap</a></li>
|
||||
</ul>
|
||||
</div><!-- contents -->
|
||||
</div><!-- doc-content -->
|
||||
|
||||
@@ -100,6 +100,7 @@ $(document).ready(function(){initNavTree('functions_rela.html',''); initResizabl
|
||||
<div class="contents">
|
||||
 <ul>
|
||||
<li>PenningTrap : <a class="el" href="classParticle.html#aa797d319549dc2a0beb06cdbfd430232">Particle</a></li>
|
||||
<li>PenningTrapTest : <a class="el" href="classPenningTrap.html#a869f032f37d0569ed16f224b4c4356ae">PenningTrap</a></li>
|
||||
</ul>
|
||||
</div><!-- contents -->
|
||||
</div><!-- doc-content -->
|
||||
|
||||
@@ -101,12 +101,16 @@ $(document).ready(function(){initNavTree('functions_vars.html',''); initResizabl
|
||||
 <ul>
|
||||
<li>B_0 : <a class="el" href="classPenningTrap.html#a0cac3509aa96e71a26d3b2c902e27716">PenningTrap</a></li>
|
||||
<li>d : <a class="el" href="classPenningTrap.html#a66dfe89c68716b9502927b97f59c27d2">PenningTrap</a></li>
|
||||
<li>k_r : <a class="el" href="classPenningTrap.html#a2f168622587709b9e3c49077f0b9a640">PenningTrap</a></li>
|
||||
<li>k_v : <a class="el" href="classPenningTrap.html#ae9b5afdaa5cd366e94bd294452a1eed4">PenningTrap</a></li>
|
||||
<li>m : <a class="el" href="classParticle.html#aedcc7e1bc53b0e2b1a4a07c9a1b47563">Particle</a></li>
|
||||
<li>particles : <a class="el" href="classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f">PenningTrap</a></li>
|
||||
<li>perturbation : <a class="el" href="classPenningTrap.html#ae915f6ad0eef1fb46530e836b6e071e5">PenningTrap</a></li>
|
||||
<li>q : <a class="el" href="classParticle.html#a566dcc1de4bdc01251776948798ea8e1">Particle</a></li>
|
||||
<li>r_vec : <a class="el" href="classParticle.html#acf1a0f3c978b06d76df5bb4279594467">Particle</a></li>
|
||||
<li>r_vec : <a class="el" href="classParticle.html#a1c59101411db43624828b766f87ad460">Particle</a></li>
|
||||
<li>t : <a class="el" href="classPenningTrap.html#a8ca4e21291f60fde619c14099d8c4e8e">PenningTrap</a></li>
|
||||
<li>V_0 : <a class="el" href="classPenningTrap.html#a715329844d75ec4c04f8391421fb4e89">PenningTrap</a></li>
|
||||
<li>v_vec : <a class="el" href="classParticle.html#a4a5d22c7aeca66f67d083f270cba25df">Particle</a></li>
|
||||
<li>v_vec : <a class="el" href="classParticle.html#a3a10400add8dd22b8031330c2aafb6fe">Particle</a></li>
|
||||
</ul>
|
||||
</div><!-- contents -->
|
||||
</div><!-- doc-content -->
|
||||
|
||||
@@ -98,12 +98,72 @@ $(document).ready(function(){initNavTree('globals.html',''); initResizable(); })
|
||||
</div>
|
||||
|
||||
<div class="contents">
|
||||
<div class="textblock">Here is a list of all documented file members with links to the documentation:</div><ul>
|
||||
<div class="textblock">Here is a list of all documented file members with links to the documentation:</div>
|
||||
|
||||
<h3><a id="index__5F" name="index__5F"></a>- _ -</h3><ul>
|
||||
<li>__METHOD_NAME__ : <a class="el" href="utils_8hpp.html#a60dca3177fb9cb5256609adc7af55168">utils.hpp</a></li>
|
||||
</ul>
|
||||
|
||||
|
||||
<h3><a id="index_a" name="index_a"></a>- a -</h3><ul>
|
||||
<li>analytical_solution_particle_1() : <a class="el" href="main_8cpp.html#a8d92fb2ad085065fbd14718647551657">main.cpp</a></li>
|
||||
<li>ASSERT : <a class="el" href="utils_8hpp.html#a73d4f21ad937dbc50a0c0538c78fd4f9">utils.hpp</a></li>
|
||||
</ul>
|
||||
|
||||
|
||||
<h3><a id="index_c" name="index_c"></a>- c -</h3><ul>
|
||||
<li>CA_CHARGE : <a class="el" href="constants_8hpp.html#af7602a3a314957137ad1cd719aa23789">constants.hpp</a></li>
|
||||
<li>CA_MASS : <a class="el" href="constants_8hpp.html#a2ff491cc7958ffd5e749c518a4a60ec8">constants.hpp</a></li>
|
||||
<li>close_to() : <a class="el" href="utils_8hpp.html#ab3e0cf669bddc59bd53998490ffb68b9">utils.hpp</a>, <a class="el" href="utils_8cpp.html#a6be6f938bcbb235ebb6a2ed9d08411b2">utils.cpp</a></li>
|
||||
</ul>
|
||||
|
||||
|
||||
<h3><a id="index_d" name="index_d"></a>- d -</h3><ul>
|
||||
<li>DEBUG : <a class="el" href="utils_8hpp.html#aecc1f7a8a2493b9e021e5bff76a00a5b">utils.hpp</a></li>
|
||||
</ul>
|
||||
|
||||
|
||||
<h3><a id="index_k" name="index_k"></a>- k -</h3><ul>
|
||||
<li>K_E : <a class="el" href="constants_8hpp.html#a4e451456ad7e9276ed0afa42826e7ccb">constants.hpp</a></li>
|
||||
</ul>
|
||||
|
||||
|
||||
<h3><a id="index_m" name="index_m"></a>- m -</h3><ul>
|
||||
<li>m_assert() : <a class="el" href="utils_8hpp.html#a2cc3a2cdb635bac3c8b02e89d4d6af38">utils.hpp</a>, <a class="el" href="utils_8cpp.html#aff5e07c3c1d321709b0cc38e999f427b">utils.cpp</a></li>
|
||||
<li>mkpath() : <a class="el" href="utils_8hpp.html#a6fdd7217b750aff5b6295ece7cbdeffa">utils.hpp</a>, <a class="el" href="utils_8cpp.html#acf13f4e492199cb7231bfa646dbd08de">utils.cpp</a></li>
|
||||
</ul>
|
||||
|
||||
|
||||
<h3><a id="index_p" name="index_p"></a>- p -</h3><ul>
|
||||
<li>p1 : <a class="el" href="main_8cpp.html#a2efa69bb9d93049429ce4637075f1d30">main.cpp</a></li>
|
||||
<li>p2 : <a class="el" href="main_8cpp.html#ac70b61df65f4336f57ea9b4c35250df7">main.cpp</a></li>
|
||||
<li>potential_resonance_narrow_sweep() : <a class="el" href="main_8cpp.html#a33d9b1c76c3c80902f89a58b1a6d96ea">main.cpp</a></li>
|
||||
<li>potential_resonance_narrow_sweep_interaction() : <a class="el" href="main_8cpp.html#ac1816f70ec612edc27848ef7f0875fdb">main.cpp</a></li>
|
||||
<li>potential_resonance_wide_sweep() : <a class="el" href="main_8cpp.html#a6b38b477c18e2f4268779751a88edab1">main.cpp</a></li>
|
||||
</ul>
|
||||
|
||||
|
||||
<h3><a id="index_s" name="index_s"></a>- s -</h3><ul>
|
||||
<li>scientific_format() : <a class="el" href="utils_8hpp.html#adfb618b2fdff47ef30a4a2b62c04f384">utils.hpp</a>, <a class="el" href="utils_8cpp.html#acd2a9c7a7d5a7fe9163be8c4cc110746">utils.cpp</a></li>
|
||||
<li>sim_arr : <a class="el" href="typedefs_8hpp.html#aec69d34220fff45de238b9e01f2686af">typedefs.hpp</a></li>
|
||||
<li>sim_cols : <a class="el" href="typedefs_8hpp.html#a46482a2697556c00556c9d73f461784f">typedefs.hpp</a></li>
|
||||
<li>sim_rows : <a class="el" href="typedefs_8hpp.html#a33418f31f28663b8414c8f7182998c22">typedefs.hpp</a></li>
|
||||
<li>simulate_100_particles() : <a class="el" href="main_8cpp.html#a213713d6ecc02a32b588ffd179dc7513">main.cpp</a></li>
|
||||
<li>simulate_single_particle() : <a class="el" href="main_8cpp.html#a8fdbe2d5a872e50ef5ec1263243589d6">main.cpp</a></li>
|
||||
<li>simulate_single_particle_with_different_steps() : <a class="el" href="main_8cpp.html#ac67e0d59227856c4d42e7d01c75e0ad2">main.cpp</a></li>
|
||||
<li>simulate_two_particles() : <a class="el" href="main_8cpp.html#a783789519f97c6430081171cacb0ffb1">main.cpp</a></li>
|
||||
<li>simulation_t : <a class="el" href="typedefs_8hpp.html#a784799c37b5e4fb8bf4f6368e004dec6">typedefs.hpp</a></li>
|
||||
</ul>
|
||||
|
||||
|
||||
<h3><a id="index_t" name="index_t"></a>- t -</h3><ul>
|
||||
<li>T : <a class="el" href="constants_8hpp.html#a0acb682b8260ab1c60b918599864e2e5">constants.hpp</a></li>
|
||||
</ul>
|
||||
|
||||
|
||||
<h3><a id="index_v" name="index_v"></a>- v -</h3><ul>
|
||||
<li>V : <a class="el" href="constants_8hpp.html#af40a326b23c68a27cebe60f16634a2cb">constants.hpp</a></li>
|
||||
<li>vec3 : <a class="el" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">typedefs.hpp</a></li>
|
||||
</ul>
|
||||
</div><!-- contents -->
|
||||
</div><!-- doc-content -->
|
||||
|
||||
@@ -99,6 +99,10 @@ $(document).ready(function(){initNavTree('globals_defs.html',''); initResizable(
|
||||
|
||||
<div class="contents">
|
||||
 <ul>
|
||||
<li>__METHOD_NAME__ : <a class="el" href="utils_8hpp.html#a60dca3177fb9cb5256609adc7af55168">utils.hpp</a></li>
|
||||
<li>ASSERT : <a class="el" href="utils_8hpp.html#a73d4f21ad937dbc50a0c0538c78fd4f9">utils.hpp</a></li>
|
||||
<li>CA_CHARGE : <a class="el" href="constants_8hpp.html#af7602a3a314957137ad1cd719aa23789">constants.hpp</a></li>
|
||||
<li>CA_MASS : <a class="el" href="constants_8hpp.html#a2ff491cc7958ffd5e749c518a4a60ec8">constants.hpp</a></li>
|
||||
<li>DEBUG : <a class="el" href="utils_8hpp.html#aecc1f7a8a2493b9e021e5bff76a00a5b">utils.hpp</a></li>
|
||||
<li>K_E : <a class="el" href="constants_8hpp.html#a4e451456ad7e9276ed0afa42826e7ccb">constants.hpp</a></li>
|
||||
<li>T : <a class="el" href="constants_8hpp.html#a0acb682b8260ab1c60b918599864e2e5">constants.hpp</a></li>
|
||||
|
||||
@@ -99,7 +99,18 @@ $(document).ready(function(){initNavTree('globals_func.html',''); initResizable(
|
||||
|
||||
<div class="contents">
|
||||
 <ul>
|
||||
<li>analytical_solution_particle_1() : <a class="el" href="main_8cpp.html#a8d92fb2ad085065fbd14718647551657">main.cpp</a></li>
|
||||
<li>close_to() : <a class="el" href="utils_8hpp.html#ab3e0cf669bddc59bd53998490ffb68b9">utils.hpp</a>, <a class="el" href="utils_8cpp.html#a6be6f938bcbb235ebb6a2ed9d08411b2">utils.cpp</a></li>
|
||||
<li>m_assert() : <a class="el" href="utils_8hpp.html#a2cc3a2cdb635bac3c8b02e89d4d6af38">utils.hpp</a>, <a class="el" href="utils_8cpp.html#aff5e07c3c1d321709b0cc38e999f427b">utils.cpp</a></li>
|
||||
<li>mkpath() : <a class="el" href="utils_8hpp.html#a6fdd7217b750aff5b6295ece7cbdeffa">utils.hpp</a>, <a class="el" href="utils_8cpp.html#acf13f4e492199cb7231bfa646dbd08de">utils.cpp</a></li>
|
||||
<li>potential_resonance_narrow_sweep() : <a class="el" href="main_8cpp.html#a33d9b1c76c3c80902f89a58b1a6d96ea">main.cpp</a></li>
|
||||
<li>potential_resonance_narrow_sweep_interaction() : <a class="el" href="main_8cpp.html#ac1816f70ec612edc27848ef7f0875fdb">main.cpp</a></li>
|
||||
<li>potential_resonance_wide_sweep() : <a class="el" href="main_8cpp.html#a6b38b477c18e2f4268779751a88edab1">main.cpp</a></li>
|
||||
<li>scientific_format() : <a class="el" href="utils_8hpp.html#adfb618b2fdff47ef30a4a2b62c04f384">utils.hpp</a>, <a class="el" href="utils_8cpp.html#acd2a9c7a7d5a7fe9163be8c4cc110746">utils.cpp</a></li>
|
||||
<li>simulate_100_particles() : <a class="el" href="main_8cpp.html#a213713d6ecc02a32b588ffd179dc7513">main.cpp</a></li>
|
||||
<li>simulate_single_particle() : <a class="el" href="main_8cpp.html#a8fdbe2d5a872e50ef5ec1263243589d6">main.cpp</a></li>
|
||||
<li>simulate_single_particle_with_different_steps() : <a class="el" href="main_8cpp.html#ac67e0d59227856c4d42e7d01c75e0ad2">main.cpp</a></li>
|
||||
<li>simulate_two_particles() : <a class="el" href="main_8cpp.html#a783789519f97c6430081171cacb0ffb1">main.cpp</a></li>
|
||||
</ul>
|
||||
</div><!-- contents -->
|
||||
</div><!-- doc-content -->
|
||||
|
||||
117
docs/globals_type.html
Normal file
117
docs/globals_type.html
Normal file
@@ -0,0 +1,117 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=11"/>
|
||||
<meta name="generator" content="Doxygen 1.9.6"/>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1"/>
|
||||
<title>Penning Trap Simulation: File Members</title>
|
||||
<link href="tabs.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="jquery.js"></script>
|
||||
<script type="text/javascript" src="dynsections.js"></script>
|
||||
<link href="navtree.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="resize.js"></script>
|
||||
<script type="text/javascript" src="navtreedata.js"></script>
|
||||
<script type="text/javascript" src="navtree.js"></script>
|
||||
<link href="search/search.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="search/searchdata.js"></script>
|
||||
<script type="text/javascript" src="search/search.js"></script>
|
||||
<script type="text/x-mathjax-config">
|
||||
MathJax.Hub.Config({
|
||||
extensions: ["tex2jax.js"],
|
||||
jax: ["input/TeX","output/HTML-CSS"],
|
||||
});
|
||||
</script>
|
||||
<script type="text/javascript" async="async" src="https://cdn.jsdelivr.net/npm/mathjax@2/MathJax.js"></script>
|
||||
<link href="doxygen.css" rel="stylesheet" type="text/css" />
|
||||
<link href="doxygen-awesome.css" rel="stylesheet" type="text/css"/>
|
||||
</head>
|
||||
<body>
|
||||
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
|
||||
<div id="titlearea">
|
||||
<table cellspacing="0" cellpadding="0">
|
||||
<tbody>
|
||||
<tr id="projectrow">
|
||||
<td id="projectalign">
|
||||
<div id="projectname">Penning Trap Simulation
|
||||
</div>
|
||||
<div id="projectbrief">Simulate particle behavior inside a Penning Trap</div>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
<!-- end header part -->
|
||||
<!-- Generated by Doxygen 1.9.6 -->
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
||||
var searchBox = new SearchBox("searchBox", "search/",'.html');
|
||||
/* @license-end */
|
||||
</script>
|
||||
<script type="text/javascript" src="menudata.js"></script>
|
||||
<script type="text/javascript" src="menu.js"></script>
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
||||
$(function() {
|
||||
initMenu('',true,false,'search.php','Search');
|
||||
$(document).ready(function() { init_search(); });
|
||||
});
|
||||
/* @license-end */
|
||||
</script>
|
||||
<div id="main-nav"></div>
|
||||
</div><!-- top -->
|
||||
<div id="side-nav" class="ui-resizable side-nav-resizable">
|
||||
<div id="nav-tree">
|
||||
<div id="nav-tree-contents">
|
||||
<div id="nav-sync" class="sync"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="splitbar" style="-moz-user-select:none;"
|
||||
class="ui-resizable-handle">
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
||||
$(document).ready(function(){initNavTree('globals_type.html',''); initResizable(); });
|
||||
/* @license-end */
|
||||
</script>
|
||||
<div id="doc-content">
|
||||
<!-- window showing the filter options -->
|
||||
<div id="MSearchSelectWindow"
|
||||
onmouseover="return searchBox.OnSearchSelectShow()"
|
||||
onmouseout="return searchBox.OnSearchSelectHide()"
|
||||
onkeydown="return searchBox.OnSearchSelectKey(event)">
|
||||
</div>
|
||||
|
||||
<!-- iframe showing the search results (closed by default) -->
|
||||
<div id="MSearchResultsWindow">
|
||||
<div id="MSearchResults">
|
||||
<div class="SRPage">
|
||||
<div id="SRIndex">
|
||||
<div id="SRResults"></div>
|
||||
<div class="SRStatus" id="Loading">Loading...</div>
|
||||
<div class="SRStatus" id="Searching">Searching...</div>
|
||||
<div class="SRStatus" id="NoMatches">No Matches</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="contents">
|
||||
 <ul>
|
||||
<li>sim_arr : <a class="el" href="typedefs_8hpp.html#aec69d34220fff45de238b9e01f2686af">typedefs.hpp</a></li>
|
||||
<li>sim_cols : <a class="el" href="typedefs_8hpp.html#a46482a2697556c00556c9d73f461784f">typedefs.hpp</a></li>
|
||||
<li>sim_rows : <a class="el" href="typedefs_8hpp.html#a33418f31f28663b8414c8f7182998c22">typedefs.hpp</a></li>
|
||||
<li>simulation_t : <a class="el" href="typedefs_8hpp.html#a784799c37b5e4fb8bf4f6368e004dec6">typedefs.hpp</a></li>
|
||||
<li>vec3 : <a class="el" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">typedefs.hpp</a></li>
|
||||
</ul>
|
||||
</div><!-- contents -->
|
||||
</div><!-- doc-content -->
|
||||
<!-- start footer part -->
|
||||
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
|
||||
<ul>
|
||||
<li class="footer">Generated by <a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.9.6 </li>
|
||||
</ul>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
114
docs/globals_vars.html
Normal file
114
docs/globals_vars.html
Normal file
@@ -0,0 +1,114 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=11"/>
|
||||
<meta name="generator" content="Doxygen 1.9.6"/>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1"/>
|
||||
<title>Penning Trap Simulation: File Members</title>
|
||||
<link href="tabs.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="jquery.js"></script>
|
||||
<script type="text/javascript" src="dynsections.js"></script>
|
||||
<link href="navtree.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="resize.js"></script>
|
||||
<script type="text/javascript" src="navtreedata.js"></script>
|
||||
<script type="text/javascript" src="navtree.js"></script>
|
||||
<link href="search/search.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="search/searchdata.js"></script>
|
||||
<script type="text/javascript" src="search/search.js"></script>
|
||||
<script type="text/x-mathjax-config">
|
||||
MathJax.Hub.Config({
|
||||
extensions: ["tex2jax.js"],
|
||||
jax: ["input/TeX","output/HTML-CSS"],
|
||||
});
|
||||
</script>
|
||||
<script type="text/javascript" async="async" src="https://cdn.jsdelivr.net/npm/mathjax@2/MathJax.js"></script>
|
||||
<link href="doxygen.css" rel="stylesheet" type="text/css" />
|
||||
<link href="doxygen-awesome.css" rel="stylesheet" type="text/css"/>
|
||||
</head>
|
||||
<body>
|
||||
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
|
||||
<div id="titlearea">
|
||||
<table cellspacing="0" cellpadding="0">
|
||||
<tbody>
|
||||
<tr id="projectrow">
|
||||
<td id="projectalign">
|
||||
<div id="projectname">Penning Trap Simulation
|
||||
</div>
|
||||
<div id="projectbrief">Simulate particle behavior inside a Penning Trap</div>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
<!-- end header part -->
|
||||
<!-- Generated by Doxygen 1.9.6 -->
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
||||
var searchBox = new SearchBox("searchBox", "search/",'.html');
|
||||
/* @license-end */
|
||||
</script>
|
||||
<script type="text/javascript" src="menudata.js"></script>
|
||||
<script type="text/javascript" src="menu.js"></script>
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
||||
$(function() {
|
||||
initMenu('',true,false,'search.php','Search');
|
||||
$(document).ready(function() { init_search(); });
|
||||
});
|
||||
/* @license-end */
|
||||
</script>
|
||||
<div id="main-nav"></div>
|
||||
</div><!-- top -->
|
||||
<div id="side-nav" class="ui-resizable side-nav-resizable">
|
||||
<div id="nav-tree">
|
||||
<div id="nav-tree-contents">
|
||||
<div id="nav-sync" class="sync"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="splitbar" style="-moz-user-select:none;"
|
||||
class="ui-resizable-handle">
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
||||
$(document).ready(function(){initNavTree('globals_vars.html',''); initResizable(); });
|
||||
/* @license-end */
|
||||
</script>
|
||||
<div id="doc-content">
|
||||
<!-- window showing the filter options -->
|
||||
<div id="MSearchSelectWindow"
|
||||
onmouseover="return searchBox.OnSearchSelectShow()"
|
||||
onmouseout="return searchBox.OnSearchSelectHide()"
|
||||
onkeydown="return searchBox.OnSearchSelectKey(event)">
|
||||
</div>
|
||||
|
||||
<!-- iframe showing the search results (closed by default) -->
|
||||
<div id="MSearchResultsWindow">
|
||||
<div id="MSearchResults">
|
||||
<div class="SRPage">
|
||||
<div id="SRIndex">
|
||||
<div id="SRResults"></div>
|
||||
<div class="SRStatus" id="Loading">Loading...</div>
|
||||
<div class="SRStatus" id="Searching">Searching...</div>
|
||||
<div class="SRStatus" id="NoMatches">No Matches</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="contents">
|
||||
 <ul>
|
||||
<li>p1 : <a class="el" href="main_8cpp.html#a2efa69bb9d93049429ce4637075f1d30">main.cpp</a></li>
|
||||
<li>p2 : <a class="el" href="main_8cpp.html#ac70b61df65f4336f57ea9b4c35250df7">main.cpp</a></li>
|
||||
</ul>
|
||||
</div><!-- contents -->
|
||||
</div><!-- doc-content -->
|
||||
<!-- start footer part -->
|
||||
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
|
||||
<ul>
|
||||
<li class="footer">Generated by <a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.9.6 </li>
|
||||
</ul>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
@@ -101,8 +101,68 @@ $(document).ready(function(){initNavTree('index.html',''); initResizable(); });
|
||||
<div class="headertitle"><div class="title">Penning trap simulation </div></div>
|
||||
</div><!--header-->
|
||||
<div class="contents">
|
||||
<div class="textblock"><p><a class="anchor" id="md_README"></a> </p>
|
||||
<div class="textblock"><p><a class="anchor" id="md_README"></a> </p><div class="image">
|
||||
<img src="100_particles.gif" alt=""/>
|
||||
</div>
|
||||
<p><a href="https://github.uio.no/FYS3150-G2-2023/Project-3">Repo</a></p>
|
||||
<p><a href="https://pages.github.uio.no/FYS3150-G2-2023/Project-3/">Documentation</a></p>
|
||||
<h1><a class="anchor" id="autotoc_md1"></a>
|
||||
Requirements</h1>
|
||||
<h2><a class="anchor" id="autotoc_md2"></a>
|
||||
Operating systems</h2>
|
||||
<ul>
|
||||
<li>Linux<ul>
|
||||
<li>Has been tested on <a href="https://fedoraproject.org/">Fedora 38</a></li>
|
||||
<li>Will most likely work on other Linux distributions</li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>MacOS<ul>
|
||||
<li>Might work, but hasn't been tested</li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>Windows<ul>
|
||||
<li>Will most likely not work</li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
<h2><a class="anchor" id="autotoc_md3"></a>
|
||||
Libraries</h2>
|
||||
<ul>
|
||||
<li>Python<ul>
|
||||
<li><a href="https://matplotlib.org/">matplotlib</a></li>
|
||||
<li><a href="https://numpy.org/">numpy</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>C++<ul>
|
||||
<li><a href="https://www.openmp.org/">openmp</a></li>
|
||||
<li><a href="https://arma.sourceforge.net/">armadillo</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
<h1><a class="anchor" id="autotoc_md4"></a>
|
||||
Compiling</h1>
|
||||
<p>Compiling is as easy as running this command while being inside the src directory:</p>
|
||||
<div class="fragment"><div class="line">make</div>
|
||||
</div><!-- fragment --><h1><a class="anchor" id="autotoc_md5"></a>
|
||||
Running programs</h1>
|
||||
<h2><a class="anchor" id="autotoc_md6"></a>
|
||||
C++ binaries</h2>
|
||||
<p>To run <b>main</b> or <b>test_suite</b>, just run this command while being inside src:</p>
|
||||
<div class="fragment"><div class="line">./<program-name></div>
|
||||
</div><!-- fragment --><h2><a class="anchor" id="autotoc_md7"></a>
|
||||
Python scripts</h2>
|
||||
<h3><a class="anchor" id="autotoc_md8"></a>
|
||||
Install libraries</h3>
|
||||
<p>Before running the scripts, make sure that all libraries are installed. Using pip, you can install all requirements like this:</p>
|
||||
<div class="fragment"><div class="line">pip install -r requirements.txt</div>
|
||||
</div><!-- fragment --><p>This recursively install all the packages that are listed in <b>requirements.txt</b>.</p>
|
||||
<h3><a class="anchor" id="autotoc_md9"></a>
|
||||
Running scripts</h3>
|
||||
<p>For the Python scripts, run them from the src directory like this:</p>
|
||||
<div class="fragment"><div class="line">python scripts/<script-name></div>
|
||||
</div><!-- fragment --><p>If you have any problems running the scripts, you might have to run this instead:</p>
|
||||
<div class="fragment"><div class="line">python3 scripts/<script-name></div>
|
||||
</div><!-- fragment --><h1><a class="anchor" id="autotoc_md10"></a>
|
||||
Credits</h1>
|
||||
<p>The Doxygen theme used here is <a href="https://github.com/jothepro/doxygen-awesome-css">doxygen-awesome-css</a>. </p>
|
||||
</div></div><!-- PageDoc -->
|
||||
|
||||
@@ -99,31 +99,146 @@ $(document).ready(function(){initNavTree('main_8cpp.html',''); initResizable();
|
||||
|
||||
<div class="header">
|
||||
<div class="summary">
|
||||
<a href="#func-members">Functions</a> </div>
|
||||
<a href="#define-members">Macros</a> |
|
||||
<a href="#func-members">Functions</a> |
|
||||
<a href="#var-members">Variables</a> </div>
|
||||
<div class="headertitle"><div class="title">main.cpp File Reference</div></div>
|
||||
</div><!--header-->
|
||||
<div class="contents">
|
||||
|
||||
<p>The main program for this project.
|
||||
<a href="#details">More...</a></p>
|
||||
|
||||
<div class="textblock"><code>#include <cmath></code><br />
|
||||
<code>#include <complex></code><br />
|
||||
<code>#include <fstream></code><br />
|
||||
<code>#include <omp.h></code><br />
|
||||
<code>#include <string></code><br />
|
||||
<code>#include <vector></code><br />
|
||||
<code>#include "<a class="el" href="PenningTrap_8hpp_source.html">PenningTrap.hpp</a>"</code><br />
|
||||
<code>#include "<a class="el" href="constants_8hpp_source.html">constants.hpp</a>"</code><br />
|
||||
<code>#include "<a class="el" href="utils_8hpp_source.html">utils.hpp</a>"</code><br />
|
||||
</div>
|
||||
<p><a href="main_8cpp_source.html">Go to the source code of this file.</a></p>
|
||||
<table class="memberdecls">
|
||||
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="define-members" name="define-members"></a>
|
||||
Macros</h2></td></tr>
|
||||
<tr class="memitem:a7b24a37e8ce9d243351bfc9b24945e63"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="main_8cpp.html#a7b24a37e8ce9d243351bfc9b24945e63">PARTICLES</a>   100</td></tr>
|
||||
<tr class="separator:a7b24a37e8ce9d243351bfc9b24945e63"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:a0240ac851181b84ac374872dc5434ee4"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="main_8cpp.html#a0240ac851181b84ac374872dc5434ee4">N</a>   40000</td></tr>
|
||||
<tr class="separator:a0240ac851181b84ac374872dc5434ee4"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
</table><table class="memberdecls">
|
||||
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="func-members" name="func-members"></a>
|
||||
Functions</h2></td></tr>
|
||||
<tr class="memitem:a8d92fb2ad085065fbd14718647551657"><td class="memItemLeft" align="right" valign="top"><a class="el" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="main_8cpp.html#a8d92fb2ad085065fbd14718647551657">analytical_solution_particle_1</a> (double t)</td></tr>
|
||||
<tr class="memdesc:a8d92fb2ad085065fbd14718647551657"><td class="mdescLeft"> </td><td class="mdescRight">The analytical solution for particle p1. <br /></td></tr>
|
||||
<tr class="separator:a8d92fb2ad085065fbd14718647551657"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:a8fdbe2d5a872e50ef5ec1263243589d6"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="main_8cpp.html#a8fdbe2d5a872e50ef5ec1263243589d6">simulate_single_particle</a> ()</td></tr>
|
||||
<tr class="memdesc:a8fdbe2d5a872e50ef5ec1263243589d6"><td class="mdescLeft"> </td><td class="mdescRight">Simulate a single particle over the period of 50 \( \mu s \). <br /></td></tr>
|
||||
<tr class="separator:a8fdbe2d5a872e50ef5ec1263243589d6"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:a783789519f97c6430081171cacb0ffb1"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="main_8cpp.html#a783789519f97c6430081171cacb0ffb1">simulate_two_particles</a> ()</td></tr>
|
||||
<tr class="memdesc:a783789519f97c6430081171cacb0ffb1"><td class="mdescLeft"> </td><td class="mdescRight">Simulate 2 particles over the period of 50 \( \mu s \) with and without particle interactions. <br /></td></tr>
|
||||
<tr class="separator:a783789519f97c6430081171cacb0ffb1"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:ac67e0d59227856c4d42e7d01c75e0ad2"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="main_8cpp.html#ac67e0d59227856c4d42e7d01c75e0ad2">simulate_single_particle_with_different_steps</a> ()</td></tr>
|
||||
<tr class="memdesc:ac67e0d59227856c4d42e7d01c75e0ad2"><td class="mdescLeft"> </td><td class="mdescRight">Simulate a single particle over 50 \( \mu s \) using different amount of steps and different methods. <br /></td></tr>
|
||||
<tr class="separator:ac67e0d59227856c4d42e7d01c75e0ad2"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:a213713d6ecc02a32b588ffd179dc7513"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="main_8cpp.html#a213713d6ecc02a32b588ffd179dc7513">simulate_100_particles</a> ()</td></tr>
|
||||
<tr class="memdesc:a213713d6ecc02a32b588ffd179dc7513"><td class="mdescLeft"> </td><td class="mdescRight">Simulate 100 particles over 50 \( \mu s \). <br /></td></tr>
|
||||
<tr class="separator:a213713d6ecc02a32b588ffd179dc7513"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:a6b38b477c18e2f4268779751a88edab1"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="main_8cpp.html#a6b38b477c18e2f4268779751a88edab1">potential_resonance_wide_sweep</a> ()</td></tr>
|
||||
<tr class="memdesc:a6b38b477c18e2f4268779751a88edab1"><td class="mdescLeft"> </td><td class="mdescRight">Simulate 100 particles over 500 \( \mu s \) using a time dependent potential. <br /></td></tr>
|
||||
<tr class="separator:a6b38b477c18e2f4268779751a88edab1"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:a33d9b1c76c3c80902f89a58b1a6d96ea"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="main_8cpp.html#a33d9b1c76c3c80902f89a58b1a6d96ea">potential_resonance_narrow_sweep</a> ()</td></tr>
|
||||
<tr class="memdesc:a33d9b1c76c3c80902f89a58b1a6d96ea"><td class="mdescLeft"> </td><td class="mdescRight">Simulate 100 particles over 500 \( \mu s \) using a time dependent potential. <br /></td></tr>
|
||||
<tr class="separator:a33d9b1c76c3c80902f89a58b1a6d96ea"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:ac1816f70ec612edc27848ef7f0875fdb"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="main_8cpp.html#ac1816f70ec612edc27848ef7f0875fdb">potential_resonance_narrow_sweep_interaction</a> ()</td></tr>
|
||||
<tr class="memdesc:ac1816f70ec612edc27848ef7f0875fdb"><td class="mdescLeft"> </td><td class="mdescRight">Simulate 100 particles over 500 \( \mu s \) using a time dependent potential. <br /></td></tr>
|
||||
<tr class="separator:ac1816f70ec612edc27848ef7f0875fdb"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:ae66f6b31b5ad750f1fe042a706a4e3d4"><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="main_8cpp.html#ae66f6b31b5ad750f1fe042a706a4e3d4">main</a> ()</td></tr>
|
||||
<tr class="separator:ae66f6b31b5ad750f1fe042a706a4e3d4"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
</table><table class="memberdecls">
|
||||
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="var-members" name="var-members"></a>
|
||||
Variables</h2></td></tr>
|
||||
<tr class="memitem:a2efa69bb9d93049429ce4637075f1d30"><td class="memItemLeft" align="right" valign="top"><a id="a2efa69bb9d93049429ce4637075f1d30" name="a2efa69bb9d93049429ce4637075f1d30"></a>
|
||||
<a class="el" href="classParticle.html">Particle</a> </td><td class="memItemRight" valign="bottom"><b>p1</b> (<a class="el" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a>{20., 0., 20.}, <a class="el" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a>{0., 25., 0.})</td></tr>
|
||||
<tr class="memdesc:a2efa69bb9d93049429ce4637075f1d30"><td class="mdescLeft"> </td><td class="mdescRight"><a class="el" href="classParticle.html" title="A class that holds attributes of a particle.">Particle</a> 1. <br /></td></tr>
|
||||
<tr class="separator:a2efa69bb9d93049429ce4637075f1d30"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
<tr class="memitem:ac70b61df65f4336f57ea9b4c35250df7"><td class="memItemLeft" align="right" valign="top"><a id="ac70b61df65f4336f57ea9b4c35250df7" name="ac70b61df65f4336f57ea9b4c35250df7"></a>
|
||||
<a class="el" href="classParticle.html">Particle</a> </td><td class="memItemRight" valign="bottom"><b>p2</b> (<a class="el" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a>{25., 25., 0.}, <a class="el" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a>{0., 40., 5.})</td></tr>
|
||||
<tr class="memdesc:ac70b61df65f4336f57ea9b4c35250df7"><td class="mdescLeft"> </td><td class="mdescRight"><a class="el" href="classParticle.html" title="A class that holds attributes of a particle.">Particle</a> 2. <br /></td></tr>
|
||||
<tr class="separator:ac70b61df65f4336f57ea9b4c35250df7"><td class="memSeparator" colspan="2"> </td></tr>
|
||||
</table>
|
||||
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
|
||||
<div class="textblock"><p>The main program for this project. </p>
|
||||
<dl class="section author"><dt>Author</dt><dd>Cory Alexander Balaton (coryab) </dd>
|
||||
<dd>
|
||||
Janita Ovidie Sandtrøen Willumsen (janitaws)</dd></dl>
|
||||
<dl class="section version"><dt>Version</dt><dd>0.1</dd></dl>
|
||||
<dl class="bug"><dt><b><a class="el" href="bug.html#_bug000005">Bug:</a></b></dt><dd>No known bugs </dd></dl>
|
||||
<dl class="section version"><dt>Version</dt><dd>1.0</dd></dl>
|
||||
<dl class="bug"><dt><b><a class="el" href="bug.html#_bug000006">Bug:</a></b></dt><dd>No known bugs </dd></dl>
|
||||
|
||||
<p class="definition">Definition in file <a class="el" href="main_8cpp_source.html">main.cpp</a>.</p>
|
||||
</div><h2 class="groupheader">Function Documentation</h2>
|
||||
</div><h2 class="groupheader">Macro Definition Documentation</h2>
|
||||
<a id="a0240ac851181b84ac374872dc5434ee4" name="a0240ac851181b84ac374872dc5434ee4"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#a0240ac851181b84ac374872dc5434ee4">◆ </a></span>N</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
<table class="memname">
|
||||
<tr>
|
||||
<td class="memname">#define N   40000</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
|
||||
<p class="definition">Definition at line <a class="el" href="main_8cpp_source.html#l00025">25</a> of file <a class="el" href="main_8cpp_source.html">main.cpp</a>.</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<a id="a7b24a37e8ce9d243351bfc9b24945e63" name="a7b24a37e8ce9d243351bfc9b24945e63"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#a7b24a37e8ce9d243351bfc9b24945e63">◆ </a></span>PARTICLES</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
<table class="memname">
|
||||
<tr>
|
||||
<td class="memname">#define PARTICLES   100</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
|
||||
<p class="definition">Definition at line <a class="el" href="main_8cpp_source.html#l00024">24</a> of file <a class="el" href="main_8cpp_source.html">main.cpp</a>.</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<h2 class="groupheader">Function Documentation</h2>
|
||||
<a id="a8d92fb2ad085065fbd14718647551657" name="a8d92fb2ad085065fbd14718647551657"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#a8d92fb2ad085065fbd14718647551657">◆ </a></span>analytical_solution_particle_1()</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
<table class="memname">
|
||||
<tr>
|
||||
<td class="memname"><a class="el" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> analytical_solution_particle_1 </td>
|
||||
<td>(</td>
|
||||
<td class="paramtype">double </td>
|
||||
<td class="paramname"><em>t</em></td><td>)</td>
|
||||
<td></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
|
||||
<p>The analytical solution for particle p1. </p>
|
||||
<dl class="params"><dt>Parameters</dt><dd>
|
||||
<table class="params">
|
||||
<tr><td class="paramname">t</td><td>Time</td></tr>
|
||||
</table>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl class="section return"><dt>Returns</dt><dd>vec3 </dd></dl>
|
||||
|
||||
<p class="definition">Definition at line <a class="el" href="main_8cpp_source.html#l00037">37</a> of file <a class="el" href="main_8cpp_source.html">main.cpp</a>.</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<a id="ae66f6b31b5ad750f1fe042a706a4e3d4" name="ae66f6b31b5ad750f1fe042a706a4e3d4"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#ae66f6b31b5ad750f1fe042a706a4e3d4">◆ </a></span>main()</h2>
|
||||
|
||||
@@ -139,7 +254,157 @@ Janita Ovidie Sandtrøen Willumsen (janitaws)</dd></dl>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
|
||||
<p class="definition">Definition at line <a class="el" href="main_8cpp_source.html#l00013">13</a> of file <a class="el" href="main_8cpp_source.html">main.cpp</a>.</p>
|
||||
<p class="definition">Definition at line <a class="el" href="main_8cpp_source.html#l00309">309</a> of file <a class="el" href="main_8cpp_source.html">main.cpp</a>.</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<a id="a33d9b1c76c3c80902f89a58b1a6d96ea" name="a33d9b1c76c3c80902f89a58b1a6d96ea"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#a33d9b1c76c3c80902f89a58b1a6d96ea">◆ </a></span>potential_resonance_narrow_sweep()</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
<table class="memname">
|
||||
<tr>
|
||||
<td class="memname">void potential_resonance_narrow_sweep </td>
|
||||
<td>(</td>
|
||||
<td class="paramname"></td><td>)</td>
|
||||
<td></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
|
||||
<p>Simulate 100 particles over 500 \( \mu s \) using a time dependent potential. </p>
|
||||
<p>The simulation sweeps over different frequencies in [1., 1.7] MHz. </p>
|
||||
|
||||
<p class="definition">Definition at line <a class="el" href="main_8cpp_source.html#l00206">206</a> of file <a class="el" href="main_8cpp_source.html">main.cpp</a>.</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<a id="ac1816f70ec612edc27848ef7f0875fdb" name="ac1816f70ec612edc27848ef7f0875fdb"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#ac1816f70ec612edc27848ef7f0875fdb">◆ </a></span>potential_resonance_narrow_sweep_interaction()</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
<table class="memname">
|
||||
<tr>
|
||||
<td class="memname">void potential_resonance_narrow_sweep_interaction </td>
|
||||
<td>(</td>
|
||||
<td class="paramname"></td><td>)</td>
|
||||
<td></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
|
||||
<p>Simulate 100 particles over 500 \( \mu s \) using a time dependent potential. </p>
|
||||
<p>The simulation sweeps over different frequencies in [1., 1.7] MHz. </p>
|
||||
|
||||
<p class="definition">Definition at line <a class="el" href="main_8cpp_source.html#l00262">262</a> of file <a class="el" href="main_8cpp_source.html">main.cpp</a>.</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<a id="a6b38b477c18e2f4268779751a88edab1" name="a6b38b477c18e2f4268779751a88edab1"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#a6b38b477c18e2f4268779751a88edab1">◆ </a></span>potential_resonance_wide_sweep()</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
<table class="memname">
|
||||
<tr>
|
||||
<td class="memname">void potential_resonance_wide_sweep </td>
|
||||
<td>(</td>
|
||||
<td class="paramname"></td><td>)</td>
|
||||
<td></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
|
||||
<p>Simulate 100 particles over 500 \( \mu s \) using a time dependent potential. </p>
|
||||
<p>The simulation sweeps over different frequencies in [0.2, 2.5] MHz. </p>
|
||||
|
||||
<p class="definition">Definition at line <a class="el" href="main_8cpp_source.html#l00149">149</a> of file <a class="el" href="main_8cpp_source.html">main.cpp</a>.</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<a id="a213713d6ecc02a32b588ffd179dc7513" name="a213713d6ecc02a32b588ffd179dc7513"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#a213713d6ecc02a32b588ffd179dc7513">◆ </a></span>simulate_100_particles()</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
<table class="memname">
|
||||
<tr>
|
||||
<td class="memname">void simulate_100_particles </td>
|
||||
<td>(</td>
|
||||
<td class="paramname"></td><td>)</td>
|
||||
<td></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
|
||||
<p>Simulate 100 particles over 50 \( \mu s \). </p>
|
||||
|
||||
<p class="definition">Definition at line <a class="el" href="main_8cpp_source.html#l00132">132</a> of file <a class="el" href="main_8cpp_source.html">main.cpp</a>.</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<a id="a8fdbe2d5a872e50ef5ec1263243589d6" name="a8fdbe2d5a872e50ef5ec1263243589d6"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#a8fdbe2d5a872e50ef5ec1263243589d6">◆ </a></span>simulate_single_particle()</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
<table class="memname">
|
||||
<tr>
|
||||
<td class="memname">void simulate_single_particle </td>
|
||||
<td>(</td>
|
||||
<td class="paramname"></td><td>)</td>
|
||||
<td></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
|
||||
<p>Simulate a single particle over the period of 50 \( \mu s \). </p>
|
||||
|
||||
<p class="definition">Definition at line <a class="el" href="main_8cpp_source.html#l00054">54</a> of file <a class="el" href="main_8cpp_source.html">main.cpp</a>.</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<a id="ac67e0d59227856c4d42e7d01c75e0ad2" name="ac67e0d59227856c4d42e7d01c75e0ad2"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#ac67e0d59227856c4d42e7d01c75e0ad2">◆ </a></span>simulate_single_particle_with_different_steps()</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
<table class="memname">
|
||||
<tr>
|
||||
<td class="memname">void simulate_single_particle_with_different_steps </td>
|
||||
<td>(</td>
|
||||
<td class="paramname"></td><td>)</td>
|
||||
<td></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
|
||||
<p>Simulate a single particle over 50 \( \mu s \) using different amount of steps and different methods. </p>
|
||||
|
||||
<p class="definition">Definition at line <a class="el" href="main_8cpp_source.html#l00087">87</a> of file <a class="el" href="main_8cpp_source.html">main.cpp</a>.</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<a id="a783789519f97c6430081171cacb0ffb1" name="a783789519f97c6430081171cacb0ffb1"></a>
|
||||
<h2 class="memtitle"><span class="permalink"><a href="#a783789519f97c6430081171cacb0ffb1">◆ </a></span>simulate_two_particles()</h2>
|
||||
|
||||
<div class="memitem">
|
||||
<div class="memproto">
|
||||
<table class="memname">
|
||||
<tr>
|
||||
<td class="memname">void simulate_two_particles </td>
|
||||
<td>(</td>
|
||||
<td class="paramname"></td><td>)</td>
|
||||
<td></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div><div class="memdoc">
|
||||
|
||||
<p>Simulate 2 particles over the period of 50 \( \mu s \) with and without particle interactions. </p>
|
||||
|
||||
<p class="definition">Definition at line <a class="el" href="main_8cpp_source.html#l00069">69</a> of file <a class="el" href="main_8cpp_source.html">main.cpp</a>.</p>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
13
docs/main_8cpp.js
Normal file
13
docs/main_8cpp.js
Normal file
@@ -0,0 +1,13 @@
|
||||
var main_8cpp =
|
||||
[
|
||||
[ "analytical_solution_particle_1", "main_8cpp.html#a8d92fb2ad085065fbd14718647551657", null ],
|
||||
[ "potential_resonance_narrow_sweep", "main_8cpp.html#a33d9b1c76c3c80902f89a58b1a6d96ea", null ],
|
||||
[ "potential_resonance_narrow_sweep_interaction", "main_8cpp.html#ac1816f70ec612edc27848ef7f0875fdb", null ],
|
||||
[ "potential_resonance_wide_sweep", "main_8cpp.html#a6b38b477c18e2f4268779751a88edab1", null ],
|
||||
[ "simulate_100_particles", "main_8cpp.html#a213713d6ecc02a32b588ffd179dc7513", null ],
|
||||
[ "simulate_single_particle", "main_8cpp.html#a8fdbe2d5a872e50ef5ec1263243589d6", null ],
|
||||
[ "simulate_single_particle_with_different_steps", "main_8cpp.html#ac67e0d59227856c4d42e7d01c75e0ad2", null ],
|
||||
[ "simulate_two_particles", "main_8cpp.html#a783789519f97c6430081171cacb0ffb1", null ],
|
||||
[ "p1", "main_8cpp.html#a2efa69bb9d93049429ce4637075f1d30", null ],
|
||||
[ "p2", "main_8cpp.html#ac70b61df65f4336f57ea9b4c35250df7", null ]
|
||||
];
|
||||
@@ -102,10 +102,348 @@ $(document).ready(function(){initNavTree('main_8cpp_source.html',''); initResiza
|
||||
</div><!--header-->
|
||||
<div class="contents">
|
||||
<a href="main_8cpp.html">Go to the documentation of this file.</a><div class="fragment"><div class="line"><a id="l00001" name="l00001"></a><span class="lineno"> 1</span> </div>
|
||||
<div class="line"><a id="l00013" name="l00013"></a><span class="lineno"> 13</span><span class="keywordtype">int</span> main() </div>
|
||||
<div class="line"><a id="l00014" name="l00014"></a><span class="lineno"> 14</span>{</div>
|
||||
<div class="line"><a id="l00015" name="l00015"></a><span class="lineno"> 15</span> <span class="keywordflow">return</span> 0;</div>
|
||||
<div class="line"><a id="l00016" name="l00016"></a><span class="lineno"> 16</span>}</div>
|
||||
<div class="line"><a id="l00013" name="l00013"></a><span class="lineno"> 13</span><span class="preprocessor">#include <cmath></span></div>
|
||||
<div class="line"><a id="l00014" name="l00014"></a><span class="lineno"> 14</span><span class="preprocessor">#include <complex></span></div>
|
||||
<div class="line"><a id="l00015" name="l00015"></a><span class="lineno"> 15</span><span class="preprocessor">#include <fstream></span></div>
|
||||
<div class="line"><a id="l00016" name="l00016"></a><span class="lineno"> 16</span><span class="preprocessor">#include <omp.h></span></div>
|
||||
<div class="line"><a id="l00017" name="l00017"></a><span class="lineno"> 17</span><span class="preprocessor">#include <string></span></div>
|
||||
<div class="line"><a id="l00018" name="l00018"></a><span class="lineno"> 18</span><span class="preprocessor">#include <vector></span></div>
|
||||
<div class="line"><a id="l00019" name="l00019"></a><span class="lineno"> 19</span> </div>
|
||||
<div class="line"><a id="l00020" name="l00020"></a><span class="lineno"> 20</span><span class="preprocessor">#include "<a class="code" href="PenningTrap_8hpp.html">PenningTrap.hpp</a>"</span></div>
|
||||
<div class="line"><a id="l00021" name="l00021"></a><span class="lineno"> 21</span><span class="preprocessor">#include "<a class="code" href="constants_8hpp.html">constants.hpp</a>"</span></div>
|
||||
<div class="line"><a id="l00022" name="l00022"></a><span class="lineno"> 22</span><span class="preprocessor">#include "<a class="code" href="utils_8hpp.html">utils.hpp</a>"</span></div>
|
||||
<div class="line"><a id="l00023" name="l00023"></a><span class="lineno"> 23</span> </div>
|
||||
<div class="line"><a id="l00024" name="l00024"></a><span class="lineno"> 24</span><span class="preprocessor">#define PARTICLES 100</span></div>
|
||||
<div class="line"><a id="l00025" name="l00025"></a><span class="lineno"> 25</span><span class="preprocessor">#define N 40000</span></div>
|
||||
<div class="line"><a id="l00026" name="l00026"></a><span class="lineno"> 26</span> </div>
|
||||
<div class="line"><a id="l00027" name="l00027"></a><span class="lineno"> 27</span><span class="comment">// Particles used for testing</span></div>
|
||||
<div class="line"><a id="l00028" name="l00028"></a><span class="lineno"><a class="line" href="main_8cpp.html#a2efa69bb9d93049429ce4637075f1d30"> 28</a></span><a class="code hl_class" href="classParticle.html">Particle</a> <a class="code hl_variable" href="main_8cpp.html#a2efa69bb9d93049429ce4637075f1d30">p1</a>(<a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a>{20., 0., 20.}, <a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a>{0., 25., 0.}); </div>
|
||||
<div class="line"><a id="l00029" name="l00029"></a><span class="lineno"><a class="line" href="main_8cpp.html#ac70b61df65f4336f57ea9b4c35250df7"> 29</a></span><a class="code hl_class" href="classParticle.html">Particle</a> <a class="code hl_variable" href="main_8cpp.html#ac70b61df65f4336f57ea9b4c35250df7">p2</a>(<a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a>{25., 25., 0.}, <a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a>{0., 40., 5.}); </div>
|
||||
<div class="line"><a id="l00030" name="l00030"></a><span class="lineno"> 30</span> </div>
|
||||
<div class="line"><a id="l00037" name="l00037"></a><span class="lineno"><a class="line" href="main_8cpp.html#a8d92fb2ad085065fbd14718647551657"> 37</a></span><a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> <a class="code hl_function" href="main_8cpp.html#a8d92fb2ad085065fbd14718647551657">analytical_solution_particle_1</a>(<span class="keywordtype">double</span> t)</div>
|
||||
<div class="line"><a id="l00038" name="l00038"></a><span class="lineno"> 38</span>{</div>
|
||||
<div class="line"><a id="l00039" name="l00039"></a><span class="lineno"> 39</span> <span class="keywordtype">double</span> w_0 = <a class="code hl_define" href="constants_8hpp.html#a0acb682b8260ab1c60b918599864e2e5">T</a> / <a class="code hl_define" href="constants_8hpp.html#a2ff491cc7958ffd5e749c518a4a60ec8">CA_MASS</a>;</div>
|
||||
<div class="line"><a id="l00040" name="l00040"></a><span class="lineno"> 40</span> <span class="keywordtype">double</span> w_z2 = (50. * <a class="code hl_define" href="constants_8hpp.html#af40a326b23c68a27cebe60f16634a2cb">V</a> / 1000.) / (<a class="code hl_define" href="constants_8hpp.html#a2ff491cc7958ffd5e749c518a4a60ec8">CA_MASS</a> * 500. * 500.);</div>
|
||||
<div class="line"><a id="l00041" name="l00041"></a><span class="lineno"> 41</span> <span class="keywordtype">double</span> w_p = (w_0 + std::sqrt(w_0 * w_0 - 2. * w_z2)) / 2.;</div>
|
||||
<div class="line"><a id="l00042" name="l00042"></a><span class="lineno"> 42</span> <span class="keywordtype">double</span> w_n = (w_0 - std::sqrt(w_0 * w_0 - 2. * w_z2)) / 2.;</div>
|
||||
<div class="line"><a id="l00043" name="l00043"></a><span class="lineno"> 43</span> <span class="keywordtype">double</span> A_p = (25. + w_n * 20.) / (w_n - w_p);</div>
|
||||
<div class="line"><a id="l00044" name="l00044"></a><span class="lineno"> 44</span> <span class="keywordtype">double</span> A_n = -(25. + w_p * 20.) / (w_n - w_p);</div>
|
||||
<div class="line"><a id="l00045" name="l00045"></a><span class="lineno"> 45</span> std::complex<double> f =</div>
|
||||
<div class="line"><a id="l00046" name="l00046"></a><span class="lineno"> 46</span> A_p * std::exp(std::complex<double>(0., -w_p * t))</div>
|
||||
<div class="line"><a id="l00047" name="l00047"></a><span class="lineno"> 47</span> + A_n * std::exp(std::complex<double>(0., -w_n * t));</div>
|
||||
<div class="line"><a id="l00048" name="l00048"></a><span class="lineno"> 48</span> <a class="code hl_typedef" href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a> res{std::real(f), std::imag(f), 20. * std::cos(std::sqrt(w_z2) * t)};</div>
|
||||
<div class="line"><a id="l00049" name="l00049"></a><span class="lineno"> 49</span> <span class="keywordflow">return</span> res;</div>
|
||||
<div class="line"><a id="l00050" name="l00050"></a><span class="lineno"> 50</span>}</div>
|
||||
<div class="line"><a id="l00051" name="l00051"></a><span class="lineno"> 51</span> </div>
|
||||
<div class="line"><a id="l00054" name="l00054"></a><span class="lineno"><a class="line" href="main_8cpp.html#a8fdbe2d5a872e50ef5ec1263243589d6"> 54</a></span><span class="keywordtype">void</span> <a class="code hl_function" href="main_8cpp.html#a8fdbe2d5a872e50ef5ec1263243589d6">simulate_single_particle</a>()</div>
|
||||
<div class="line"><a id="l00055" name="l00055"></a><span class="lineno"> 55</span>{</div>
|
||||
<div class="line"><a id="l00056" name="l00056"></a><span class="lineno"> 56</span> <span class="comment">// Initialize trap with particle 1</span></div>
|
||||
<div class="line"><a id="l00057" name="l00057"></a><span class="lineno"> 57</span> <a class="code hl_class" href="classPenningTrap.html">PenningTrap</a> trap(std::vector<Particle>{<a class="code hl_variable" href="main_8cpp.html#a2efa69bb9d93049429ce4637075f1d30">p1</a>});</div>
|
||||
<div class="line"><a id="l00058" name="l00058"></a><span class="lineno"> 58</span> </div>
|
||||
<div class="line"><a id="l00059" name="l00059"></a><span class="lineno"> 59</span> <span class="keywordtype">double</span> time = 50.; <span class="comment">// microseconds</span></div>
|
||||
<div class="line"><a id="l00060" name="l00060"></a><span class="lineno"> 60</span> </div>
|
||||
<div class="line"><a id="l00061" name="l00061"></a><span class="lineno"> 61</span> <span class="comment">// Simulate and write results to file</span></div>
|
||||
<div class="line"><a id="l00062" name="l00062"></a><span class="lineno"> 62</span> trap.<a class="code hl_function" href="classPenningTrap.html#ad8bc4df7ab3eed53b16cfdff38e7760b">write_simulation_to_dir</a>(<span class="stringliteral">"output/simulate_single_particle"</span>, time, N,</div>
|
||||
<div class="line"><a id="l00063" name="l00063"></a><span class="lineno"> 63</span> <span class="stringliteral">"rk4"</span>, <span class="keyword">false</span>);</div>
|
||||
<div class="line"><a id="l00064" name="l00064"></a><span class="lineno"> 64</span>}</div>
|
||||
<div class="line"><a id="l00065" name="l00065"></a><span class="lineno"> 65</span> </div>
|
||||
<div class="line"><a id="l00069" name="l00069"></a><span class="lineno"><a class="line" href="main_8cpp.html#a783789519f97c6430081171cacb0ffb1"> 69</a></span><span class="keywordtype">void</span> <a class="code hl_function" href="main_8cpp.html#a783789519f97c6430081171cacb0ffb1">simulate_two_particles</a>()</div>
|
||||
<div class="line"><a id="l00070" name="l00070"></a><span class="lineno"> 70</span>{</div>
|
||||
<div class="line"><a id="l00071" name="l00071"></a><span class="lineno"> 71</span> <span class="comment">// Initialize traps with particles</span></div>
|
||||
<div class="line"><a id="l00072" name="l00072"></a><span class="lineno"> 72</span> <a class="code hl_class" href="classPenningTrap.html">PenningTrap</a> trap_no_interaction(std::vector<Particle>{<a class="code hl_variable" href="main_8cpp.html#a2efa69bb9d93049429ce4637075f1d30">p1</a>, <a class="code hl_variable" href="main_8cpp.html#ac70b61df65f4336f57ea9b4c35250df7">p2</a>});</div>
|
||||
<div class="line"><a id="l00073" name="l00073"></a><span class="lineno"> 73</span> <a class="code hl_class" href="classPenningTrap.html">PenningTrap</a> trap_with_interaction(std::vector<Particle>{<a class="code hl_variable" href="main_8cpp.html#a2efa69bb9d93049429ce4637075f1d30">p1</a>, <a class="code hl_variable" href="main_8cpp.html#ac70b61df65f4336f57ea9b4c35250df7">p2</a>});</div>
|
||||
<div class="line"><a id="l00074" name="l00074"></a><span class="lineno"> 74</span> </div>
|
||||
<div class="line"><a id="l00075" name="l00075"></a><span class="lineno"> 75</span> <span class="keywordtype">double</span> time = 50.; <span class="comment">// microseconds</span></div>
|
||||
<div class="line"><a id="l00076" name="l00076"></a><span class="lineno"> 76</span> </div>
|
||||
<div class="line"><a id="l00077" name="l00077"></a><span class="lineno"> 77</span> <span class="comment">// Simulate and write results to files</span></div>
|
||||
<div class="line"><a id="l00078" name="l00078"></a><span class="lineno"> 78</span> trap_no_interaction.<a class="code hl_function" href="classPenningTrap.html#ad8bc4df7ab3eed53b16cfdff38e7760b">write_simulation_to_dir</a>(</div>
|
||||
<div class="line"><a id="l00079" name="l00079"></a><span class="lineno"> 79</span> <span class="stringliteral">"output/simulate_2_particles/no_interaction"</span>, time, N, <span class="stringliteral">"rk4"</span>, <span class="keyword">false</span>);</div>
|
||||
<div class="line"><a id="l00080" name="l00080"></a><span class="lineno"> 80</span> trap_with_interaction.write_simulation_to_dir(</div>
|
||||
<div class="line"><a id="l00081" name="l00081"></a><span class="lineno"> 81</span> <span class="stringliteral">"output/simulate_2_particles/with_interaction"</span>, time, N);</div>
|
||||
<div class="line"><a id="l00082" name="l00082"></a><span class="lineno"> 82</span>}</div>
|
||||
<div class="line"><a id="l00083" name="l00083"></a><span class="lineno"> 83</span> </div>
|
||||
<div class="line"><a id="l00087" name="l00087"></a><span class="lineno"><a class="line" href="main_8cpp.html#ac67e0d59227856c4d42e7d01c75e0ad2"> 87</a></span><span class="keywordtype">void</span> <a class="code hl_function" href="main_8cpp.html#ac67e0d59227856c4d42e7d01c75e0ad2">simulate_single_particle_with_different_steps</a>()</div>
|
||||
<div class="line"><a id="l00088" name="l00088"></a><span class="lineno"> 88</span>{</div>
|
||||
<div class="line"><a id="l00089" name="l00089"></a><span class="lineno"> 89</span> <span class="keywordtype">double</span> time = 50.; <span class="comment">// microseconds</span></div>
|
||||
<div class="line"><a id="l00090" name="l00090"></a><span class="lineno"> 90</span> </div>
|
||||
<div class="line"><a id="l00091" name="l00091"></a><span class="lineno"> 91</span> std::ofstream ofile;</div>
|
||||
<div class="line"><a id="l00092" name="l00092"></a><span class="lineno"> 92</span> </div>
|
||||
<div class="line"><a id="l00093" name="l00093"></a><span class="lineno"> 93</span> <span class="comment">// Calculate relative error for RK4</span></div>
|
||||
<div class="line"><a id="l00094" name="l00094"></a><span class="lineno"> 94</span> std::string path = <span class="stringliteral">"output/relative_error/RK4/"</span>;</div>
|
||||
<div class="line"><a id="l00095" name="l00095"></a><span class="lineno"> 95</span> <a class="code hl_function" href="utils_8hpp.html#a6fdd7217b750aff5b6295ece7cbdeffa">mkpath</a>(path);</div>
|
||||
<div class="line"><a id="l00096" name="l00096"></a><span class="lineno"> 96</span><span class="preprocessor">#pragma omp parallel for</span></div>
|
||||
<div class="line"><a id="l00097" name="l00097"></a><span class="lineno"> 97</span> <span class="keywordflow">for</span> (<span class="keywordtype">int</span> i = 0; i < 4; i++) {</div>
|
||||
<div class="line"><a id="l00098" name="l00098"></a><span class="lineno"> 98</span> <span class="keywordtype">int</span> steps = 4000 * std::pow(2, i);</div>
|
||||
<div class="line"><a id="l00099" name="l00099"></a><span class="lineno"> 99</span> <span class="keywordtype">double</span> dt = time / (double)steps;</div>
|
||||
<div class="line"><a id="l00100" name="l00100"></a><span class="lineno"> 100</span> ofile.open(path + std::to_string(steps) + <span class="stringliteral">"_steps.txt"</span>);</div>
|
||||
<div class="line"><a id="l00101" name="l00101"></a><span class="lineno"> 101</span> <a class="code hl_class" href="classPenningTrap.html">PenningTrap</a> trap(std::vector<Particle>{<a class="code hl_variable" href="main_8cpp.html#a2efa69bb9d93049429ce4637075f1d30">p1</a>});</div>
|
||||
<div class="line"><a id="l00102" name="l00102"></a><span class="lineno"> 102</span> <a class="code hl_struct" href="structsimulation.html">simulation_t</a> res = trap.simulate(time, steps, <span class="stringliteral">"rk4"</span>, <span class="keyword">false</span>);</div>
|
||||
<div class="line"><a id="l00103" name="l00103"></a><span class="lineno"> 103</span> <span class="keywordflow">for</span> (<span class="keywordtype">int</span> i = 0; i < steps; i++) {</div>
|
||||
<div class="line"><a id="l00104" name="l00104"></a><span class="lineno"> 104</span> ofile << arma::norm(res.r_vecs[0][i]</div>
|
||||
<div class="line"><a id="l00105" name="l00105"></a><span class="lineno"> 105</span> - <a class="code hl_function" href="main_8cpp.html#a8d92fb2ad085065fbd14718647551657">analytical_solution_particle_1</a>(dt * i))</div>
|
||||
<div class="line"><a id="l00106" name="l00106"></a><span class="lineno"> 106</span> << <span class="charliteral">'\n'</span>;</div>
|
||||
<div class="line"><a id="l00107" name="l00107"></a><span class="lineno"> 107</span> }</div>
|
||||
<div class="line"><a id="l00108" name="l00108"></a><span class="lineno"> 108</span> ofile.close();</div>
|
||||
<div class="line"><a id="l00109" name="l00109"></a><span class="lineno"> 109</span> }</div>
|
||||
<div class="line"><a id="l00110" name="l00110"></a><span class="lineno"> 110</span> </div>
|
||||
<div class="line"><a id="l00111" name="l00111"></a><span class="lineno"> 111</span> <span class="comment">// Calculate relative error for forward Euler</span></div>
|
||||
<div class="line"><a id="l00112" name="l00112"></a><span class="lineno"> 112</span> path = <span class="stringliteral">"output/relative_error/euler/"</span>;</div>
|
||||
<div class="line"><a id="l00113" name="l00113"></a><span class="lineno"> 113</span> <a class="code hl_function" href="utils_8hpp.html#a6fdd7217b750aff5b6295ece7cbdeffa">mkpath</a>(path);</div>
|
||||
<div class="line"><a id="l00114" name="l00114"></a><span class="lineno"> 114</span><span class="preprocessor">#pragma omp parallel for</span></div>
|
||||
<div class="line"><a id="l00115" name="l00115"></a><span class="lineno"> 115</span> <span class="keywordflow">for</span> (<span class="keywordtype">int</span> i = 0; i < 4; i++) {</div>
|
||||
<div class="line"><a id="l00116" name="l00116"></a><span class="lineno"> 116</span> <span class="keywordtype">int</span> steps = 4000 * std::pow(2, i);</div>
|
||||
<div class="line"><a id="l00117" name="l00117"></a><span class="lineno"> 117</span> <span class="keywordtype">double</span> dt = time / (double)steps;</div>
|
||||
<div class="line"><a id="l00118" name="l00118"></a><span class="lineno"> 118</span> ofile.open(path + std::to_string(steps) + <span class="stringliteral">"_steps.txt"</span>);</div>
|
||||
<div class="line"><a id="l00119" name="l00119"></a><span class="lineno"> 119</span> <a class="code hl_class" href="classPenningTrap.html">PenningTrap</a> trap(std::vector<Particle>{<a class="code hl_variable" href="main_8cpp.html#a2efa69bb9d93049429ce4637075f1d30">p1</a>});</div>
|
||||
<div class="line"><a id="l00120" name="l00120"></a><span class="lineno"> 120</span> <a class="code hl_struct" href="structsimulation.html">simulation_t</a> res = trap.simulate(time, steps, <span class="stringliteral">"euler"</span>, <span class="keyword">false</span>);</div>
|
||||
<div class="line"><a id="l00121" name="l00121"></a><span class="lineno"> 121</span> <span class="keywordflow">for</span> (<span class="keywordtype">int</span> i = 0; i < steps; i++) {</div>
|
||||
<div class="line"><a id="l00122" name="l00122"></a><span class="lineno"> 122</span> ofile << arma::norm(res.r_vecs[0][i]</div>
|
||||
<div class="line"><a id="l00123" name="l00123"></a><span class="lineno"> 123</span> - <a class="code hl_function" href="main_8cpp.html#a8d92fb2ad085065fbd14718647551657">analytical_solution_particle_1</a>(dt * i))</div>
|
||||
<div class="line"><a id="l00124" name="l00124"></a><span class="lineno"> 124</span> << <span class="charliteral">'\n'</span>;</div>
|
||||
<div class="line"><a id="l00125" name="l00125"></a><span class="lineno"> 125</span> }</div>
|
||||
<div class="line"><a id="l00126" name="l00126"></a><span class="lineno"> 126</span> ofile.close();</div>
|
||||
<div class="line"><a id="l00127" name="l00127"></a><span class="lineno"> 127</span> }</div>
|
||||
<div class="line"><a id="l00128" name="l00128"></a><span class="lineno"> 128</span>}</div>
|
||||
<div class="line"><a id="l00129" name="l00129"></a><span class="lineno"> 129</span> </div>
|
||||
<div class="line"><a id="l00132" name="l00132"></a><span class="lineno"><a class="line" href="main_8cpp.html#a213713d6ecc02a32b588ffd179dc7513"> 132</a></span><span class="keywordtype">void</span> <a class="code hl_function" href="main_8cpp.html#a213713d6ecc02a32b588ffd179dc7513">simulate_100_particles</a>()</div>
|
||||
<div class="line"><a id="l00133" name="l00133"></a><span class="lineno"> 133</span>{</div>
|
||||
<div class="line"><a id="l00134" name="l00134"></a><span class="lineno"> 134</span> <a class="code hl_class" href="classPenningTrap.html">PenningTrap</a> trap((<span class="keywordtype">unsigned</span>)100);</div>
|
||||
<div class="line"><a id="l00135" name="l00135"></a><span class="lineno"> 135</span> </div>
|
||||
<div class="line"><a id="l00136" name="l00136"></a><span class="lineno"> 136</span> <span class="keywordtype">double</span> time = 50.; <span class="comment">// microseconds</span></div>
|
||||
<div class="line"><a id="l00137" name="l00137"></a><span class="lineno"> 137</span> </div>
|
||||
<div class="line"><a id="l00138" name="l00138"></a><span class="lineno"> 138</span> trap.<a class="code hl_function" href="classPenningTrap.html#ad8bc4df7ab3eed53b16cfdff38e7760b">write_simulation_to_dir</a>(<span class="stringliteral">"output/simulate_100_particles"</span>, time, N,</div>
|
||||
<div class="line"><a id="l00139" name="l00139"></a><span class="lineno"> 139</span> <span class="stringliteral">"rk4"</span>, <span class="keyword">false</span>);</div>
|
||||
<div class="line"><a id="l00140" name="l00140"></a><span class="lineno"> 140</span>}</div>
|
||||
<div class="line"><a id="l00141" name="l00141"></a><span class="lineno"> 141</span> </div>
|
||||
<div class="line"><a id="l00149" name="l00149"></a><span class="lineno"><a class="line" href="main_8cpp.html#a6b38b477c18e2f4268779751a88edab1"> 149</a></span><span class="keywordtype">void</span> <a class="code hl_function" href="main_8cpp.html#a6b38b477c18e2f4268779751a88edab1">potential_resonance_wide_sweep</a>()</div>
|
||||
<div class="line"><a id="l00150" name="l00150"></a><span class="lineno"> 150</span>{</div>
|
||||
<div class="line"><a id="l00151" name="l00151"></a><span class="lineno"> 151</span> <span class="keywordtype">double</span> time = 500.;</div>
|
||||
<div class="line"><a id="l00152" name="l00152"></a><span class="lineno"> 152</span> </div>
|
||||
<div class="line"><a id="l00153" name="l00153"></a><span class="lineno"> 153</span> <span class="keywordtype">double</span> amplitudes[]{.1, .4, .7};</div>
|
||||
<div class="line"><a id="l00154" name="l00154"></a><span class="lineno"> 154</span> </div>
|
||||
<div class="line"><a id="l00155" name="l00155"></a><span class="lineno"> 155</span> <span class="keywordtype">double</span> freq_start = .2;</div>
|
||||
<div class="line"><a id="l00156" name="l00156"></a><span class="lineno"> 156</span> <span class="keywordtype">double</span> freq_end = 2.5;</div>
|
||||
<div class="line"><a id="l00157" name="l00157"></a><span class="lineno"> 157</span> <span class="keywordtype">double</span> freq_increment = .02;</div>
|
||||
<div class="line"><a id="l00158" name="l00158"></a><span class="lineno"> 158</span> <span class="keywordtype">size_t</span> freq_iterations =</div>
|
||||
<div class="line"><a id="l00159" name="l00159"></a><span class="lineno"> 159</span> (size_t)((freq_end - freq_start) / freq_increment) + 1;</div>
|
||||
<div class="line"><a id="l00160" name="l00160"></a><span class="lineno"> 160</span> </div>
|
||||
<div class="line"><a id="l00161" name="l00161"></a><span class="lineno"> 161</span> <span class="keywordtype">double</span> res[4][freq_iterations];</div>
|
||||
<div class="line"><a id="l00162" name="l00162"></a><span class="lineno"> 162</span> </div>
|
||||
<div class="line"><a id="l00163" name="l00163"></a><span class="lineno"> 163</span> std::string path = <span class="stringliteral">"output/time_dependent_potential/"</span>;</div>
|
||||
<div class="line"><a id="l00164" name="l00164"></a><span class="lineno"> 164</span> <a class="code hl_function" href="utils_8hpp.html#a6fdd7217b750aff5b6295ece7cbdeffa">mkpath</a>(path);</div>
|
||||
<div class="line"><a id="l00165" name="l00165"></a><span class="lineno"> 165</span> </div>
|
||||
<div class="line"><a id="l00166" name="l00166"></a><span class="lineno"> 166</span> std::ofstream ofile;</div>
|
||||
<div class="line"><a id="l00167" name="l00167"></a><span class="lineno"> 167</span> </div>
|
||||
<div class="line"><a id="l00168" name="l00168"></a><span class="lineno"> 168</span><span class="preprocessor">#pragma omp parallel for</span></div>
|
||||
<div class="line"><a id="l00169" name="l00169"></a><span class="lineno"> 169</span> <span class="comment">// Insert frequencies</span></div>
|
||||
<div class="line"><a id="l00170" name="l00170"></a><span class="lineno"> 170</span> <span class="keywordflow">for</span> (<span class="keywordtype">size_t</span> i = 0; i < freq_iterations; i++) {</div>
|
||||
<div class="line"><a id="l00171" name="l00171"></a><span class="lineno"> 171</span> res[0][i] = freq_start + freq_increment * i;</div>
|
||||
<div class="line"><a id="l00172" name="l00172"></a><span class="lineno"> 172</span> }</div>
|
||||
<div class="line"><a id="l00173" name="l00173"></a><span class="lineno"> 173</span> </div>
|
||||
<div class="line"><a id="l00174" name="l00174"></a><span class="lineno"> 174</span><span class="preprocessor">#pragma omp parallel</span></div>
|
||||
<div class="line"><a id="l00175" name="l00175"></a><span class="lineno"> 175</span> {</div>
|
||||
<div class="line"><a id="l00176" name="l00176"></a><span class="lineno"> 176</span> <span class="comment">// Each thread creates a PenningTrap instance and reuses it throughout</span></div>
|
||||
<div class="line"><a id="l00177" name="l00177"></a><span class="lineno"> 177</span> <span class="comment">// the sweep.</span></div>
|
||||
<div class="line"><a id="l00178" name="l00178"></a><span class="lineno"> 178</span> <a class="code hl_class" href="classPenningTrap.html">PenningTrap</a> trap((uint)100);</div>
|
||||
<div class="line"><a id="l00179" name="l00179"></a><span class="lineno"> 179</span><span class="preprocessor">#pragma omp for collapse(2)</span></div>
|
||||
<div class="line"><a id="l00180" name="l00180"></a><span class="lineno"> 180</span> <span class="keywordflow">for</span> (<span class="keywordtype">size_t</span> i = 0; i < 3; i++) {</div>
|
||||
<div class="line"><a id="l00181" name="l00181"></a><span class="lineno"> 181</span> <span class="keywordflow">for</span> (<span class="keywordtype">size_t</span> j = 0; j < freq_iterations; j++) {</div>
|
||||
<div class="line"><a id="l00182" name="l00182"></a><span class="lineno"> 182</span> <span class="comment">// Reset particles and give new time dependent potential.</span></div>
|
||||
<div class="line"><a id="l00183" name="l00183"></a><span class="lineno"> 183</span> trap.<a class="code hl_function" href="classPenningTrap.html#aaee129f177657455348d0c8ae1441dea">reinitialize</a>(amplitudes[i], res[0][j]);</div>
|
||||
<div class="line"><a id="l00184" name="l00184"></a><span class="lineno"> 184</span> res[i + 1][j] =</div>
|
||||
<div class="line"><a id="l00185" name="l00185"></a><span class="lineno"> 185</span> trap.<a class="code hl_function" href="classPenningTrap.html#ac529aa26c288f34eae184a67e6bac41f">fraction_of_particles_left</a>(time, N, <span class="stringliteral">"rk4"</span>, <span class="keyword">false</span>);</div>
|
||||
<div class="line"><a id="l00186" name="l00186"></a><span class="lineno"> 186</span> }</div>
|
||||
<div class="line"><a id="l00187" name="l00187"></a><span class="lineno"> 187</span> }</div>
|
||||
<div class="line"><a id="l00188" name="l00188"></a><span class="lineno"> 188</span> }</div>
|
||||
<div class="line"><a id="l00189" name="l00189"></a><span class="lineno"> 189</span> </div>
|
||||
<div class="line"><a id="l00190" name="l00190"></a><span class="lineno"> 190</span> <span class="comment">// Write results to file</span></div>
|
||||
<div class="line"><a id="l00191" name="l00191"></a><span class="lineno"> 191</span> ofile.open(path + <span class="stringliteral">"wide_sweep.txt"</span>);</div>
|
||||
<div class="line"><a id="l00192" name="l00192"></a><span class="lineno"> 192</span> <span class="keywordflow">for</span> (<span class="keywordtype">size_t</span> i = 0; i < freq_iterations; i++) {</div>
|
||||
<div class="line"><a id="l00193" name="l00193"></a><span class="lineno"> 193</span> ofile << res[0][i] << <span class="charliteral">','</span> << res[1][i] << <span class="charliteral">','</span> << res[2][i] << <span class="charliteral">','</span></div>
|
||||
<div class="line"><a id="l00194" name="l00194"></a><span class="lineno"> 194</span> << res[3][i] << <span class="charliteral">'\n'</span>;</div>
|
||||
<div class="line"><a id="l00195" name="l00195"></a><span class="lineno"> 195</span> }</div>
|
||||
<div class="line"><a id="l00196" name="l00196"></a><span class="lineno"> 196</span> ofile.close();</div>
|
||||
<div class="line"><a id="l00197" name="l00197"></a><span class="lineno"> 197</span>}</div>
|
||||
<div class="line"><a id="l00198" name="l00198"></a><span class="lineno"> 198</span> </div>
|
||||
<div class="line"><a id="l00206" name="l00206"></a><span class="lineno"><a class="line" href="main_8cpp.html#a33d9b1c76c3c80902f89a58b1a6d96ea"> 206</a></span><span class="keywordtype">void</span> <a class="code hl_function" href="main_8cpp.html#a33d9b1c76c3c80902f89a58b1a6d96ea">potential_resonance_narrow_sweep</a>()</div>
|
||||
<div class="line"><a id="l00207" name="l00207"></a><span class="lineno"> 207</span>{</div>
|
||||
<div class="line"><a id="l00208" name="l00208"></a><span class="lineno"> 208</span> <span class="keywordtype">double</span> time = 500.;</div>
|
||||
<div class="line"><a id="l00209" name="l00209"></a><span class="lineno"> 209</span> </div>
|
||||
<div class="line"><a id="l00210" name="l00210"></a><span class="lineno"> 210</span> <span class="keywordtype">double</span> amplitudes[]{.1, .4, .7};</div>
|
||||
<div class="line"><a id="l00211" name="l00211"></a><span class="lineno"> 211</span> </div>
|
||||
<div class="line"><a id="l00212" name="l00212"></a><span class="lineno"> 212</span> <span class="keywordtype">double</span> freq_start = 1.;</div>
|
||||
<div class="line"><a id="l00213" name="l00213"></a><span class="lineno"> 213</span> <span class="keywordtype">double</span> freq_end = 1.7;</div>
|
||||
<div class="line"><a id="l00214" name="l00214"></a><span class="lineno"> 214</span> <span class="keywordtype">double</span> freq_increment = .002;</div>
|
||||
<div class="line"><a id="l00215" name="l00215"></a><span class="lineno"> 215</span> <span class="keywordtype">size_t</span> freq_iterations = (size_t)((freq_end - freq_start) / freq_increment);</div>
|
||||
<div class="line"><a id="l00216" name="l00216"></a><span class="lineno"> 216</span> </div>
|
||||
<div class="line"><a id="l00217" name="l00217"></a><span class="lineno"> 217</span> <span class="keywordtype">double</span> res[4][freq_iterations];</div>
|
||||
<div class="line"><a id="l00218" name="l00218"></a><span class="lineno"> 218</span> </div>
|
||||
<div class="line"><a id="l00219" name="l00219"></a><span class="lineno"> 219</span> std::string path = <span class="stringliteral">"output/time_dependent_potential/"</span>;</div>
|
||||
<div class="line"><a id="l00220" name="l00220"></a><span class="lineno"> 220</span> <a class="code hl_function" href="utils_8hpp.html#a6fdd7217b750aff5b6295ece7cbdeffa">mkpath</a>(path);</div>
|
||||
<div class="line"><a id="l00221" name="l00221"></a><span class="lineno"> 221</span> </div>
|
||||
<div class="line"><a id="l00222" name="l00222"></a><span class="lineno"> 222</span> std::ofstream ofile;</div>
|
||||
<div class="line"><a id="l00223" name="l00223"></a><span class="lineno"> 223</span> </div>
|
||||
<div class="line"><a id="l00224" name="l00224"></a><span class="lineno"> 224</span><span class="preprocessor">#pragma omp parallel for</span></div>
|
||||
<div class="line"><a id="l00225" name="l00225"></a><span class="lineno"> 225</span> <span class="comment">// Insert frequencies</span></div>
|
||||
<div class="line"><a id="l00226" name="l00226"></a><span class="lineno"> 226</span> <span class="keywordflow">for</span> (<span class="keywordtype">size_t</span> i = 0; i < freq_iterations; i++) {</div>
|
||||
<div class="line"><a id="l00227" name="l00227"></a><span class="lineno"> 227</span> res[0][i] = freq_start + freq_increment * i;</div>
|
||||
<div class="line"><a id="l00228" name="l00228"></a><span class="lineno"> 228</span> }</div>
|
||||
<div class="line"><a id="l00229" name="l00229"></a><span class="lineno"> 229</span> </div>
|
||||
<div class="line"><a id="l00230" name="l00230"></a><span class="lineno"> 230</span><span class="preprocessor">#pragma omp parallel</span></div>
|
||||
<div class="line"><a id="l00231" name="l00231"></a><span class="lineno"> 231</span> {</div>
|
||||
<div class="line"><a id="l00232" name="l00232"></a><span class="lineno"> 232</span> <span class="comment">// Each thread creates a PenningTrap instance and reuses it throughout</span></div>
|
||||
<div class="line"><a id="l00233" name="l00233"></a><span class="lineno"> 233</span> <span class="comment">// the sweep.</span></div>
|
||||
<div class="line"><a id="l00234" name="l00234"></a><span class="lineno"> 234</span> <a class="code hl_class" href="classPenningTrap.html">PenningTrap</a> trap((uint)100);</div>
|
||||
<div class="line"><a id="l00235" name="l00235"></a><span class="lineno"> 235</span><span class="preprocessor">#pragma omp for collapse(2)</span></div>
|
||||
<div class="line"><a id="l00236" name="l00236"></a><span class="lineno"> 236</span> <span class="keywordflow">for</span> (<span class="keywordtype">size_t</span> i = 0; i < 3; i++) {</div>
|
||||
<div class="line"><a id="l00237" name="l00237"></a><span class="lineno"> 237</span> <span class="keywordflow">for</span> (<span class="keywordtype">size_t</span> j = 0; j < freq_iterations; j++) {</div>
|
||||
<div class="line"><a id="l00238" name="l00238"></a><span class="lineno"> 238</span> <span class="comment">// Reset particles and give new time dependent potential.</span></div>
|
||||
<div class="line"><a id="l00239" name="l00239"></a><span class="lineno"> 239</span> trap.<a class="code hl_function" href="classPenningTrap.html#aaee129f177657455348d0c8ae1441dea">reinitialize</a>(amplitudes[i], res[0][j]);</div>
|
||||
<div class="line"><a id="l00240" name="l00240"></a><span class="lineno"> 240</span> res[i + 1][j] =</div>
|
||||
<div class="line"><a id="l00241" name="l00241"></a><span class="lineno"> 241</span> trap.<a class="code hl_function" href="classPenningTrap.html#ac529aa26c288f34eae184a67e6bac41f">fraction_of_particles_left</a>(time, N, <span class="stringliteral">"rk4"</span>, <span class="keyword">false</span>);</div>
|
||||
<div class="line"><a id="l00242" name="l00242"></a><span class="lineno"> 242</span> }</div>
|
||||
<div class="line"><a id="l00243" name="l00243"></a><span class="lineno"> 243</span> }</div>
|
||||
<div class="line"><a id="l00244" name="l00244"></a><span class="lineno"> 244</span> }</div>
|
||||
<div class="line"><a id="l00245" name="l00245"></a><span class="lineno"> 245</span> </div>
|
||||
<div class="line"><a id="l00246" name="l00246"></a><span class="lineno"> 246</span> <span class="comment">// Write results to file</span></div>
|
||||
<div class="line"><a id="l00247" name="l00247"></a><span class="lineno"> 247</span> ofile.open(path + <span class="stringliteral">"narrow_sweep.txt"</span>);</div>
|
||||
<div class="line"><a id="l00248" name="l00248"></a><span class="lineno"> 248</span> <span class="keywordflow">for</span> (<span class="keywordtype">size_t</span> i = 0; i < freq_iterations; i++) {</div>
|
||||
<div class="line"><a id="l00249" name="l00249"></a><span class="lineno"> 249</span> ofile << res[0][i] << <span class="charliteral">','</span> << res[1][i] << <span class="charliteral">','</span> << res[2][i] << <span class="charliteral">','</span></div>
|
||||
<div class="line"><a id="l00250" name="l00250"></a><span class="lineno"> 250</span> << res[3][i] << <span class="charliteral">'\n'</span>;</div>
|
||||
<div class="line"><a id="l00251" name="l00251"></a><span class="lineno"> 251</span> }</div>
|
||||
<div class="line"><a id="l00252" name="l00252"></a><span class="lineno"> 252</span> ofile.close();</div>
|
||||
<div class="line"><a id="l00253" name="l00253"></a><span class="lineno"> 253</span>}</div>
|
||||
<div class="line"><a id="l00254" name="l00254"></a><span class="lineno"> 254</span> </div>
|
||||
<div class="line"><a id="l00262" name="l00262"></a><span class="lineno"><a class="line" href="main_8cpp.html#ac1816f70ec612edc27848ef7f0875fdb"> 262</a></span><span class="keywordtype">void</span> <a class="code hl_function" href="main_8cpp.html#ac1816f70ec612edc27848ef7f0875fdb">potential_resonance_narrow_sweep_interaction</a>()</div>
|
||||
<div class="line"><a id="l00263" name="l00263"></a><span class="lineno"> 263</span>{</div>
|
||||
<div class="line"><a id="l00264" name="l00264"></a><span class="lineno"> 264</span> <span class="keywordtype">double</span> time = 500.;</div>
|
||||
<div class="line"><a id="l00265" name="l00265"></a><span class="lineno"> 265</span> </div>
|
||||
<div class="line"><a id="l00266" name="l00266"></a><span class="lineno"> 266</span> <span class="keywordtype">double</span> amplitudes[]{.1, .4, .7};</div>
|
||||
<div class="line"><a id="l00267" name="l00267"></a><span class="lineno"> 267</span> </div>
|
||||
<div class="line"><a id="l00268" name="l00268"></a><span class="lineno"> 268</span> <span class="keywordtype">double</span> freq_start = 1.;</div>
|
||||
<div class="line"><a id="l00269" name="l00269"></a><span class="lineno"> 269</span> <span class="keywordtype">double</span> freq_end = 1.7;</div>
|
||||
<div class="line"><a id="l00270" name="l00270"></a><span class="lineno"> 270</span> <span class="keywordtype">double</span> freq_increment = .002;</div>
|
||||
<div class="line"><a id="l00271" name="l00271"></a><span class="lineno"> 271</span> <span class="keywordtype">size_t</span> freq_iterations = (size_t)((freq_end - freq_start) / freq_increment);</div>
|
||||
<div class="line"><a id="l00272" name="l00272"></a><span class="lineno"> 272</span> </div>
|
||||
<div class="line"><a id="l00273" name="l00273"></a><span class="lineno"> 273</span> <span class="keywordtype">double</span> res[4][freq_iterations];</div>
|
||||
<div class="line"><a id="l00274" name="l00274"></a><span class="lineno"> 274</span> </div>
|
||||
<div class="line"><a id="l00275" name="l00275"></a><span class="lineno"> 275</span> std::string path = <span class="stringliteral">"output/time_dependent_potential/"</span>;</div>
|
||||
<div class="line"><a id="l00276" name="l00276"></a><span class="lineno"> 276</span> <a class="code hl_function" href="utils_8hpp.html#a6fdd7217b750aff5b6295ece7cbdeffa">mkpath</a>(path);</div>
|
||||
<div class="line"><a id="l00277" name="l00277"></a><span class="lineno"> 277</span> </div>
|
||||
<div class="line"><a id="l00278" name="l00278"></a><span class="lineno"> 278</span> std::ofstream ofile;</div>
|
||||
<div class="line"><a id="l00279" name="l00279"></a><span class="lineno"> 279</span> </div>
|
||||
<div class="line"><a id="l00280" name="l00280"></a><span class="lineno"> 280</span><span class="preprocessor">#pragma omp parallel for</span></div>
|
||||
<div class="line"><a id="l00281" name="l00281"></a><span class="lineno"> 281</span> <span class="keywordflow">for</span> (<span class="keywordtype">size_t</span> i = 0; i < freq_iterations; i++) {</div>
|
||||
<div class="line"><a id="l00282" name="l00282"></a><span class="lineno"> 282</span> res[0][i] = freq_start + freq_increment * i;</div>
|
||||
<div class="line"><a id="l00283" name="l00283"></a><span class="lineno"> 283</span> }</div>
|
||||
<div class="line"><a id="l00284" name="l00284"></a><span class="lineno"> 284</span> </div>
|
||||
<div class="line"><a id="l00285" name="l00285"></a><span class="lineno"> 285</span><span class="preprocessor">#pragma omp parallel</span></div>
|
||||
<div class="line"><a id="l00286" name="l00286"></a><span class="lineno"> 286</span> {</div>
|
||||
<div class="line"><a id="l00287" name="l00287"></a><span class="lineno"> 287</span> <span class="comment">// Each thread creates a PenningTrap instance and reuses it throughout</span></div>
|
||||
<div class="line"><a id="l00288" name="l00288"></a><span class="lineno"> 288</span> <span class="comment">// the sweep.</span></div>
|
||||
<div class="line"><a id="l00289" name="l00289"></a><span class="lineno"> 289</span> <a class="code hl_class" href="classPenningTrap.html">PenningTrap</a> trap((uint)100);</div>
|
||||
<div class="line"><a id="l00290" name="l00290"></a><span class="lineno"> 290</span><span class="preprocessor">#pragma omp for collapse(2)</span></div>
|
||||
<div class="line"><a id="l00291" name="l00291"></a><span class="lineno"> 291</span> <span class="keywordflow">for</span> (<span class="keywordtype">size_t</span> i = 0; i < 3; i++) {</div>
|
||||
<div class="line"><a id="l00292" name="l00292"></a><span class="lineno"> 292</span> <span class="keywordflow">for</span> (<span class="keywordtype">size_t</span> j = 0; j < freq_iterations; j++) {</div>
|
||||
<div class="line"><a id="l00293" name="l00293"></a><span class="lineno"> 293</span> <span class="comment">// Reset particles and give new time dependent potential.</span></div>
|
||||
<div class="line"><a id="l00294" name="l00294"></a><span class="lineno"> 294</span> trap.<a class="code hl_function" href="classPenningTrap.html#aaee129f177657455348d0c8ae1441dea">reinitialize</a>(amplitudes[i], res[0][j]);</div>
|
||||
<div class="line"><a id="l00295" name="l00295"></a><span class="lineno"> 295</span> res[i + 1][j] = trap.<a class="code hl_function" href="classPenningTrap.html#ac529aa26c288f34eae184a67e6bac41f">fraction_of_particles_left</a>(time, N);</div>
|
||||
<div class="line"><a id="l00296" name="l00296"></a><span class="lineno"> 296</span> }</div>
|
||||
<div class="line"><a id="l00297" name="l00297"></a><span class="lineno"> 297</span> }</div>
|
||||
<div class="line"><a id="l00298" name="l00298"></a><span class="lineno"> 298</span> }</div>
|
||||
<div class="line"><a id="l00299" name="l00299"></a><span class="lineno"> 299</span> </div>
|
||||
<div class="line"><a id="l00300" name="l00300"></a><span class="lineno"> 300</span> <span class="comment">// Write results to file</span></div>
|
||||
<div class="line"><a id="l00301" name="l00301"></a><span class="lineno"> 301</span> ofile.open(path + <span class="stringliteral">"narrow_sweep_interactions.txt"</span>);</div>
|
||||
<div class="line"><a id="l00302" name="l00302"></a><span class="lineno"> 302</span> <span class="keywordflow">for</span> (<span class="keywordtype">size_t</span> i = 0; i < freq_iterations; i++) {</div>
|
||||
<div class="line"><a id="l00303" name="l00303"></a><span class="lineno"> 303</span> ofile << res[0][i] << <span class="charliteral">','</span> << res[1][i] << <span class="charliteral">','</span> << res[2][i] << <span class="charliteral">','</span></div>
|
||||
<div class="line"><a id="l00304" name="l00304"></a><span class="lineno"> 304</span> << res[3][i] << <span class="charliteral">'\n'</span>;</div>
|
||||
<div class="line"><a id="l00305" name="l00305"></a><span class="lineno"> 305</span> }</div>
|
||||
<div class="line"><a id="l00306" name="l00306"></a><span class="lineno"> 306</span> ofile.close();</div>
|
||||
<div class="line"><a id="l00307" name="l00307"></a><span class="lineno"> 307</span>}</div>
|
||||
<div class="line"><a id="l00308" name="l00308"></a><span class="lineno"> 308</span> </div>
|
||||
<div class="line"><a id="l00309" name="l00309"></a><span class="lineno"> 309</span><span class="keywordtype">int</span> main()</div>
|
||||
<div class="line"><a id="l00310" name="l00310"></a><span class="lineno"> 310</span>{</div>
|
||||
<div class="line"><a id="l00311" name="l00311"></a><span class="lineno"> 311</span> <span class="keywordtype">double</span> start, end, t1, t2;</div>
|
||||
<div class="line"><a id="l00312" name="l00312"></a><span class="lineno"> 312</span> start = omp_get_wtime();</div>
|
||||
<div class="line"><a id="l00313" name="l00313"></a><span class="lineno"> 313</span> </div>
|
||||
<div class="line"><a id="l00314" name="l00314"></a><span class="lineno"> 314</span> <a class="code hl_function" href="main_8cpp.html#a8fdbe2d5a872e50ef5ec1263243589d6">simulate_single_particle</a>();</div>
|
||||
<div class="line"><a id="l00315" name="l00315"></a><span class="lineno"> 315</span> </div>
|
||||
<div class="line"><a id="l00316" name="l00316"></a><span class="lineno"> 316</span> <a class="code hl_function" href="main_8cpp.html#a783789519f97c6430081171cacb0ffb1">simulate_two_particles</a>();</div>
|
||||
<div class="line"><a id="l00317" name="l00317"></a><span class="lineno"> 317</span> </div>
|
||||
<div class="line"><a id="l00318" name="l00318"></a><span class="lineno"> 318</span> <a class="code hl_function" href="main_8cpp.html#ac67e0d59227856c4d42e7d01c75e0ad2">simulate_single_particle_with_different_steps</a>();</div>
|
||||
<div class="line"><a id="l00319" name="l00319"></a><span class="lineno"> 319</span> </div>
|
||||
<div class="line"><a id="l00320" name="l00320"></a><span class="lineno"> 320</span> t2 = omp_get_wtime();</div>
|
||||
<div class="line"><a id="l00321" name="l00321"></a><span class="lineno"> 321</span> </div>
|
||||
<div class="line"><a id="l00322" name="l00322"></a><span class="lineno"> 322</span> std::cout << <span class="stringliteral">"Time single and double : "</span> << (t2 - start)</div>
|
||||
<div class="line"><a id="l00323" name="l00323"></a><span class="lineno"> 323</span> << <span class="stringliteral">" seconds"</span> << std::endl;</div>
|
||||
<div class="line"><a id="l00324" name="l00324"></a><span class="lineno"> 324</span> </div>
|
||||
<div class="line"><a id="l00325" name="l00325"></a><span class="lineno"> 325</span> t1 = omp_get_wtime();</div>
|
||||
<div class="line"><a id="l00326" name="l00326"></a><span class="lineno"> 326</span> </div>
|
||||
<div class="line"><a id="l00327" name="l00327"></a><span class="lineno"> 327</span> <a class="code hl_function" href="main_8cpp.html#a213713d6ecc02a32b588ffd179dc7513">simulate_100_particles</a>();</div>
|
||||
<div class="line"><a id="l00328" name="l00328"></a><span class="lineno"> 328</span> </div>
|
||||
<div class="line"><a id="l00329" name="l00329"></a><span class="lineno"> 329</span> t2 = omp_get_wtime();</div>
|
||||
<div class="line"><a id="l00330" name="l00330"></a><span class="lineno"> 330</span> </div>
|
||||
<div class="line"><a id="l00331" name="l00331"></a><span class="lineno"> 331</span> std::cout << <span class="stringliteral">"Time 100 particles : "</span> << (t2 - t1)</div>
|
||||
<div class="line"><a id="l00332" name="l00332"></a><span class="lineno"> 332</span> << <span class="stringliteral">" seconds"</span> << std::endl;</div>
|
||||
<div class="line"><a id="l00333" name="l00333"></a><span class="lineno"> 333</span> </div>
|
||||
<div class="line"><a id="l00334" name="l00334"></a><span class="lineno"> 334</span> t1 = omp_get_wtime();</div>
|
||||
<div class="line"><a id="l00335" name="l00335"></a><span class="lineno"> 335</span> </div>
|
||||
<div class="line"><a id="l00336" name="l00336"></a><span class="lineno"> 336</span> <a class="code hl_function" href="main_8cpp.html#a6b38b477c18e2f4268779751a88edab1">potential_resonance_wide_sweep</a>();</div>
|
||||
<div class="line"><a id="l00337" name="l00337"></a><span class="lineno"> 337</span> </div>
|
||||
<div class="line"><a id="l00338" name="l00338"></a><span class="lineno"> 338</span> t2 = omp_get_wtime();</div>
|
||||
<div class="line"><a id="l00339" name="l00339"></a><span class="lineno"> 339</span> </div>
|
||||
<div class="line"><a id="l00340" name="l00340"></a><span class="lineno"> 340</span> std::cout << <span class="stringliteral">"Time wide sweep : "</span> << (t2 - t1)</div>
|
||||
<div class="line"><a id="l00341" name="l00341"></a><span class="lineno"> 341</span> << <span class="stringliteral">" seconds"</span> << std::endl;</div>
|
||||
<div class="line"><a id="l00342" name="l00342"></a><span class="lineno"> 342</span> </div>
|
||||
<div class="line"><a id="l00343" name="l00343"></a><span class="lineno"> 343</span> t1 = omp_get_wtime();</div>
|
||||
<div class="line"><a id="l00344" name="l00344"></a><span class="lineno"> 344</span> </div>
|
||||
<div class="line"><a id="l00345" name="l00345"></a><span class="lineno"> 345</span> <a class="code hl_function" href="main_8cpp.html#a33d9b1c76c3c80902f89a58b1a6d96ea">potential_resonance_narrow_sweep</a>();</div>
|
||||
<div class="line"><a id="l00346" name="l00346"></a><span class="lineno"> 346</span> </div>
|
||||
<div class="line"><a id="l00347" name="l00347"></a><span class="lineno"> 347</span> t2 = omp_get_wtime();</div>
|
||||
<div class="line"><a id="l00348" name="l00348"></a><span class="lineno"> 348</span> </div>
|
||||
<div class="line"><a id="l00349" name="l00349"></a><span class="lineno"> 349</span> std::cout << <span class="stringliteral">"Time narrow sweep no interaction : "</span> << (t2 - t1)</div>
|
||||
<div class="line"><a id="l00350" name="l00350"></a><span class="lineno"> 350</span> << <span class="stringliteral">" seconds"</span> << std::endl;</div>
|
||||
<div class="line"><a id="l00351" name="l00351"></a><span class="lineno"> 351</span> </div>
|
||||
<div class="line"><a id="l00352" name="l00352"></a><span class="lineno"> 352</span> t1 = omp_get_wtime();</div>
|
||||
<div class="line"><a id="l00353" name="l00353"></a><span class="lineno"> 353</span> </div>
|
||||
<div class="line"><a id="l00354" name="l00354"></a><span class="lineno"> 354</span> <a class="code hl_function" href="main_8cpp.html#ac1816f70ec612edc27848ef7f0875fdb">potential_resonance_narrow_sweep_interaction</a>();</div>
|
||||
<div class="line"><a id="l00355" name="l00355"></a><span class="lineno"> 355</span> </div>
|
||||
<div class="line"><a id="l00356" name="l00356"></a><span class="lineno"> 356</span> t2 = omp_get_wtime();</div>
|
||||
<div class="line"><a id="l00357" name="l00357"></a><span class="lineno"> 357</span> </div>
|
||||
<div class="line"><a id="l00358" name="l00358"></a><span class="lineno"> 358</span> std::cout << <span class="stringliteral">"Time narrow sweep with interaction: "</span> << (t2 - t1)</div>
|
||||
<div class="line"><a id="l00359" name="l00359"></a><span class="lineno"> 359</span> << <span class="stringliteral">" seconds"</span> << std::endl;</div>
|
||||
<div class="line"><a id="l00360" name="l00360"></a><span class="lineno"> 360</span> </div>
|
||||
<div class="line"><a id="l00361" name="l00361"></a><span class="lineno"> 361</span> end = omp_get_wtime();</div>
|
||||
<div class="line"><a id="l00362" name="l00362"></a><span class="lineno"> 362</span> </div>
|
||||
<div class="line"><a id="l00363" name="l00363"></a><span class="lineno"> 363</span> std::cout << <span class="stringliteral">"Time : "</span> << (end - start)</div>
|
||||
<div class="line"><a id="l00364" name="l00364"></a><span class="lineno"> 364</span> << <span class="stringliteral">" seconds"</span> << std::endl;</div>
|
||||
<div class="line"><a id="l00365" name="l00365"></a><span class="lineno"> 365</span> </div>
|
||||
<div class="line"><a id="l00366" name="l00366"></a><span class="lineno"> 366</span> <span class="keywordflow">return</span> 0;</div>
|
||||
<div class="line"><a id="l00367" name="l00367"></a><span class="lineno"> 367</span>}</div>
|
||||
<div class="ttc" id="aPenningTrap_8hpp_html"><div class="ttname"><a href="PenningTrap_8hpp.html">PenningTrap.hpp</a></div><div class="ttdoc">A class for simulating a Penning trap.</div></div>
|
||||
<div class="ttc" id="aclassParticle_html"><div class="ttname"><a href="classParticle.html">Particle</a></div><div class="ttdoc">A class that holds attributes of a particle.</div><div class="ttdef"><b>Definition:</b> <a href="Particle_8hpp_source.html#l00022">Particle.hpp:23</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html"><div class="ttname"><a href="classPenningTrap.html">PenningTrap</a></div><div class="ttdoc">A class that simulates a Penning trap.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8hpp_source.html#l00031">PenningTrap.hpp:32</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_aaee129f177657455348d0c8ae1441dea"><div class="ttname"><a href="classPenningTrap.html#aaee129f177657455348d0c8ae1441dea">PenningTrap::reinitialize</a></div><div class="ttdeci">void reinitialize(double f, double omega_V, double t=0.)</div><div class="ttdoc">Give all particles new positions and velocities, and change t and V_0.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00148">PenningTrap.cpp:148</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_ac529aa26c288f34eae184a67e6bac41f"><div class="ttname"><a href="classPenningTrap.html#ac529aa26c288f34eae184a67e6bac41f">PenningTrap::fraction_of_particles_left</a></div><div class="ttdeci">double fraction_of_particles_left(double time, uint steps, std::string method="rk4", bool particle_interaction=true)</div><div class="ttdoc">Simulate and calculate what fraction of particles are still left inside the Penning trap after the si...</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00297">PenningTrap.cpp:297</a></div></div>
|
||||
<div class="ttc" id="aclassPenningTrap_html_ad8bc4df7ab3eed53b16cfdff38e7760b"><div class="ttname"><a href="classPenningTrap.html#ad8bc4df7ab3eed53b16cfdff38e7760b">PenningTrap::write_simulation_to_dir</a></div><div class="ttdeci">void write_simulation_to_dir(std::string path, double time, uint steps, std::string method="rk4", bool particle_interaction=true)</div><div class="ttdoc">Simulate and write the displacement of all particles to files.</div><div class="ttdef"><b>Definition:</b> <a href="PenningTrap_8cpp_source.html#l00259">PenningTrap.cpp:259</a></div></div>
|
||||
<div class="ttc" id="aconstants_8hpp_html"><div class="ttname"><a href="constants_8hpp.html">constants.hpp</a></div><div class="ttdoc">Library of constants.</div></div>
|
||||
<div class="ttc" id="aconstants_8hpp_html_a0acb682b8260ab1c60b918599864e2e5"><div class="ttname"><a href="constants_8hpp.html#a0acb682b8260ab1c60b918599864e2e5">T</a></div><div class="ttdeci">#define T</div><div class="ttdoc">1 Tesla. unit:</div><div class="ttdef"><b>Definition:</b> <a href="constants_8hpp_source.html#l00021">constants.hpp:21</a></div></div>
|
||||
<div class="ttc" id="aconstants_8hpp_html_a2ff491cc7958ffd5e749c518a4a60ec8"><div class="ttname"><a href="constants_8hpp.html#a2ff491cc7958ffd5e749c518a4a60ec8">CA_MASS</a></div><div class="ttdeci">#define CA_MASS</div><div class="ttdoc">Mass of a single calcium ion. unit: amu.</div><div class="ttdef"><b>Definition:</b> <a href="constants_8hpp_source.html#l00029">constants.hpp:29</a></div></div>
|
||||
<div class="ttc" id="aconstants_8hpp_html_af40a326b23c68a27cebe60f16634a2cb"><div class="ttname"><a href="constants_8hpp.html#af40a326b23c68a27cebe60f16634a2cb">V</a></div><div class="ttdeci">#define V</div><div class="ttdoc">1 Volt. unit:</div><div class="ttdef"><b>Definition:</b> <a href="constants_8hpp_source.html#l00025">constants.hpp:25</a></div></div>
|
||||
<div class="ttc" id="amain_8cpp_html_a213713d6ecc02a32b588ffd179dc7513"><div class="ttname"><a href="main_8cpp.html#a213713d6ecc02a32b588ffd179dc7513">simulate_100_particles</a></div><div class="ttdeci">void simulate_100_particles()</div><div class="ttdoc">Simulate 100 particles over 50 .</div><div class="ttdef"><b>Definition:</b> <a href="main_8cpp_source.html#l00132">main.cpp:132</a></div></div>
|
||||
<div class="ttc" id="amain_8cpp_html_a2efa69bb9d93049429ce4637075f1d30"><div class="ttname"><a href="main_8cpp.html#a2efa69bb9d93049429ce4637075f1d30">p1</a></div><div class="ttdeci">Particle p1(vec3{20., 0., 20.}, vec3{0., 25., 0.})</div><div class="ttdoc">Particle 1.</div></div>
|
||||
<div class="ttc" id="amain_8cpp_html_a33d9b1c76c3c80902f89a58b1a6d96ea"><div class="ttname"><a href="main_8cpp.html#a33d9b1c76c3c80902f89a58b1a6d96ea">potential_resonance_narrow_sweep</a></div><div class="ttdeci">void potential_resonance_narrow_sweep()</div><div class="ttdoc">Simulate 100 particles over 500 using a time dependent potential.</div><div class="ttdef"><b>Definition:</b> <a href="main_8cpp_source.html#l00206">main.cpp:206</a></div></div>
|
||||
<div class="ttc" id="amain_8cpp_html_a6b38b477c18e2f4268779751a88edab1"><div class="ttname"><a href="main_8cpp.html#a6b38b477c18e2f4268779751a88edab1">potential_resonance_wide_sweep</a></div><div class="ttdeci">void potential_resonance_wide_sweep()</div><div class="ttdoc">Simulate 100 particles over 500 using a time dependent potential.</div><div class="ttdef"><b>Definition:</b> <a href="main_8cpp_source.html#l00149">main.cpp:149</a></div></div>
|
||||
<div class="ttc" id="amain_8cpp_html_a783789519f97c6430081171cacb0ffb1"><div class="ttname"><a href="main_8cpp.html#a783789519f97c6430081171cacb0ffb1">simulate_two_particles</a></div><div class="ttdeci">void simulate_two_particles()</div><div class="ttdoc">Simulate 2 particles over the period of 50 with and without particle interactions.</div><div class="ttdef"><b>Definition:</b> <a href="main_8cpp_source.html#l00069">main.cpp:69</a></div></div>
|
||||
<div class="ttc" id="amain_8cpp_html_a8d92fb2ad085065fbd14718647551657"><div class="ttname"><a href="main_8cpp.html#a8d92fb2ad085065fbd14718647551657">analytical_solution_particle_1</a></div><div class="ttdeci">vec3 analytical_solution_particle_1(double t)</div><div class="ttdoc">The analytical solution for particle p1.</div><div class="ttdef"><b>Definition:</b> <a href="main_8cpp_source.html#l00037">main.cpp:37</a></div></div>
|
||||
<div class="ttc" id="amain_8cpp_html_a8fdbe2d5a872e50ef5ec1263243589d6"><div class="ttname"><a href="main_8cpp.html#a8fdbe2d5a872e50ef5ec1263243589d6">simulate_single_particle</a></div><div class="ttdeci">void simulate_single_particle()</div><div class="ttdoc">Simulate a single particle over the period of 50 .</div><div class="ttdef"><b>Definition:</b> <a href="main_8cpp_source.html#l00054">main.cpp:54</a></div></div>
|
||||
<div class="ttc" id="amain_8cpp_html_ac1816f70ec612edc27848ef7f0875fdb"><div class="ttname"><a href="main_8cpp.html#ac1816f70ec612edc27848ef7f0875fdb">potential_resonance_narrow_sweep_interaction</a></div><div class="ttdeci">void potential_resonance_narrow_sweep_interaction()</div><div class="ttdoc">Simulate 100 particles over 500 using a time dependent potential.</div><div class="ttdef"><b>Definition:</b> <a href="main_8cpp_source.html#l00262">main.cpp:262</a></div></div>
|
||||
<div class="ttc" id="amain_8cpp_html_ac67e0d59227856c4d42e7d01c75e0ad2"><div class="ttname"><a href="main_8cpp.html#ac67e0d59227856c4d42e7d01c75e0ad2">simulate_single_particle_with_different_steps</a></div><div class="ttdeci">void simulate_single_particle_with_different_steps()</div><div class="ttdoc">Simulate a single particle over 50 using different amount of steps and different methods.</div><div class="ttdef"><b>Definition:</b> <a href="main_8cpp_source.html#l00087">main.cpp:87</a></div></div>
|
||||
<div class="ttc" id="amain_8cpp_html_ac70b61df65f4336f57ea9b4c35250df7"><div class="ttname"><a href="main_8cpp.html#ac70b61df65f4336f57ea9b4c35250df7">p2</a></div><div class="ttdeci">Particle p2(vec3{25., 25., 0.}, vec3{0., 40., 5.})</div><div class="ttdoc">Particle 2.</div></div>
|
||||
<div class="ttc" id="astructsimulation_html"><div class="ttname"><a href="structsimulation.html">simulation</a></div><div class="ttdoc">Typedef for PenningTrap::simulation return value.</div><div class="ttdef"><b>Definition:</b> <a href="typedefs_8hpp_source.html#l00040">typedefs.hpp:40</a></div></div>
|
||||
<div class="ttc" id="atypedefs_8hpp_html_a3bdfb73a02f88ae32b6128ef747c4aea"><div class="ttname"><a href="typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea">vec3</a></div><div class="ttdeci">arma::vec::fixed< 3 > vec3</div><div class="ttdoc">Typedef for a fixed 3d arma vector.</div><div class="ttdef"><b>Definition:</b> <a href="typedefs_8hpp_source.html#l00023">typedefs.hpp:23</a></div></div>
|
||||
<div class="ttc" id="autils_8hpp_html"><div class="ttname"><a href="utils_8hpp.html">utils.hpp</a></div><div class="ttdoc">Function prototypes and macros that are useful.</div></div>
|
||||
<div class="ttc" id="autils_8hpp_html_a6fdd7217b750aff5b6295ece7cbdeffa"><div class="ttname"><a href="utils_8hpp.html#a6fdd7217b750aff5b6295ece7cbdeffa">mkpath</a></div><div class="ttdeci">bool mkpath(std::string path, int mode=0777)</div><div class="ttdoc">Make path given.</div><div class="ttdef"><b>Definition:</b> <a href="utils_8cpp_source.html#l00072">utils.cpp:72</a></div></div>
|
||||
</div><!-- fragment --></div><!-- contents -->
|
||||
</div><!-- doc-content -->
|
||||
<!-- start footer part -->
|
||||
|
||||
@@ -29,13 +29,39 @@ var menudata={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:"All",url:"functions.html",children:[
|
||||
{text:"a",url:"functions.html#index_a"},
|
||||
{text:"b",url:"functions.html#index_b"},
|
||||
{text:"d",url:"functions.html#index_d"},
|
||||
{text:"e",url:"functions.html#index_e"},
|
||||
{text:"f",url:"functions.html#index_f"},
|
||||
{text:"k",url:"functions.html#index_k"},
|
||||
{text:"m",url:"functions.html#index_m"},
|
||||
{text:"p",url:"functions.html#index_p"},
|
||||
{text:"q",url:"functions.html#index_q"},
|
||||
{text:"r",url:"functions.html#index_r"},
|
||||
{text:"s",url:"functions.html#index_s"},
|
||||
{text:"t",url:"functions.html#index_t"},
|
||||
{text:"v",url:"functions.html#index_v"},
|
||||
{text:"w",url:"functions.html#index_w"}]},
|
||||
{text:"Functions",url:"functions_func.html"},
|
||||
{text:"Variables",url:"functions_vars.html"},
|
||||
{text:"Related Functions",url:"functions_rela.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:"All",url:"globals.html",children:[
|
||||
{text:"_",url:"globals.html#index__5F"},
|
||||
{text:"a",url:"globals.html#index_a"},
|
||||
{text:"c",url:"globals.html#index_c"},
|
||||
{text:"d",url:"globals.html#index_d"},
|
||||
{text:"k",url:"globals.html#index_k"},
|
||||
{text:"m",url:"globals.html#index_m"},
|
||||
{text:"p",url:"globals.html#index_p"},
|
||||
{text:"s",url:"globals.html#index_s"},
|
||||
{text:"t",url:"globals.html#index_t"},
|
||||
{text:"v",url:"globals.html#index_v"}]},
|
||||
{text:"Functions",url:"globals_func.html"},
|
||||
{text:"Variables",url:"globals_vars.html"},
|
||||
{text:"Typedefs",url:"globals_type.html"},
|
||||
{text:"Macros",url:"globals_defs.html"}]}]}]}
|
||||
|
||||
@@ -25,9 +25,20 @@
|
||||
var NAVTREE =
|
||||
[
|
||||
[ "Penning Trap Simulation", "index.html", [
|
||||
[ "Credits", "index.html#autotoc_md1", null ],
|
||||
[ "Requirements", "index.html#autotoc_md1", [
|
||||
[ "Operating systems", "index.html#autotoc_md2", null ],
|
||||
[ "Libraries", "index.html#autotoc_md3", null ]
|
||||
] ],
|
||||
[ "Compiling", "index.html#autotoc_md4", null ],
|
||||
[ "Running programs", "index.html#autotoc_md5", [
|
||||
[ "C++ binaries", "index.html#autotoc_md6", null ],
|
||||
[ "Python scripts", "index.html#autotoc_md7", [
|
||||
[ "Install libraries", "index.html#autotoc_md8", null ],
|
||||
[ "Running scripts", "index.html#autotoc_md9", null ]
|
||||
] ]
|
||||
] ],
|
||||
[ "Credits", "index.html#autotoc_md10", null ],
|
||||
[ "Bug List", "bug.html", null ],
|
||||
[ "Todo List", "todo.html", null ],
|
||||
[ "Classes", "annotated.html", [
|
||||
[ "Class List", "annotated.html", "annotated_dup" ],
|
||||
[ "Class Index", "classes.html", null ],
|
||||
@@ -43,6 +54,8 @@ var NAVTREE =
|
||||
[ "File Members", "globals.html", [
|
||||
[ "All", "globals.html", null ],
|
||||
[ "Functions", "globals_func.html", null ],
|
||||
[ "Variables", "globals_vars.html", null ],
|
||||
[ "Typedefs", "globals_type.html", null ],
|
||||
[ "Macros", "globals_defs.html", null ]
|
||||
] ]
|
||||
] ]
|
||||
|
||||
@@ -1,68 +1,134 @@
|
||||
var NAVTREEINDEX0 =
|
||||
{
|
||||
"Particle_8cpp.html":[4,0,1,1],
|
||||
"Particle_8cpp_source.html":[4,0,1,1],
|
||||
"Particle_8hpp.html":[4,0,0,1],
|
||||
"Particle_8hpp_source.html":[4,0,0,1],
|
||||
"PenningTrap_8cpp.html":[4,0,1,2],
|
||||
"PenningTrap_8cpp_source.html":[4,0,1,2],
|
||||
"PenningTrap_8hpp.html":[4,0,0,2],
|
||||
"PenningTrap_8hpp_source.html":[4,0,0,2],
|
||||
"annotated.html":[3,0],
|
||||
"bug.html":[1],
|
||||
"classParticle.html":[3,0,0],
|
||||
"classParticle.html#a00e108823877a25513ccae7cac011b4c":[3,0,0,0],
|
||||
"classParticle.html#a4a5d22c7aeca66f67d083f270cba25df":[3,0,0,5],
|
||||
"classParticle.html#a566dcc1de4bdc01251776948798ea8e1":[3,0,0,3],
|
||||
"classParticle.html#aa797d319549dc2a0beb06cdbfd430232":[3,0,0,1],
|
||||
"classParticle.html#acf1a0f3c978b06d76df5bb4279594467":[3,0,0,4],
|
||||
"classParticle.html#aedcc7e1bc53b0e2b1a4a07c9a1b47563":[3,0,0,2],
|
||||
"classPenningTrap.html":[3,0,1],
|
||||
"classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f":[3,0,1,12],
|
||||
"classPenningTrap.html#a045adb85e97a8e0c38fb36d2fd74eeee":[3,0,1,8],
|
||||
"classPenningTrap.html#a0cac3509aa96e71a26d3b2c902e27716":[3,0,1,10],
|
||||
"classPenningTrap.html#a135db7d991d9b88b00fde4edee71f78d":[3,0,1,9],
|
||||
"classPenningTrap.html#a2a3e7f480ba52e9f24d4c50c3981a784":[3,0,1,4],
|
||||
"classPenningTrap.html#a4790f41e4fbc6ede4991aa7bbda92182":[3,0,1,6],
|
||||
"classPenningTrap.html#a56544b6f4befb42984e9650cf2a40965":[3,0,1,2],
|
||||
"classPenningTrap.html#a66dfe89c68716b9502927b97f59c27d2":[3,0,1,11],
|
||||
"classPenningTrap.html#a6e9776ff5b149f01080800716455d7c8":[3,0,1,1],
|
||||
"classPenningTrap.html#a715329844d75ec4c04f8391421fb4e89":[3,0,1,13],
|
||||
"classPenningTrap.html#a81add5063bd5f29d77f0b5c299c6c560":[3,0,1,0],
|
||||
"classPenningTrap.html#a83cc7a04dae009ed8e75453c38fdf8be":[3,0,1,7],
|
||||
"classPenningTrap.html#a978a2e2026a4b5308d5184712f81704b":[3,0,1,5],
|
||||
"classPenningTrap.html#ab891b839c40eeb38d8a2a636c70090a9":[3,0,1,3],
|
||||
"classes.html":[3,1],
|
||||
"constants_8hpp.html":[4,0,0,0],
|
||||
"constants_8hpp.html#a0acb682b8260ab1c60b918599864e2e5":[4,0,0,0,1],
|
||||
"constants_8hpp.html#a4e451456ad7e9276ed0afa42826e7ccb":[4,0,0,0,0],
|
||||
"constants_8hpp.html#af40a326b23c68a27cebe60f16634a2cb":[4,0,0,0,2],
|
||||
"constants_8hpp_source.html":[4,0,0,0],
|
||||
"dir_68267d1309a1af8e8297ef4c3efbcdba.html":[4,0,1],
|
||||
"dir_d44c64559bbebec7f509842c48db8b23.html":[4,0,0],
|
||||
"files.html":[4,0],
|
||||
"functions.html":[3,2,0],
|
||||
"functions_func.html":[3,2,1],
|
||||
"functions_rela.html":[3,2,3],
|
||||
"functions_vars.html":[3,2,2],
|
||||
"globals.html":[4,1,0],
|
||||
"globals_defs.html":[4,1,2],
|
||||
"globals_func.html":[4,1,1],
|
||||
"Particle_8cpp.html":[6,0,1,2],
|
||||
"Particle_8cpp_source.html":[6,0,1,2],
|
||||
"Particle_8hpp.html":[6,0,0,1],
|
||||
"Particle_8hpp_source.html":[6,0,0,1],
|
||||
"PenningTrap_8cpp.html":[6,0,1,3],
|
||||
"PenningTrap_8cpp_source.html":[6,0,1,3],
|
||||
"PenningTrap_8hpp.html":[6,0,0,2],
|
||||
"PenningTrap_8hpp_source.html":[6,0,0,2],
|
||||
"animate__100__particles_8py_source.html":[6,0,1,0,0],
|
||||
"annotated.html":[5,0],
|
||||
"bug.html":[4],
|
||||
"classParticle.html":[5,0,0],
|
||||
"classParticle.html#a1c59101411db43624828b766f87ad460":[5,0,0,4],
|
||||
"classParticle.html#a3a10400add8dd22b8031330c2aafb6fe":[5,0,0,5],
|
||||
"classParticle.html#a566dcc1de4bdc01251776948798ea8e1":[5,0,0,3],
|
||||
"classParticle.html#aa797d319549dc2a0beb06cdbfd430232":[5,0,0,1],
|
||||
"classParticle.html#aedcc7e1bc53b0e2b1a4a07c9a1b47563":[5,0,0,2],
|
||||
"classParticle.html#af1d7535fb8311eaa77d2b7b345882ec4":[5,0,0,0],
|
||||
"classPenningTrap.html":[5,0,1],
|
||||
"classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f":[5,0,1,24],
|
||||
"classPenningTrap.html#a0cac3509aa96e71a26d3b2c902e27716":[5,0,1,20],
|
||||
"classPenningTrap.html#a2c01108b52c8e2a003cf9170da9e7682":[5,0,1,15],
|
||||
"classPenningTrap.html#a2f168622587709b9e3c49077f0b9a640":[5,0,1,22],
|
||||
"classPenningTrap.html#a2fe1cefbae18fa5808155ee0d2df713c":[5,0,1,16],
|
||||
"classPenningTrap.html#a361f2c4862c90b5e8e2a2f50c6a95655":[5,0,1,6],
|
||||
"classPenningTrap.html#a36946152fd951b1f7c346c51ff900d8e":[5,0,1,5],
|
||||
"classPenningTrap.html#a3c0a44e4e0a94366ff609e81fe463fa2":[5,0,1,17],
|
||||
"classPenningTrap.html#a5846c8f75cdc543fd9cf0b2185a3ef22":[5,0,1,7],
|
||||
"classPenningTrap.html#a5b6c6d4636f3a6e279ccde59d4a345e8":[5,0,1,0],
|
||||
"classPenningTrap.html#a66dfe89c68716b9502927b97f59c27d2":[5,0,1,21],
|
||||
"classPenningTrap.html#a6e9776ff5b149f01080800716455d7c8":[5,0,1,3],
|
||||
"classPenningTrap.html#a715329844d75ec4c04f8391421fb4e89":[5,0,1,27],
|
||||
"classPenningTrap.html#a7a1d9f0528a12308de25bc30718da20a":[5,0,1,13],
|
||||
"classPenningTrap.html#a7f210bb2768a5d79ced4b0df0df97598":[5,0,1,8],
|
||||
"classPenningTrap.html#a826b7fa8e709d481eb1dee7d0c2cdc08":[5,0,1,10],
|
||||
"classPenningTrap.html#a830be1b8cbf59664e060b6edbeaa302f":[5,0,1,1],
|
||||
"classPenningTrap.html#a869f032f37d0569ed16f224b4c4356ae":[5,0,1,19],
|
||||
"classPenningTrap.html#a8ca4e21291f60fde619c14099d8c4e8e":[5,0,1,26],
|
||||
"classPenningTrap.html#a9a301b0540078c36697880ef204afdf3":[5,0,1,14],
|
||||
"classPenningTrap.html#a9d1d8e90ca839b928aee1ad0cd4aff43":[5,0,1,12],
|
||||
"classPenningTrap.html#aaee129f177657455348d0c8ae1441dea":[5,0,1,11],
|
||||
"classPenningTrap.html#ab9ea97a406534bbe621a95215144875e":[5,0,1,4],
|
||||
"classPenningTrap.html#ac529aa26c288f34eae184a67e6bac41f":[5,0,1,9],
|
||||
"classPenningTrap.html#ad8bc4df7ab3eed53b16cfdff38e7760b":[5,0,1,18],
|
||||
"classPenningTrap.html#addc96789dcfec07b75156e19fee82f4f":[5,0,1,2],
|
||||
"classPenningTrap.html#ae915f6ad0eef1fb46530e836b6e071e5":[5,0,1,25],
|
||||
"classPenningTrap.html#ae9b5afdaa5cd366e94bd294452a1eed4":[5,0,1,23],
|
||||
"classPenningTrapTest.html":[5,0,2],
|
||||
"classPenningTrapTest.html#a5f4f0b150e54ce463bb29f76d49883f9":[5,0,2,2],
|
||||
"classPenningTrapTest.html#a68449d508e66205bc8b27fa5f60db508":[5,0,2,4],
|
||||
"classPenningTrapTest.html#a6a303be62039ca2ecccd8252744d4dc8":[5,0,2,1],
|
||||
"classPenningTrapTest.html#ad668d7d875bdc1909a42426bf9dead9e":[5,0,2,0],
|
||||
"classPenningTrapTest.html#ae6d0c8e0d80338fb7c7edefc97331046":[5,0,2,3],
|
||||
"classes.html":[5,1],
|
||||
"constants_8hpp.html":[6,0,0,0],
|
||||
"constants_8hpp.html#a0acb682b8260ab1c60b918599864e2e5":[6,0,0,0,3],
|
||||
"constants_8hpp.html#a2ff491cc7958ffd5e749c518a4a60ec8":[6,0,0,0,1],
|
||||
"constants_8hpp.html#a4e451456ad7e9276ed0afa42826e7ccb":[6,0,0,0,2],
|
||||
"constants_8hpp.html#af40a326b23c68a27cebe60f16634a2cb":[6,0,0,0,4],
|
||||
"constants_8hpp.html#af7602a3a314957137ad1cd719aa23789":[6,0,0,0,0],
|
||||
"constants_8hpp_source.html":[6,0,0,0],
|
||||
"dir_634e799a3947388232110823971192a8.html":[6,0,1,0],
|
||||
"dir_68267d1309a1af8e8297ef4c3efbcdba.html":[6,0,1],
|
||||
"dir_d44c64559bbebec7f509842c48db8b23.html":[6,0,0],
|
||||
"files.html":[6,0],
|
||||
"functions.html":[5,2,0],
|
||||
"functions_func.html":[5,2,1],
|
||||
"functions_rela.html":[5,2,3],
|
||||
"functions_vars.html":[5,2,2],
|
||||
"globals.html":[6,1,0],
|
||||
"globals_defs.html":[6,1,4],
|
||||
"globals_func.html":[6,1,1],
|
||||
"globals_type.html":[6,1,3],
|
||||
"globals_vars.html":[6,1,2],
|
||||
"index.html":[],
|
||||
"index.html#autotoc_md1":[0],
|
||||
"main_8cpp.html":[4,0,1,0],
|
||||
"main_8cpp_source.html":[4,0,1,0],
|
||||
"index.html#autotoc_md10":[3],
|
||||
"index.html#autotoc_md2":[0,0],
|
||||
"index.html#autotoc_md3":[0,1],
|
||||
"index.html#autotoc_md4":[1],
|
||||
"index.html#autotoc_md5":[2],
|
||||
"index.html#autotoc_md6":[2,0],
|
||||
"index.html#autotoc_md7":[2,1],
|
||||
"index.html#autotoc_md8":[2,1,0],
|
||||
"index.html#autotoc_md9":[2,1,1],
|
||||
"main_8cpp.html":[6,0,1,1],
|
||||
"main_8cpp.html#a213713d6ecc02a32b588ffd179dc7513":[6,0,1,1,4],
|
||||
"main_8cpp.html#a2efa69bb9d93049429ce4637075f1d30":[6,0,1,1,8],
|
||||
"main_8cpp.html#a33d9b1c76c3c80902f89a58b1a6d96ea":[6,0,1,1,1],
|
||||
"main_8cpp.html#a6b38b477c18e2f4268779751a88edab1":[6,0,1,1,3],
|
||||
"main_8cpp.html#a783789519f97c6430081171cacb0ffb1":[6,0,1,1,7],
|
||||
"main_8cpp.html#a8d92fb2ad085065fbd14718647551657":[6,0,1,1,0],
|
||||
"main_8cpp.html#a8fdbe2d5a872e50ef5ec1263243589d6":[6,0,1,1,5],
|
||||
"main_8cpp.html#ac1816f70ec612edc27848ef7f0875fdb":[6,0,1,1,2],
|
||||
"main_8cpp.html#ac67e0d59227856c4d42e7d01c75e0ad2":[6,0,1,1,6],
|
||||
"main_8cpp.html#ac70b61df65f4336f57ea9b4c35250df7":[6,0,1,1,9],
|
||||
"main_8cpp_source.html":[6,0,1,1],
|
||||
"pages.html":[],
|
||||
"test__suite_8cpp.html":[4,0,1,3],
|
||||
"test__suite_8cpp_source.html":[4,0,1,3],
|
||||
"todo.html":[2],
|
||||
"utils_8cpp.html":[4,0,1,4],
|
||||
"utils_8cpp.html#a58565270b643b24e3132f38c653e0199":[4,0,1,4,0],
|
||||
"utils_8cpp.html#acd2a9c7a7d5a7fe9163be8c4cc110746":[4,0,1,4,1],
|
||||
"utils_8cpp_source.html":[4,0,1,4],
|
||||
"utils_8hpp.html":[4,0,0,3],
|
||||
"utils_8hpp.html#ad54b96a1074f9df4dc892a41d115b72d":[4,0,0,3,1],
|
||||
"utils_8hpp.html#adfb618b2fdff47ef30a4a2b62c04f384":[4,0,0,3,2],
|
||||
"utils_8hpp.html#aecc1f7a8a2493b9e021e5bff76a00a5b":[4,0,0,3,0],
|
||||
"utils_8hpp_source.html":[4,0,0,3]
|
||||
"plot__2__particles_8py_source.html":[6,0,1,0,1],
|
||||
"plot__3d_8py_source.html":[6,0,1,0,2],
|
||||
"plot__particles__left_8py_source.html":[6,0,1,0,3],
|
||||
"plot__phase__space_8py_source.html":[6,0,1,0,4],
|
||||
"plot__relative__error_8py_source.html":[6,0,1,0,5],
|
||||
"plot__single__particle_8py_source.html":[6,0,1,0,6],
|
||||
"structsimulation.html":[5,0,3],
|
||||
"test__suite_8cpp.html":[6,0,1,4],
|
||||
"test__suite_8cpp_source.html":[6,0,1,4],
|
||||
"typedefs_8hpp.html":[6,0,0,3],
|
||||
"typedefs_8hpp.html#a33418f31f28663b8414c8f7182998c22":[6,0,0,3,3],
|
||||
"typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea":[6,0,0,3,5],
|
||||
"typedefs_8hpp.html#a46482a2697556c00556c9d73f461784f":[6,0,0,3,2],
|
||||
"typedefs_8hpp.html#a784799c37b5e4fb8bf4f6368e004dec6":[6,0,0,3,4],
|
||||
"typedefs_8hpp.html#aec69d34220fff45de238b9e01f2686af":[6,0,0,3,1],
|
||||
"typedefs_8hpp_source.html":[6,0,0,3],
|
||||
"utils_8cpp.html":[6,0,1,5],
|
||||
"utils_8cpp.html#a58565270b643b24e3132f38c653e0199":[6,0,1,5,3],
|
||||
"utils_8cpp.html#a6be6f938bcbb235ebb6a2ed9d08411b2":[6,0,1,5,0],
|
||||
"utils_8cpp.html#acd2a9c7a7d5a7fe9163be8c4cc110746":[6,0,1,5,4],
|
||||
"utils_8cpp.html#acf13f4e492199cb7231bfa646dbd08de":[6,0,1,5,2],
|
||||
"utils_8cpp.html#aff5e07c3c1d321709b0cc38e999f427b":[6,0,1,5,1],
|
||||
"utils_8cpp_source.html":[6,0,1,5],
|
||||
"utils_8hpp.html":[6,0,0,4],
|
||||
"utils_8hpp.html#a2cc3a2cdb635bac3c8b02e89d4d6af38":[6,0,0,4,4],
|
||||
"utils_8hpp.html#a60dca3177fb9cb5256609adc7af55168":[6,0,0,4,0],
|
||||
"utils_8hpp.html#a6fdd7217b750aff5b6295ece7cbdeffa":[6,0,0,4,5],
|
||||
"utils_8hpp.html#a73d4f21ad937dbc50a0c0538c78fd4f9":[6,0,0,4,1],
|
||||
"utils_8hpp.html#ab3e0cf669bddc59bd53998490ffb68b9":[6,0,0,4,3],
|
||||
"utils_8hpp.html#ad54b96a1074f9df4dc892a41d115b72d":[6,0,0,4,6],
|
||||
"utils_8hpp.html#adfb618b2fdff47ef30a4a2b62c04f384":[6,0,0,4,7],
|
||||
"utils_8hpp.html#aecc1f7a8a2493b9e021e5bff76a00a5b":[6,0,0,4,2],
|
||||
"utils_8hpp_source.html":[6,0,0,4]
|
||||
};
|
||||
|
||||
@@ -104,7 +104,6 @@ $(document).ready(function(){initNavTree('pages.html',''); initResizable(); });
|
||||
<div class="textblock">Here is a list of all related documentation pages:</div><div class="directory">
|
||||
<table class="directory">
|
||||
<tr id="row_0_" class="even"><td class="entry"><span style="width:16px;display:inline-block;"> </span><a class="el" href="bug.html" target="_self">Bug List</a></td><td class="desc"></td></tr>
|
||||
<tr id="row_1_" class="odd"><td class="entry"><span style="width:16px;display:inline-block;"> </span><a class="el" href="todo.html" target="_self">Todo List</a></td><td class="desc"></td></tr>
|
||||
</table>
|
||||
</div><!-- directory -->
|
||||
</div><!-- contents -->
|
||||
|
||||
153
docs/plot__2__particles_8py_source.html
Normal file
153
docs/plot__2__particles_8py_source.html
Normal file
@@ -0,0 +1,153 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=11"/>
|
||||
<meta name="generator" content="Doxygen 1.9.6"/>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1"/>
|
||||
<title>Penning Trap Simulation: src/scripts/plot_2_particles.py Source File</title>
|
||||
<link href="tabs.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="jquery.js"></script>
|
||||
<script type="text/javascript" src="dynsections.js"></script>
|
||||
<link href="navtree.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="resize.js"></script>
|
||||
<script type="text/javascript" src="navtreedata.js"></script>
|
||||
<script type="text/javascript" src="navtree.js"></script>
|
||||
<link href="search/search.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="search/searchdata.js"></script>
|
||||
<script type="text/javascript" src="search/search.js"></script>
|
||||
<script type="text/x-mathjax-config">
|
||||
MathJax.Hub.Config({
|
||||
extensions: ["tex2jax.js"],
|
||||
jax: ["input/TeX","output/HTML-CSS"],
|
||||
});
|
||||
</script>
|
||||
<script type="text/javascript" async="async" src="https://cdn.jsdelivr.net/npm/mathjax@2/MathJax.js"></script>
|
||||
<link href="doxygen.css" rel="stylesheet" type="text/css" />
|
||||
<link href="doxygen-awesome.css" rel="stylesheet" type="text/css"/>
|
||||
</head>
|
||||
<body>
|
||||
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
|
||||
<div id="titlearea">
|
||||
<table cellspacing="0" cellpadding="0">
|
||||
<tbody>
|
||||
<tr id="projectrow">
|
||||
<td id="projectalign">
|
||||
<div id="projectname">Penning Trap Simulation
|
||||
</div>
|
||||
<div id="projectbrief">Simulate particle behavior inside a Penning Trap</div>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
<!-- end header part -->
|
||||
<!-- Generated by Doxygen 1.9.6 -->
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
||||
var searchBox = new SearchBox("searchBox", "search/",'.html');
|
||||
/* @license-end */
|
||||
</script>
|
||||
<script type="text/javascript" src="menudata.js"></script>
|
||||
<script type="text/javascript" src="menu.js"></script>
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
||||
$(function() {
|
||||
initMenu('',true,false,'search.php','Search');
|
||||
$(document).ready(function() { init_search(); });
|
||||
});
|
||||
/* @license-end */
|
||||
</script>
|
||||
<div id="main-nav"></div>
|
||||
</div><!-- top -->
|
||||
<div id="side-nav" class="ui-resizable side-nav-resizable">
|
||||
<div id="nav-tree">
|
||||
<div id="nav-tree-contents">
|
||||
<div id="nav-sync" class="sync"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="splitbar" style="-moz-user-select:none;"
|
||||
class="ui-resizable-handle">
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
||||
$(document).ready(function(){initNavTree('plot__2__particles_8py_source.html',''); initResizable(); });
|
||||
/* @license-end */
|
||||
</script>
|
||||
<div id="doc-content">
|
||||
<!-- window showing the filter options -->
|
||||
<div id="MSearchSelectWindow"
|
||||
onmouseover="return searchBox.OnSearchSelectShow()"
|
||||
onmouseout="return searchBox.OnSearchSelectHide()"
|
||||
onkeydown="return searchBox.OnSearchSelectKey(event)">
|
||||
</div>
|
||||
|
||||
<!-- iframe showing the search results (closed by default) -->
|
||||
<div id="MSearchResultsWindow">
|
||||
<div id="MSearchResults">
|
||||
<div class="SRPage">
|
||||
<div id="SRIndex">
|
||||
<div id="SRResults"></div>
|
||||
<div class="SRStatus" id="Loading">Loading...</div>
|
||||
<div class="SRStatus" id="Searching">Searching...</div>
|
||||
<div class="SRStatus" id="NoMatches">No Matches</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="header">
|
||||
<div class="headertitle"><div class="title">plot_2_particles.py</div></div>
|
||||
</div><!--header-->
|
||||
<div class="contents">
|
||||
<div class="fragment"><div class="line"><a id="l00001" name="l00001"></a><span class="lineno"> 1</span><span class="keyword">import</span> matplotlib.pyplot <span class="keyword">as</span> plt</div>
|
||||
<div class="line"><a id="l00002" name="l00002"></a><span class="lineno"> 2</span><span class="keyword">import</span> numpy <span class="keyword">as</span> np</div>
|
||||
<div class="line"><a id="l00003" name="l00003"></a><span class="lineno"> 3</span> </div>
|
||||
<div class="line"><a id="l00004" name="l00004"></a><span class="lineno"> 4</span><span class="keyword">def </span>main():</div>
|
||||
<div class="line"><a id="l00005" name="l00005"></a><span class="lineno"> 5</span> files = [</div>
|
||||
<div class="line"><a id="l00006" name="l00006"></a><span class="lineno"> 6</span> <span class="stringliteral">"output/simulate_2_particles/no_interaction/particle_0_r.txt"</span>,</div>
|
||||
<div class="line"><a id="l00007" name="l00007"></a><span class="lineno"> 7</span> <span class="stringliteral">"output/simulate_2_particles/no_interaction/particle_1_r.txt"</span>,</div>
|
||||
<div class="line"><a id="l00008" name="l00008"></a><span class="lineno"> 8</span> <span class="stringliteral">"output/simulate_2_particles/with_interaction/particle_0_r.txt"</span>,</div>
|
||||
<div class="line"><a id="l00009" name="l00009"></a><span class="lineno"> 9</span> <span class="stringliteral">"output/simulate_2_particles/with_interaction/particle_1_r.txt"</span></div>
|
||||
<div class="line"><a id="l00010" name="l00010"></a><span class="lineno"> 10</span> ]</div>
|
||||
<div class="line"><a id="l00011" name="l00011"></a><span class="lineno"> 11</span> labels = [</div>
|
||||
<div class="line"><a id="l00012" name="l00012"></a><span class="lineno"> 12</span> <span class="stringliteral">"particle 1 no interaction"</span>,</div>
|
||||
<div class="line"><a id="l00013" name="l00013"></a><span class="lineno"> 13</span> <span class="stringliteral">"particle 2 no interaction"</span>,</div>
|
||||
<div class="line"><a id="l00014" name="l00014"></a><span class="lineno"> 14</span> <span class="stringliteral">"particle 1 with interaction"</span>,</div>
|
||||
<div class="line"><a id="l00015" name="l00015"></a><span class="lineno"> 15</span> <span class="stringliteral">"particle 2 with interaction"</span>,</div>
|
||||
<div class="line"><a id="l00016" name="l00016"></a><span class="lineno"> 16</span> ]</div>
|
||||
<div class="line"><a id="l00017" name="l00017"></a><span class="lineno"> 17</span> colors = [</div>
|
||||
<div class="line"><a id="l00018" name="l00018"></a><span class="lineno"> 18</span> <span class="stringliteral">"lightskyblue"</span>,</div>
|
||||
<div class="line"><a id="l00019" name="l00019"></a><span class="lineno"> 19</span> <span class="stringliteral">"lightskyblue"</span>,</div>
|
||||
<div class="line"><a id="l00020" name="l00020"></a><span class="lineno"> 20</span> <span class="stringliteral">"salmon"</span>,</div>
|
||||
<div class="line"><a id="l00021" name="l00021"></a><span class="lineno"> 21</span> <span class="stringliteral">"salmon"</span></div>
|
||||
<div class="line"><a id="l00022" name="l00022"></a><span class="lineno"> 22</span> ]</div>
|
||||
<div class="line"><a id="l00023" name="l00023"></a><span class="lineno"> 23</span> <span class="keywordflow">for</span> label, color, file <span class="keywordflow">in</span> zip(labels, colors, files):</div>
|
||||
<div class="line"><a id="l00024" name="l00024"></a><span class="lineno"> 24</span> <span class="keyword">with</span> open(file) <span class="keyword">as</span> f:</div>
|
||||
<div class="line"><a id="l00025" name="l00025"></a><span class="lineno"> 25</span> lines = f.readlines()</div>
|
||||
<div class="line"><a id="l00026" name="l00026"></a><span class="lineno"> 26</span> t = np.linspace(0, 50, len(lines))</div>
|
||||
<div class="line"><a id="l00027" name="l00027"></a><span class="lineno"> 27</span> r = np.array([list(map(float, line.strip().split(<span class="stringliteral">","</span>))) <span class="keywordflow">for</span> line <span class="keywordflow">in</span> lines])</div>
|
||||
<div class="line"><a id="l00028" name="l00028"></a><span class="lineno"> 28</span> plt.plot(r[:,0], r[:,1], label=label, color=color)</div>
|
||||
<div class="line"><a id="l00029" name="l00029"></a><span class="lineno"> 29</span> </div>
|
||||
<div class="line"><a id="l00030" name="l00030"></a><span class="lineno"> 30</span> plt.xlabel(<span class="stringliteral">r"x $(\mu m)$"</span>)</div>
|
||||
<div class="line"><a id="l00031" name="l00031"></a><span class="lineno"> 31</span> plt.ylabel(<span class="stringliteral">r"y $(\mu m)$"</span>)</div>
|
||||
<div class="line"><a id="l00032" name="l00032"></a><span class="lineno"> 32</span> plt.title(<span class="stringliteral">r"2 particles with and without interactions."</span>)</div>
|
||||
<div class="line"><a id="l00033" name="l00033"></a><span class="lineno"> 33</span> <span class="comment"># plt.legend()</span></div>
|
||||
<div class="line"><a id="l00034" name="l00034"></a><span class="lineno"> 34</span> <span class="comment"># plt.show()</span></div>
|
||||
<div class="line"><a id="l00035" name="l00035"></a><span class="lineno"> 35</span> plt.savefig(<span class="stringliteral">"../latex/images/plot_2_particles_xy.pdf"</span>)</div>
|
||||
<div class="line"><a id="l00036" name="l00036"></a><span class="lineno"> 36</span> </div>
|
||||
<div class="line"><a id="l00037" name="l00037"></a><span class="lineno"> 37</span> </div>
|
||||
<div class="line"><a id="l00038" name="l00038"></a><span class="lineno"> 38</span><span class="keywordflow">if</span> __name__ == <span class="stringliteral">"__main__"</span>:</div>
|
||||
<div class="line"><a id="l00039" name="l00039"></a><span class="lineno"> 39</span> main()</div>
|
||||
</div><!-- fragment --></div><!-- contents -->
|
||||
</div><!-- doc-content -->
|
||||
<!-- start footer part -->
|
||||
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
|
||||
<ul>
|
||||
<li class="navelem"><a class="el" href="dir_68267d1309a1af8e8297ef4c3efbcdba.html">src</a></li><li class="navelem"><a class="el" href="dir_634e799a3947388232110823971192a8.html">scripts</a></li><li class="navelem"><b>plot_2_particles.py</b></li>
|
||||
<li class="footer">Generated by <a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.9.6 </li>
|
||||
</ul>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
154
docs/plot__3d_8py_source.html
Normal file
154
docs/plot__3d_8py_source.html
Normal file
@@ -0,0 +1,154 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=11"/>
|
||||
<meta name="generator" content="Doxygen 1.9.6"/>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1"/>
|
||||
<title>Penning Trap Simulation: src/scripts/plot_3d.py Source File</title>
|
||||
<link href="tabs.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="jquery.js"></script>
|
||||
<script type="text/javascript" src="dynsections.js"></script>
|
||||
<link href="navtree.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="resize.js"></script>
|
||||
<script type="text/javascript" src="navtreedata.js"></script>
|
||||
<script type="text/javascript" src="navtree.js"></script>
|
||||
<link href="search/search.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="search/searchdata.js"></script>
|
||||
<script type="text/javascript" src="search/search.js"></script>
|
||||
<script type="text/x-mathjax-config">
|
||||
MathJax.Hub.Config({
|
||||
extensions: ["tex2jax.js"],
|
||||
jax: ["input/TeX","output/HTML-CSS"],
|
||||
});
|
||||
</script>
|
||||
<script type="text/javascript" async="async" src="https://cdn.jsdelivr.net/npm/mathjax@2/MathJax.js"></script>
|
||||
<link href="doxygen.css" rel="stylesheet" type="text/css" />
|
||||
<link href="doxygen-awesome.css" rel="stylesheet" type="text/css"/>
|
||||
</head>
|
||||
<body>
|
||||
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
|
||||
<div id="titlearea">
|
||||
<table cellspacing="0" cellpadding="0">
|
||||
<tbody>
|
||||
<tr id="projectrow">
|
||||
<td id="projectalign">
|
||||
<div id="projectname">Penning Trap Simulation
|
||||
</div>
|
||||
<div id="projectbrief">Simulate particle behavior inside a Penning Trap</div>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
<!-- end header part -->
|
||||
<!-- Generated by Doxygen 1.9.6 -->
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
||||
var searchBox = new SearchBox("searchBox", "search/",'.html');
|
||||
/* @license-end */
|
||||
</script>
|
||||
<script type="text/javascript" src="menudata.js"></script>
|
||||
<script type="text/javascript" src="menu.js"></script>
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
||||
$(function() {
|
||||
initMenu('',true,false,'search.php','Search');
|
||||
$(document).ready(function() { init_search(); });
|
||||
});
|
||||
/* @license-end */
|
||||
</script>
|
||||
<div id="main-nav"></div>
|
||||
</div><!-- top -->
|
||||
<div id="side-nav" class="ui-resizable side-nav-resizable">
|
||||
<div id="nav-tree">
|
||||
<div id="nav-tree-contents">
|
||||
<div id="nav-sync" class="sync"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="splitbar" style="-moz-user-select:none;"
|
||||
class="ui-resizable-handle">
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
||||
$(document).ready(function(){initNavTree('plot__3d_8py_source.html',''); initResizable(); });
|
||||
/* @license-end */
|
||||
</script>
|
||||
<div id="doc-content">
|
||||
<!-- window showing the filter options -->
|
||||
<div id="MSearchSelectWindow"
|
||||
onmouseover="return searchBox.OnSearchSelectShow()"
|
||||
onmouseout="return searchBox.OnSearchSelectHide()"
|
||||
onkeydown="return searchBox.OnSearchSelectKey(event)">
|
||||
</div>
|
||||
|
||||
<!-- iframe showing the search results (closed by default) -->
|
||||
<div id="MSearchResultsWindow">
|
||||
<div id="MSearchResults">
|
||||
<div class="SRPage">
|
||||
<div id="SRIndex">
|
||||
<div id="SRResults"></div>
|
||||
<div class="SRStatus" id="Loading">Loading...</div>
|
||||
<div class="SRStatus" id="Searching">Searching...</div>
|
||||
<div class="SRStatus" id="NoMatches">No Matches</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="header">
|
||||
<div class="headertitle"><div class="title">plot_3d.py</div></div>
|
||||
</div><!--header-->
|
||||
<div class="contents">
|
||||
<div class="fragment"><div class="line"><a id="l00001" name="l00001"></a><span class="lineno"> 1</span><span class="keyword">import</span> matplotlib.pyplot <span class="keyword">as</span> plt</div>
|
||||
<div class="line"><a id="l00002" name="l00002"></a><span class="lineno"> 2</span><span class="keyword">import</span> numpy <span class="keyword">as</span> np</div>
|
||||
<div class="line"><a id="l00003" name="l00003"></a><span class="lineno"> 3</span> </div>
|
||||
<div class="line"><a id="l00004" name="l00004"></a><span class="lineno"> 4</span><span class="keyword">def </span>main():</div>
|
||||
<div class="line"><a id="l00005" name="l00005"></a><span class="lineno"> 5</span> files = [</div>
|
||||
<div class="line"><a id="l00006" name="l00006"></a><span class="lineno"> 6</span> <span class="stringliteral">"output/simulate_2_particles/no_interaction/particle_0_r.txt"</span>,</div>
|
||||
<div class="line"><a id="l00007" name="l00007"></a><span class="lineno"> 7</span> <span class="stringliteral">"output/simulate_2_particles/no_interaction/particle_1_r.txt"</span>,</div>
|
||||
<div class="line"><a id="l00008" name="l00008"></a><span class="lineno"> 8</span> <span class="stringliteral">"output/simulate_2_particles/with_interaction/particle_0_r.txt"</span>,</div>
|
||||
<div class="line"><a id="l00009" name="l00009"></a><span class="lineno"> 9</span> <span class="stringliteral">"output/simulate_2_particles/with_interaction/particle_1_r.txt"</span></div>
|
||||
<div class="line"><a id="l00010" name="l00010"></a><span class="lineno"> 10</span> ]</div>
|
||||
<div class="line"><a id="l00011" name="l00011"></a><span class="lineno"> 11</span> labels = [</div>
|
||||
<div class="line"><a id="l00012" name="l00012"></a><span class="lineno"> 12</span> <span class="stringliteral">"particle 1 no interaction"</span>,</div>
|
||||
<div class="line"><a id="l00013" name="l00013"></a><span class="lineno"> 13</span> <span class="stringliteral">"particle 2 no interaction"</span>,</div>
|
||||
<div class="line"><a id="l00014" name="l00014"></a><span class="lineno"> 14</span> <span class="stringliteral">"particle 1 with interaction"</span>,</div>
|
||||
<div class="line"><a id="l00015" name="l00015"></a><span class="lineno"> 15</span> <span class="stringliteral">"particle 2 with interaction"</span>,</div>
|
||||
<div class="line"><a id="l00016" name="l00016"></a><span class="lineno"> 16</span> ]</div>
|
||||
<div class="line"><a id="l00017" name="l00017"></a><span class="lineno"> 17</span> colors = [</div>
|
||||
<div class="line"><a id="l00018" name="l00018"></a><span class="lineno"> 18</span> <span class="stringliteral">"lightskyblue"</span>,</div>
|
||||
<div class="line"><a id="l00019" name="l00019"></a><span class="lineno"> 19</span> <span class="stringliteral">"deepskyblue"</span>,</div>
|
||||
<div class="line"><a id="l00020" name="l00020"></a><span class="lineno"> 20</span> <span class="stringliteral">"salmon"</span>,</div>
|
||||
<div class="line"><a id="l00021" name="l00021"></a><span class="lineno"> 21</span> <span class="stringliteral">"darkred"</span></div>
|
||||
<div class="line"><a id="l00022" name="l00022"></a><span class="lineno"> 22</span> ]</div>
|
||||
<div class="line"><a id="l00023" name="l00023"></a><span class="lineno"> 23</span> ax = plt.figure().add_subplot(projection=<span class="stringliteral">"3d"</span>)</div>
|
||||
<div class="line"><a id="l00024" name="l00024"></a><span class="lineno"> 24</span> <span class="keywordflow">for</span> label, color, file <span class="keywordflow">in</span> zip(labels, colors, files):</div>
|
||||
<div class="line"><a id="l00025" name="l00025"></a><span class="lineno"> 25</span> <span class="keyword">with</span> open(file) <span class="keyword">as</span> f:</div>
|
||||
<div class="line"><a id="l00026" name="l00026"></a><span class="lineno"> 26</span> lines = f.readlines()</div>
|
||||
<div class="line"><a id="l00027" name="l00027"></a><span class="lineno"> 27</span> t = np.linspace(0, 50, len(lines))</div>
|
||||
<div class="line"><a id="l00028" name="l00028"></a><span class="lineno"> 28</span> r = np.array([list(map(float, line.strip().split(<span class="stringliteral">","</span>))) <span class="keywordflow">for</span> line <span class="keywordflow">in</span> lines])</div>
|
||||
<div class="line"><a id="l00029" name="l00029"></a><span class="lineno"> 29</span> ax.plot(r[:,0], r[:,1], r[:,2], label=label, color=color)</div>
|
||||
<div class="line"><a id="l00030" name="l00030"></a><span class="lineno"> 30</span> </div>
|
||||
<div class="line"><a id="l00031" name="l00031"></a><span class="lineno"> 31</span> ax.set_xlabel(<span class="stringliteral">r"x $(\mu m)$"</span>)</div>
|
||||
<div class="line"><a id="l00032" name="l00032"></a><span class="lineno"> 32</span> ax.set_ylabel(<span class="stringliteral">r"y $(\mu m)$"</span>)</div>
|
||||
<div class="line"><a id="l00033" name="l00033"></a><span class="lineno"> 33</span> ax.set_zlabel(<span class="stringliteral">r"z $(\mu m)$"</span>)</div>
|
||||
<div class="line"><a id="l00034" name="l00034"></a><span class="lineno"> 34</span> plt.title(<span class="stringliteral">r"2 particles with and without interactions."</span>)</div>
|
||||
<div class="line"><a id="l00035" name="l00035"></a><span class="lineno"> 35</span> plt.legend()</div>
|
||||
<div class="line"><a id="l00036" name="l00036"></a><span class="lineno"> 36</span> plt.savefig(<span class="stringliteral">"../latex/images/3d_plot.pdf"</span>)</div>
|
||||
<div class="line"><a id="l00037" name="l00037"></a><span class="lineno"> 37</span> </div>
|
||||
<div class="line"><a id="l00038" name="l00038"></a><span class="lineno"> 38</span> </div>
|
||||
<div class="line"><a id="l00039" name="l00039"></a><span class="lineno"> 39</span><span class="keywordflow">if</span> __name__ == <span class="stringliteral">"__main__"</span>:</div>
|
||||
<div class="line"><a id="l00040" name="l00040"></a><span class="lineno"> 40</span> main()</div>
|
||||
</div><!-- fragment --></div><!-- contents -->
|
||||
</div><!-- doc-content -->
|
||||
<!-- start footer part -->
|
||||
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
|
||||
<ul>
|
||||
<li class="navelem"><a class="el" href="dir_68267d1309a1af8e8297ef4c3efbcdba.html">src</a></li><li class="navelem"><a class="el" href="dir_634e799a3947388232110823971192a8.html">scripts</a></li><li class="navelem"><b>plot_3d.py</b></li>
|
||||
<li class="footer">Generated by <a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.9.6 </li>
|
||||
</ul>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
182
docs/plot__particles__left_8py_source.html
Normal file
182
docs/plot__particles__left_8py_source.html
Normal file
@@ -0,0 +1,182 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=11"/>
|
||||
<meta name="generator" content="Doxygen 1.9.6"/>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1"/>
|
||||
<title>Penning Trap Simulation: src/scripts/plot_particles_left.py Source File</title>
|
||||
<link href="tabs.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="jquery.js"></script>
|
||||
<script type="text/javascript" src="dynsections.js"></script>
|
||||
<link href="navtree.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="resize.js"></script>
|
||||
<script type="text/javascript" src="navtreedata.js"></script>
|
||||
<script type="text/javascript" src="navtree.js"></script>
|
||||
<link href="search/search.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="search/searchdata.js"></script>
|
||||
<script type="text/javascript" src="search/search.js"></script>
|
||||
<script type="text/x-mathjax-config">
|
||||
MathJax.Hub.Config({
|
||||
extensions: ["tex2jax.js"],
|
||||
jax: ["input/TeX","output/HTML-CSS"],
|
||||
});
|
||||
</script>
|
||||
<script type="text/javascript" async="async" src="https://cdn.jsdelivr.net/npm/mathjax@2/MathJax.js"></script>
|
||||
<link href="doxygen.css" rel="stylesheet" type="text/css" />
|
||||
<link href="doxygen-awesome.css" rel="stylesheet" type="text/css"/>
|
||||
</head>
|
||||
<body>
|
||||
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
|
||||
<div id="titlearea">
|
||||
<table cellspacing="0" cellpadding="0">
|
||||
<tbody>
|
||||
<tr id="projectrow">
|
||||
<td id="projectalign">
|
||||
<div id="projectname">Penning Trap Simulation
|
||||
</div>
|
||||
<div id="projectbrief">Simulate particle behavior inside a Penning Trap</div>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
<!-- end header part -->
|
||||
<!-- Generated by Doxygen 1.9.6 -->
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
||||
var searchBox = new SearchBox("searchBox", "search/",'.html');
|
||||
/* @license-end */
|
||||
</script>
|
||||
<script type="text/javascript" src="menudata.js"></script>
|
||||
<script type="text/javascript" src="menu.js"></script>
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
||||
$(function() {
|
||||
initMenu('',true,false,'search.php','Search');
|
||||
$(document).ready(function() { init_search(); });
|
||||
});
|
||||
/* @license-end */
|
||||
</script>
|
||||
<div id="main-nav"></div>
|
||||
</div><!-- top -->
|
||||
<div id="side-nav" class="ui-resizable side-nav-resizable">
|
||||
<div id="nav-tree">
|
||||
<div id="nav-tree-contents">
|
||||
<div id="nav-sync" class="sync"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="splitbar" style="-moz-user-select:none;"
|
||||
class="ui-resizable-handle">
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
||||
$(document).ready(function(){initNavTree('plot__particles__left_8py_source.html',''); initResizable(); });
|
||||
/* @license-end */
|
||||
</script>
|
||||
<div id="doc-content">
|
||||
<!-- window showing the filter options -->
|
||||
<div id="MSearchSelectWindow"
|
||||
onmouseover="return searchBox.OnSearchSelectShow()"
|
||||
onmouseout="return searchBox.OnSearchSelectHide()"
|
||||
onkeydown="return searchBox.OnSearchSelectKey(event)">
|
||||
</div>
|
||||
|
||||
<!-- iframe showing the search results (closed by default) -->
|
||||
<div id="MSearchResultsWindow">
|
||||
<div id="MSearchResults">
|
||||
<div class="SRPage">
|
||||
<div id="SRIndex">
|
||||
<div id="SRResults"></div>
|
||||
<div class="SRStatus" id="Loading">Loading...</div>
|
||||
<div class="SRStatus" id="Searching">Searching...</div>
|
||||
<div class="SRStatus" id="NoMatches">No Matches</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="header">
|
||||
<div class="headertitle"><div class="title">plot_particles_left.py</div></div>
|
||||
</div><!--header-->
|
||||
<div class="contents">
|
||||
<div class="fragment"><div class="line"><a id="l00001" name="l00001"></a><span class="lineno"> 1</span><span class="keyword">import</span> matplotlib.pyplot <span class="keyword">as</span> plt</div>
|
||||
<div class="line"><a id="l00002" name="l00002"></a><span class="lineno"> 2</span><span class="keyword">import</span> seaborn <span class="keyword">as</span> sns</div>
|
||||
<div class="line"><a id="l00003" name="l00003"></a><span class="lineno"> 3</span> </div>
|
||||
<div class="line"><a id="l00004" name="l00004"></a><span class="lineno"> 4</span>sns.set_theme()</div>
|
||||
<div class="line"><a id="l00005" name="l00005"></a><span class="lineno"> 5</span>params = {</div>
|
||||
<div class="line"><a id="l00006" name="l00006"></a><span class="lineno"> 6</span> <span class="stringliteral">"font.family"</span>: <span class="stringliteral">"Serif"</span>,</div>
|
||||
<div class="line"><a id="l00007" name="l00007"></a><span class="lineno"> 7</span> <span class="stringliteral">"font.serif"</span>: <span class="stringliteral">"Roman"</span>, </div>
|
||||
<div class="line"><a id="l00008" name="l00008"></a><span class="lineno"> 8</span> <span class="stringliteral">"text.usetex"</span>: <span class="keyword">True</span>,</div>
|
||||
<div class="line"><a id="l00009" name="l00009"></a><span class="lineno"> 9</span> <span class="stringliteral">"axes.titlesize"</span>: <span class="stringliteral">"large"</span>,</div>
|
||||
<div class="line"><a id="l00010" name="l00010"></a><span class="lineno"> 10</span> <span class="stringliteral">"axes.labelsize"</span>: <span class="stringliteral">"large"</span>,</div>
|
||||
<div class="line"><a id="l00011" name="l00011"></a><span class="lineno"> 11</span> <span class="stringliteral">"xtick.labelsize"</span>: <span class="stringliteral">"large"</span>,</div>
|
||||
<div class="line"><a id="l00012" name="l00012"></a><span class="lineno"> 12</span> <span class="stringliteral">"ytick.labelsize"</span>: <span class="stringliteral">"large"</span>,</div>
|
||||
<div class="line"><a id="l00013" name="l00013"></a><span class="lineno"> 13</span> <span class="stringliteral">"legend.fontsize"</span>: <span class="stringliteral">"medium"</span></div>
|
||||
<div class="line"><a id="l00014" name="l00014"></a><span class="lineno"> 14</span>}</div>
|
||||
<div class="line"><a id="l00015" name="l00015"></a><span class="lineno"> 15</span>plt.rcParams.update(params)</div>
|
||||
<div class="line"><a id="l00016" name="l00016"></a><span class="lineno"> 16</span> </div>
|
||||
<div class="line"><a id="l00017" name="l00017"></a><span class="lineno"> 17</span><span class="keyword">def </span>main():</div>
|
||||
<div class="line"><a id="l00018" name="l00018"></a><span class="lineno"> 18</span> colors = [</div>
|
||||
<div class="line"><a id="l00019" name="l00019"></a><span class="lineno"> 19</span> <span class="stringliteral">"lightskyblue"</span>,</div>
|
||||
<div class="line"><a id="l00020" name="l00020"></a><span class="lineno"> 20</span> <span class="stringliteral">"deepskyblue"</span>,</div>
|
||||
<div class="line"><a id="l00021" name="l00021"></a><span class="lineno"> 21</span> <span class="stringliteral">"salmon"</span>,</div>
|
||||
<div class="line"><a id="l00022" name="l00022"></a><span class="lineno"> 22</span> <span class="stringliteral">"tomato"</span>,</div>
|
||||
<div class="line"><a id="l00023" name="l00023"></a><span class="lineno"> 23</span> <span class="stringliteral">"mediumaquamarine"</span>,</div>
|
||||
<div class="line"><a id="l00024" name="l00024"></a><span class="lineno"> 24</span> <span class="stringliteral">"mediumseagreen"</span></div>
|
||||
<div class="line"><a id="l00025" name="l00025"></a><span class="lineno"> 25</span> ]</div>
|
||||
<div class="line"><a id="l00026" name="l00026"></a><span class="lineno"> 26</span> files = [</div>
|
||||
<div class="line"><a id="l00027" name="l00027"></a><span class="lineno"> 27</span> <span class="stringliteral">"output/time_dependent_potential/wide_sweep.txt"</span>,</div>
|
||||
<div class="line"><a id="l00028" name="l00028"></a><span class="lineno"> 28</span> <span class="stringliteral">"output/time_dependent_potential/narrow_sweep.txt"</span>,</div>
|
||||
<div class="line"><a id="l00029" name="l00029"></a><span class="lineno"> 29</span> <span class="stringliteral">"output/time_dependent_potential/narrow_sweep_interactions.txt"</span>,</div>
|
||||
<div class="line"><a id="l00030" name="l00030"></a><span class="lineno"> 30</span> ]</div>
|
||||
<div class="line"><a id="l00031" name="l00031"></a><span class="lineno"> 31</span> outputs = [</div>
|
||||
<div class="line"><a id="l00032" name="l00032"></a><span class="lineno"> 32</span> <span class="stringliteral">"../latex/images/wide_sweep.pdf"</span>,</div>
|
||||
<div class="line"><a id="l00033" name="l00033"></a><span class="lineno"> 33</span> <span class="stringliteral">"../latex/images/narrow_sweep.pdf"</span>,</div>
|
||||
<div class="line"><a id="l00034" name="l00034"></a><span class="lineno"> 34</span> <span class="stringliteral">"../latex/images/narrow_sweep_interactions.pdf"</span>,</div>
|
||||
<div class="line"><a id="l00035" name="l00035"></a><span class="lineno"> 35</span> ]</div>
|
||||
<div class="line"><a id="l00036" name="l00036"></a><span class="lineno"> 36</span> <span class="keywordflow">for</span> file, output <span class="keywordflow">in</span> zip(files, outputs):</div>
|
||||
<div class="line"><a id="l00037" name="l00037"></a><span class="lineno"> 37</span> <span class="keyword">with</span> open(file) <span class="keyword">as</span> f:</div>
|
||||
<div class="line"><a id="l00038" name="l00038"></a><span class="lineno"> 38</span> lines = f.readlines()</div>
|
||||
<div class="line"><a id="l00039" name="l00039"></a><span class="lineno"> 39</span> x = []</div>
|
||||
<div class="line"><a id="l00040" name="l00040"></a><span class="lineno"> 40</span> y1 = []</div>
|
||||
<div class="line"><a id="l00041" name="l00041"></a><span class="lineno"> 41</span> y2 = []</div>
|
||||
<div class="line"><a id="l00042" name="l00042"></a><span class="lineno"> 42</span> y3 = []</div>
|
||||
<div class="line"><a id="l00043" name="l00043"></a><span class="lineno"> 43</span> <span class="keywordflow">for</span> line <span class="keywordflow">in</span> lines:</div>
|
||||
<div class="line"><a id="l00044" name="l00044"></a><span class="lineno"> 44</span> l = line.strip().split(<span class="stringliteral">","</span>)</div>
|
||||
<div class="line"><a id="l00045" name="l00045"></a><span class="lineno"> 45</span> x.append(float(l[0]))</div>
|
||||
<div class="line"><a id="l00046" name="l00046"></a><span class="lineno"> 46</span> y1.append(float(l[1]))</div>
|
||||
<div class="line"><a id="l00047" name="l00047"></a><span class="lineno"> 47</span> y2.append(float(l[2]))</div>
|
||||
<div class="line"><a id="l00048" name="l00048"></a><span class="lineno"> 48</span> y3.append(float(l[3]))</div>
|
||||
<div class="line"><a id="l00049" name="l00049"></a><span class="lineno"> 49</span> </div>
|
||||
<div class="line"><a id="l00050" name="l00050"></a><span class="lineno"> 50</span> fig, ax = plt.subplots()</div>
|
||||
<div class="line"><a id="l00051" name="l00051"></a><span class="lineno"> 51</span> ax.plot(x, y1, label=<span class="stringliteral">r"$f_{1} = 0.1$"</span>, color=colors[0])</div>
|
||||
<div class="line"><a id="l00052" name="l00052"></a><span class="lineno"> 52</span> ax.plot(x, y2, label=<span class="stringliteral">r"$f_{2} = 0.4$"</span>, color=colors[2])</div>
|
||||
<div class="line"><a id="l00053" name="l00053"></a><span class="lineno"> 53</span> ax.plot(x, y3, label=<span class="stringliteral">r"$f_{3} = 0.7$"</span>, color=colors[4])</div>
|
||||
<div class="line"><a id="l00054" name="l00054"></a><span class="lineno"> 54</span> </div>
|
||||
<div class="line"><a id="l00055" name="l00055"></a><span class="lineno"> 55</span> ax.set_xlabel(<span class="stringliteral">r"Frequency $\omega_V$ (MHz)"</span>)</div>
|
||||
<div class="line"><a id="l00056" name="l00056"></a><span class="lineno"> 56</span> <span class="comment"># ax.set_xlim((0, 2.8))</span></div>
|
||||
<div class="line"><a id="l00057" name="l00057"></a><span class="lineno"> 57</span> ax.set_ylabel(<span class="stringliteral">r"Fraction of particles left"</span>)</div>
|
||||
<div class="line"><a id="l00058" name="l00058"></a><span class="lineno"> 58</span> <span class="comment"># ax.set_ylim((-0.1, 1.1))</span></div>
|
||||
<div class="line"><a id="l00059" name="l00059"></a><span class="lineno"> 59</span> <span class="comment"># plt.title(r"The fraction of particles left in the Penning trap "</span></div>
|
||||
<div class="line"><a id="l00060" name="l00060"></a><span class="lineno"> 60</span> <span class="comment"># "after 500 microseconds for different amplitudes and frequencies")</span></div>
|
||||
<div class="line"><a id="l00061" name="l00061"></a><span class="lineno"> 61</span> </div>
|
||||
<div class="line"><a id="l00062" name="l00062"></a><span class="lineno"> 62</span> ax.legend(loc=<span class="stringliteral">"upper right"</span>)</div>
|
||||
<div class="line"><a id="l00063" name="l00063"></a><span class="lineno"> 63</span> </div>
|
||||
<div class="line"><a id="l00064" name="l00064"></a><span class="lineno"> 64</span> <span class="comment"># plt.show()</span></div>
|
||||
<div class="line"><a id="l00065" name="l00065"></a><span class="lineno"> 65</span> fig.savefig(output, bbox_inches=<span class="stringliteral">"tight"</span>)</div>
|
||||
<div class="line"><a id="l00066" name="l00066"></a><span class="lineno"> 66</span> </div>
|
||||
<div class="line"><a id="l00067" name="l00067"></a><span class="lineno"> 67</span><span class="keywordflow">if</span> __name__ == <span class="stringliteral">"__main__"</span>:</div>
|
||||
<div class="line"><a id="l00068" name="l00068"></a><span class="lineno"> 68</span> main()</div>
|
||||
</div><!-- fragment --></div><!-- contents -->
|
||||
</div><!-- doc-content -->
|
||||
<!-- start footer part -->
|
||||
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
|
||||
<ul>
|
||||
<li class="navelem"><a class="el" href="dir_68267d1309a1af8e8297ef4c3efbcdba.html">src</a></li><li class="navelem"><a class="el" href="dir_634e799a3947388232110823971192a8.html">scripts</a></li><li class="navelem"><b>plot_particles_left.py</b></li>
|
||||
<li class="footer">Generated by <a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.9.6 </li>
|
||||
</ul>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
167
docs/plot__phase__space_8py_source.html
Normal file
167
docs/plot__phase__space_8py_source.html
Normal file
@@ -0,0 +1,167 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=11"/>
|
||||
<meta name="generator" content="Doxygen 1.9.6"/>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1"/>
|
||||
<title>Penning Trap Simulation: src/scripts/plot_phase_space.py Source File</title>
|
||||
<link href="tabs.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="jquery.js"></script>
|
||||
<script type="text/javascript" src="dynsections.js"></script>
|
||||
<link href="navtree.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="resize.js"></script>
|
||||
<script type="text/javascript" src="navtreedata.js"></script>
|
||||
<script type="text/javascript" src="navtree.js"></script>
|
||||
<link href="search/search.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="search/searchdata.js"></script>
|
||||
<script type="text/javascript" src="search/search.js"></script>
|
||||
<script type="text/x-mathjax-config">
|
||||
MathJax.Hub.Config({
|
||||
extensions: ["tex2jax.js"],
|
||||
jax: ["input/TeX","output/HTML-CSS"],
|
||||
});
|
||||
</script>
|
||||
<script type="text/javascript" async="async" src="https://cdn.jsdelivr.net/npm/mathjax@2/MathJax.js"></script>
|
||||
<link href="doxygen.css" rel="stylesheet" type="text/css" />
|
||||
<link href="doxygen-awesome.css" rel="stylesheet" type="text/css"/>
|
||||
</head>
|
||||
<body>
|
||||
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
|
||||
<div id="titlearea">
|
||||
<table cellspacing="0" cellpadding="0">
|
||||
<tbody>
|
||||
<tr id="projectrow">
|
||||
<td id="projectalign">
|
||||
<div id="projectname">Penning Trap Simulation
|
||||
</div>
|
||||
<div id="projectbrief">Simulate particle behavior inside a Penning Trap</div>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
<!-- end header part -->
|
||||
<!-- Generated by Doxygen 1.9.6 -->
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
||||
var searchBox = new SearchBox("searchBox", "search/",'.html');
|
||||
/* @license-end */
|
||||
</script>
|
||||
<script type="text/javascript" src="menudata.js"></script>
|
||||
<script type="text/javascript" src="menu.js"></script>
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
||||
$(function() {
|
||||
initMenu('',true,false,'search.php','Search');
|
||||
$(document).ready(function() { init_search(); });
|
||||
});
|
||||
/* @license-end */
|
||||
</script>
|
||||
<div id="main-nav"></div>
|
||||
</div><!-- top -->
|
||||
<div id="side-nav" class="ui-resizable side-nav-resizable">
|
||||
<div id="nav-tree">
|
||||
<div id="nav-tree-contents">
|
||||
<div id="nav-sync" class="sync"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="splitbar" style="-moz-user-select:none;"
|
||||
class="ui-resizable-handle">
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
||||
$(document).ready(function(){initNavTree('plot__phase__space_8py_source.html',''); initResizable(); });
|
||||
/* @license-end */
|
||||
</script>
|
||||
<div id="doc-content">
|
||||
<!-- window showing the filter options -->
|
||||
<div id="MSearchSelectWindow"
|
||||
onmouseover="return searchBox.OnSearchSelectShow()"
|
||||
onmouseout="return searchBox.OnSearchSelectHide()"
|
||||
onkeydown="return searchBox.OnSearchSelectKey(event)">
|
||||
</div>
|
||||
|
||||
<!-- iframe showing the search results (closed by default) -->
|
||||
<div id="MSearchResultsWindow">
|
||||
<div id="MSearchResults">
|
||||
<div class="SRPage">
|
||||
<div id="SRIndex">
|
||||
<div id="SRResults"></div>
|
||||
<div class="SRStatus" id="Loading">Loading...</div>
|
||||
<div class="SRStatus" id="Searching">Searching...</div>
|
||||
<div class="SRStatus" id="NoMatches">No Matches</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="header">
|
||||
<div class="headertitle"><div class="title">plot_phase_space.py</div></div>
|
||||
</div><!--header-->
|
||||
<div class="contents">
|
||||
<div class="fragment"><div class="line"><a id="l00001" name="l00001"></a><span class="lineno"> 1</span><span class="keyword">import</span> matplotlib.pyplot <span class="keyword">as</span> plt</div>
|
||||
<div class="line"><a id="l00002" name="l00002"></a><span class="lineno"> 2</span><span class="keyword">import</span> numpy <span class="keyword">as</span> np</div>
|
||||
<div class="line"><a id="l00003" name="l00003"></a><span class="lineno"> 3</span> </div>
|
||||
<div class="line"><a id="l00004" name="l00004"></a><span class="lineno"> 4</span><span class="keyword">def </span>main():</div>
|
||||
<div class="line"><a id="l00005" name="l00005"></a><span class="lineno"> 5</span> directories = {</div>
|
||||
<div class="line"><a id="l00006" name="l00006"></a><span class="lineno"> 6</span> <span class="stringliteral">"output/simulate_2_particles/no_interaction/"</span>,</div>
|
||||
<div class="line"><a id="l00007" name="l00007"></a><span class="lineno"> 7</span> <span class="stringliteral">"output/simulate_2_particles/with_interaction/"</span>,</div>
|
||||
<div class="line"><a id="l00008" name="l00008"></a><span class="lineno"> 8</span> }</div>
|
||||
<div class="line"><a id="l00009" name="l00009"></a><span class="lineno"> 9</span> titles = {</div>
|
||||
<div class="line"><a id="l00010" name="l00010"></a><span class="lineno"> 10</span> <span class="stringliteral">"particles without interaction"</span>,</div>
|
||||
<div class="line"><a id="l00011" name="l00011"></a><span class="lineno"> 11</span> <span class="stringliteral">"particles with interaction"</span></div>
|
||||
<div class="line"><a id="l00012" name="l00012"></a><span class="lineno"> 12</span> }</div>
|
||||
<div class="line"><a id="l00013" name="l00013"></a><span class="lineno"> 13</span> files = [</div>
|
||||
<div class="line"><a id="l00014" name="l00014"></a><span class="lineno"> 14</span> <span class="stringliteral">"particle_0_r.txt"</span>,</div>
|
||||
<div class="line"><a id="l00015" name="l00015"></a><span class="lineno"> 15</span> <span class="stringliteral">"particle_0_v.txt"</span>,</div>
|
||||
<div class="line"><a id="l00016" name="l00016"></a><span class="lineno"> 16</span> <span class="stringliteral">"particle_1_r.txt"</span>,</div>
|
||||
<div class="line"><a id="l00017" name="l00017"></a><span class="lineno"> 17</span> <span class="stringliteral">"particle_1_v.txt"</span>,</div>
|
||||
<div class="line"><a id="l00018" name="l00018"></a><span class="lineno"> 18</span> ]</div>
|
||||
<div class="line"><a id="l00019" name="l00019"></a><span class="lineno"> 19</span> labels = [</div>
|
||||
<div class="line"><a id="l00020" name="l00020"></a><span class="lineno"> 20</span> <span class="stringliteral">r"particle 1 r"</span>,</div>
|
||||
<div class="line"><a id="l00021" name="l00021"></a><span class="lineno"> 21</span> <span class="stringliteral">r"particle 1 v"</span>,</div>
|
||||
<div class="line"><a id="l00022" name="l00022"></a><span class="lineno"> 22</span> <span class="stringliteral">r"particle 2 r"</span>,</div>
|
||||
<div class="line"><a id="l00023" name="l00023"></a><span class="lineno"> 23</span> <span class="stringliteral">r"particle 2 v"</span>,</div>
|
||||
<div class="line"><a id="l00024" name="l00024"></a><span class="lineno"> 24</span> ]</div>
|
||||
<div class="line"><a id="l00025" name="l00025"></a><span class="lineno"> 25</span> colors = [</div>
|
||||
<div class="line"><a id="l00026" name="l00026"></a><span class="lineno"> 26</span> <span class="stringliteral">"lightskyblue"</span>,</div>
|
||||
<div class="line"><a id="l00027" name="l00027"></a><span class="lineno"> 27</span> <span class="stringliteral">"deepskyblue"</span>,</div>
|
||||
<div class="line"><a id="l00028" name="l00028"></a><span class="lineno"> 28</span> <span class="stringliteral">"salmon"</span>,</div>
|
||||
<div class="line"><a id="l00029" name="l00029"></a><span class="lineno"> 29</span> <span class="stringliteral">"tomato"</span>,</div>
|
||||
<div class="line"><a id="l00030" name="l00030"></a><span class="lineno"> 30</span> ]</div>
|
||||
<div class="line"><a id="l00031" name="l00031"></a><span class="lineno"> 31</span> fig1, axs1 = plt.subplots(2,1)</div>
|
||||
<div class="line"><a id="l00032" name="l00032"></a><span class="lineno"> 32</span> fig2, axs2 = plt.subplots(2,1)</div>
|
||||
<div class="line"><a id="l00033" name="l00033"></a><span class="lineno"> 33</span> <span class="keywordflow">for</span> i, (dir, title) <span class="keywordflow">in</span> enumerate(zip(directories, titles)):</div>
|
||||
<div class="line"><a id="l00034" name="l00034"></a><span class="lineno"> 34</span> <span class="keywordflow">for</span> label, color, file <span class="keywordflow">in</span> zip(labels, colors, files):</div>
|
||||
<div class="line"><a id="l00035" name="l00035"></a><span class="lineno"> 35</span> <span class="keyword">with</span> open(dir+file) <span class="keyword">as</span> f:</div>
|
||||
<div class="line"><a id="l00036" name="l00036"></a><span class="lineno"> 36</span> lines = f.readlines()</div>
|
||||
<div class="line"><a id="l00037" name="l00037"></a><span class="lineno"> 37</span> t = np.linspace(0, 50, len(lines))</div>
|
||||
<div class="line"><a id="l00038" name="l00038"></a><span class="lineno"> 38</span> r = np.array([list(map(float, line.strip().split(<span class="stringliteral">","</span>))) <span class="keywordflow">for</span> line <span class="keywordflow">in</span> lines])</div>
|
||||
<div class="line"><a id="l00039" name="l00039"></a><span class="lineno"> 39</span> axs1[i].plot(t, r[:,0], label=label, color=color)</div>
|
||||
<div class="line"><a id="l00040" name="l00040"></a><span class="lineno"> 40</span> axs2[i].plot(t, r[:,2], label=label, color=color)</div>
|
||||
<div class="line"><a id="l00041" name="l00041"></a><span class="lineno"> 41</span> </div>
|
||||
<div class="line"><a id="l00042" name="l00042"></a><span class="lineno"> 42</span> axs1[i].set(xlabel=<span class="stringliteral">r"t $(\mu s)$"</span>, ylabel = <span class="stringliteral">r"z $(\mu m)$"</span>)</div>
|
||||
<div class="line"><a id="l00043" name="l00043"></a><span class="lineno"> 43</span> </div>
|
||||
<div class="line"><a id="l00044" name="l00044"></a><span class="lineno"> 44</span> axs1[i].legend()</div>
|
||||
<div class="line"><a id="l00045" name="l00045"></a><span class="lineno"> 45</span> axs1[i].set_title(title)</div>
|
||||
<div class="line"><a id="l00046" name="l00046"></a><span class="lineno"> 46</span> </div>
|
||||
<div class="line"><a id="l00047" name="l00047"></a><span class="lineno"> 47</span> <span class="comment"># plt.show()</span></div>
|
||||
<div class="line"><a id="l00048" name="l00048"></a><span class="lineno"> 48</span> fig1.savefig(<span class="stringliteral">"../latex/images/phase_space_2_particles_x.pdf"</span>)</div>
|
||||
<div class="line"><a id="l00049" name="l00049"></a><span class="lineno"> 49</span> fig2.savefig(<span class="stringliteral">"../latex/images/phase_space_2_particles_z.pdf"</span>)</div>
|
||||
<div class="line"><a id="l00050" name="l00050"></a><span class="lineno"> 50</span> </div>
|
||||
<div class="line"><a id="l00051" name="l00051"></a><span class="lineno"> 51</span> </div>
|
||||
<div class="line"><a id="l00052" name="l00052"></a><span class="lineno"> 52</span><span class="keywordflow">if</span> __name__ == <span class="stringliteral">"__main__"</span>:</div>
|
||||
<div class="line"><a id="l00053" name="l00053"></a><span class="lineno"> 53</span> main()</div>
|
||||
</div><!-- fragment --></div><!-- contents -->
|
||||
</div><!-- doc-content -->
|
||||
<!-- start footer part -->
|
||||
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
|
||||
<ul>
|
||||
<li class="navelem"><a class="el" href="dir_68267d1309a1af8e8297ef4c3efbcdba.html">src</a></li><li class="navelem"><a class="el" href="dir_634e799a3947388232110823971192a8.html">scripts</a></li><li class="navelem"><b>plot_phase_space.py</b></li>
|
||||
<li class="footer">Generated by <a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.9.6 </li>
|
||||
</ul>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
165
docs/plot__relative__error_8py_source.html
Normal file
165
docs/plot__relative__error_8py_source.html
Normal file
@@ -0,0 +1,165 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=11"/>
|
||||
<meta name="generator" content="Doxygen 1.9.6"/>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1"/>
|
||||
<title>Penning Trap Simulation: src/scripts/plot_relative_error.py Source File</title>
|
||||
<link href="tabs.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="jquery.js"></script>
|
||||
<script type="text/javascript" src="dynsections.js"></script>
|
||||
<link href="navtree.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="resize.js"></script>
|
||||
<script type="text/javascript" src="navtreedata.js"></script>
|
||||
<script type="text/javascript" src="navtree.js"></script>
|
||||
<link href="search/search.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="search/searchdata.js"></script>
|
||||
<script type="text/javascript" src="search/search.js"></script>
|
||||
<script type="text/x-mathjax-config">
|
||||
MathJax.Hub.Config({
|
||||
extensions: ["tex2jax.js"],
|
||||
jax: ["input/TeX","output/HTML-CSS"],
|
||||
});
|
||||
</script>
|
||||
<script type="text/javascript" async="async" src="https://cdn.jsdelivr.net/npm/mathjax@2/MathJax.js"></script>
|
||||
<link href="doxygen.css" rel="stylesheet" type="text/css" />
|
||||
<link href="doxygen-awesome.css" rel="stylesheet" type="text/css"/>
|
||||
</head>
|
||||
<body>
|
||||
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
|
||||
<div id="titlearea">
|
||||
<table cellspacing="0" cellpadding="0">
|
||||
<tbody>
|
||||
<tr id="projectrow">
|
||||
<td id="projectalign">
|
||||
<div id="projectname">Penning Trap Simulation
|
||||
</div>
|
||||
<div id="projectbrief">Simulate particle behavior inside a Penning Trap</div>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
<!-- end header part -->
|
||||
<!-- Generated by Doxygen 1.9.6 -->
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
||||
var searchBox = new SearchBox("searchBox", "search/",'.html');
|
||||
/* @license-end */
|
||||
</script>
|
||||
<script type="text/javascript" src="menudata.js"></script>
|
||||
<script type="text/javascript" src="menu.js"></script>
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
||||
$(function() {
|
||||
initMenu('',true,false,'search.php','Search');
|
||||
$(document).ready(function() { init_search(); });
|
||||
});
|
||||
/* @license-end */
|
||||
</script>
|
||||
<div id="main-nav"></div>
|
||||
</div><!-- top -->
|
||||
<div id="side-nav" class="ui-resizable side-nav-resizable">
|
||||
<div id="nav-tree">
|
||||
<div id="nav-tree-contents">
|
||||
<div id="nav-sync" class="sync"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="splitbar" style="-moz-user-select:none;"
|
||||
class="ui-resizable-handle">
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
||||
$(document).ready(function(){initNavTree('plot__relative__error_8py_source.html',''); initResizable(); });
|
||||
/* @license-end */
|
||||
</script>
|
||||
<div id="doc-content">
|
||||
<!-- window showing the filter options -->
|
||||
<div id="MSearchSelectWindow"
|
||||
onmouseover="return searchBox.OnSearchSelectShow()"
|
||||
onmouseout="return searchBox.OnSearchSelectHide()"
|
||||
onkeydown="return searchBox.OnSearchSelectKey(event)">
|
||||
</div>
|
||||
|
||||
<!-- iframe showing the search results (closed by default) -->
|
||||
<div id="MSearchResultsWindow">
|
||||
<div id="MSearchResults">
|
||||
<div class="SRPage">
|
||||
<div id="SRIndex">
|
||||
<div id="SRResults"></div>
|
||||
<div class="SRStatus" id="Loading">Loading...</div>
|
||||
<div class="SRStatus" id="Searching">Searching...</div>
|
||||
<div class="SRStatus" id="NoMatches">No Matches</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="header">
|
||||
<div class="headertitle"><div class="title">plot_relative_error.py</div></div>
|
||||
</div><!--header-->
|
||||
<div class="contents">
|
||||
<div class="fragment"><div class="line"><a id="l00001" name="l00001"></a><span class="lineno"> 1</span><span class="keyword">import</span> matplotlib.pyplot <span class="keyword">as</span> plt</div>
|
||||
<div class="line"><a id="l00002" name="l00002"></a><span class="lineno"> 2</span><span class="keyword">import</span> numpy <span class="keyword">as</span> np</div>
|
||||
<div class="line"><a id="l00003" name="l00003"></a><span class="lineno"> 3</span> </div>
|
||||
<div class="line"><a id="l00004" name="l00004"></a><span class="lineno"> 4</span><span class="keyword">def </span>main():</div>
|
||||
<div class="line"><a id="l00005" name="l00005"></a><span class="lineno"> 5</span> directories = [</div>
|
||||
<div class="line"><a id="l00006" name="l00006"></a><span class="lineno"> 6</span> <span class="stringliteral">"output/relative_error/RK4/"</span>,</div>
|
||||
<div class="line"><a id="l00007" name="l00007"></a><span class="lineno"> 7</span> <span class="stringliteral">"output/relative_error/euler/"</span>,</div>
|
||||
<div class="line"><a id="l00008" name="l00008"></a><span class="lineno"> 8</span> ]</div>
|
||||
<div class="line"><a id="l00009" name="l00009"></a><span class="lineno"> 9</span> files = [</div>
|
||||
<div class="line"><a id="l00010" name="l00010"></a><span class="lineno"> 10</span> <span class="stringliteral">"4000_steps.txt"</span>,</div>
|
||||
<div class="line"><a id="l00011" name="l00011"></a><span class="lineno"> 11</span> <span class="stringliteral">"8000_steps.txt"</span>,</div>
|
||||
<div class="line"><a id="l00012" name="l00012"></a><span class="lineno"> 12</span> <span class="stringliteral">"16000_steps.txt"</span>,</div>
|
||||
<div class="line"><a id="l00013" name="l00013"></a><span class="lineno"> 13</span> <span class="stringliteral">"32000_steps.txt"</span>,</div>
|
||||
<div class="line"><a id="l00014" name="l00014"></a><span class="lineno"> 14</span> ]</div>
|
||||
<div class="line"><a id="l00015" name="l00015"></a><span class="lineno"> 15</span> labels = [</div>
|
||||
<div class="line"><a id="l00016" name="l00016"></a><span class="lineno"> 16</span> <span class="stringliteral">r"4000 steps"</span>,</div>
|
||||
<div class="line"><a id="l00017" name="l00017"></a><span class="lineno"> 17</span> <span class="stringliteral">r"8000 steps"</span>,</div>
|
||||
<div class="line"><a id="l00018" name="l00018"></a><span class="lineno"> 18</span> <span class="stringliteral">r"16000 steps"</span>,</div>
|
||||
<div class="line"><a id="l00019" name="l00019"></a><span class="lineno"> 19</span> <span class="stringliteral">r"32000 steps"</span>,</div>
|
||||
<div class="line"><a id="l00020" name="l00020"></a><span class="lineno"> 20</span> ]</div>
|
||||
<div class="line"><a id="l00021" name="l00021"></a><span class="lineno"> 21</span> titles = [</div>
|
||||
<div class="line"><a id="l00022" name="l00022"></a><span class="lineno"> 22</span> <span class="stringliteral">"Relative error for the RK4 method"</span>,</div>
|
||||
<div class="line"><a id="l00023" name="l00023"></a><span class="lineno"> 23</span> <span class="stringliteral">"Relative error for the forward Euler method"</span></div>
|
||||
<div class="line"><a id="l00024" name="l00024"></a><span class="lineno"> 24</span> ]</div>
|
||||
<div class="line"><a id="l00025" name="l00025"></a><span class="lineno"> 25</span> methods = [</div>
|
||||
<div class="line"><a id="l00026" name="l00026"></a><span class="lineno"> 26</span> <span class="stringliteral">"rk4"</span>,</div>
|
||||
<div class="line"><a id="l00027" name="l00027"></a><span class="lineno"> 27</span> <span class="stringliteral">"euler"</span></div>
|
||||
<div class="line"><a id="l00028" name="l00028"></a><span class="lineno"> 28</span> ]</div>
|
||||
<div class="line"><a id="l00029" name="l00029"></a><span class="lineno"> 29</span> fig1, axs1 = plt.subplots(2,1)</div>
|
||||
<div class="line"><a id="l00030" name="l00030"></a><span class="lineno"> 30</span> <span class="keywordflow">for</span> i, (dir, title) <span class="keywordflow">in</span> enumerate(list(zip(directories, titles))):</div>
|
||||
<div class="line"><a id="l00031" name="l00031"></a><span class="lineno"> 31</span> max_err = []</div>
|
||||
<div class="line"><a id="l00032" name="l00032"></a><span class="lineno"> 32</span> <span class="keywordflow">for</span> label, file <span class="keywordflow">in</span> zip(labels, files):</div>
|
||||
<div class="line"><a id="l00033" name="l00033"></a><span class="lineno"> 33</span> <span class="keyword">with</span> open(dir+file) <span class="keyword">as</span> f:</div>
|
||||
<div class="line"><a id="l00034" name="l00034"></a><span class="lineno"> 34</span> lines = f.readlines()</div>
|
||||
<div class="line"><a id="l00035" name="l00035"></a><span class="lineno"> 35</span> t = np.linspace(0, 50, len(lines))</div>
|
||||
<div class="line"><a id="l00036" name="l00036"></a><span class="lineno"> 36</span> r = np.array([float(line.strip()) <span class="keywordflow">for</span> line <span class="keywordflow">in</span> lines])</div>
|
||||
<div class="line"><a id="l00037" name="l00037"></a><span class="lineno"> 37</span> max_err.append(max(r))</div>
|
||||
<div class="line"><a id="l00038" name="l00038"></a><span class="lineno"> 38</span> axs1[i].plot(t, r, label=label)</div>
|
||||
<div class="line"><a id="l00039" name="l00039"></a><span class="lineno"> 39</span> </div>
|
||||
<div class="line"><a id="l00040" name="l00040"></a><span class="lineno"> 40</span> axs1[i].set(xlabel=<span class="stringliteral">r"t $(\mu s)$"</span>, ylabel = <span class="stringliteral">r"relative_error $(\mu m)$"</span>)</div>
|
||||
<div class="line"><a id="l00041" name="l00041"></a><span class="lineno"> 41</span> axs1[i].legend()</div>
|
||||
<div class="line"><a id="l00042" name="l00042"></a><span class="lineno"> 42</span> axs1[i].set_title(title)</div>
|
||||
<div class="line"><a id="l00043" name="l00043"></a><span class="lineno"> 43</span> </div>
|
||||
<div class="line"><a id="l00044" name="l00044"></a><span class="lineno"> 44</span> conv_rate = 1/3 * sum([np.log2(max_err[i+1]/max_err[i])/np.log2(.5) <span class="keywordflow">for</span> i <span class="keywordflow">in</span> range(3)])</div>
|
||||
<div class="line"><a id="l00045" name="l00045"></a><span class="lineno"> 45</span> print(f<span class="stringliteral">"{methods[i]}: {conv_rate}"</span>)</div>
|
||||
<div class="line"><a id="l00046" name="l00046"></a><span class="lineno"> 46</span> </div>
|
||||
<div class="line"><a id="l00047" name="l00047"></a><span class="lineno"> 47</span> fig1.savefig(<span class="stringliteral">"../latex/images/phase_space_2_particles_x.pdf"</span>)</div>
|
||||
<div class="line"><a id="l00048" name="l00048"></a><span class="lineno"> 48</span> </div>
|
||||
<div class="line"><a id="l00049" name="l00049"></a><span class="lineno"> 49</span> </div>
|
||||
<div class="line"><a id="l00050" name="l00050"></a><span class="lineno"> 50</span><span class="keywordflow">if</span> __name__ == <span class="stringliteral">"__main__"</span>:</div>
|
||||
<div class="line"><a id="l00051" name="l00051"></a><span class="lineno"> 51</span> main()</div>
|
||||
</div><!-- fragment --></div><!-- contents -->
|
||||
</div><!-- doc-content -->
|
||||
<!-- start footer part -->
|
||||
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
|
||||
<ul>
|
||||
<li class="navelem"><a class="el" href="dir_68267d1309a1af8e8297ef4c3efbcdba.html">src</a></li><li class="navelem"><a class="el" href="dir_634e799a3947388232110823971192a8.html">scripts</a></li><li class="navelem"><b>plot_relative_error.py</b></li>
|
||||
<li class="footer">Generated by <a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.9.6 </li>
|
||||
</ul>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
144
docs/plot__single__particle_8py_source.html
Normal file
144
docs/plot__single__particle_8py_source.html
Normal file
@@ -0,0 +1,144 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=11"/>
|
||||
<meta name="generator" content="Doxygen 1.9.6"/>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1"/>
|
||||
<title>Penning Trap Simulation: src/scripts/plot_single_particle.py Source File</title>
|
||||
<link href="tabs.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="jquery.js"></script>
|
||||
<script type="text/javascript" src="dynsections.js"></script>
|
||||
<link href="navtree.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="resize.js"></script>
|
||||
<script type="text/javascript" src="navtreedata.js"></script>
|
||||
<script type="text/javascript" src="navtree.js"></script>
|
||||
<link href="search/search.css" rel="stylesheet" type="text/css"/>
|
||||
<script type="text/javascript" src="search/searchdata.js"></script>
|
||||
<script type="text/javascript" src="search/search.js"></script>
|
||||
<script type="text/x-mathjax-config">
|
||||
MathJax.Hub.Config({
|
||||
extensions: ["tex2jax.js"],
|
||||
jax: ["input/TeX","output/HTML-CSS"],
|
||||
});
|
||||
</script>
|
||||
<script type="text/javascript" async="async" src="https://cdn.jsdelivr.net/npm/mathjax@2/MathJax.js"></script>
|
||||
<link href="doxygen.css" rel="stylesheet" type="text/css" />
|
||||
<link href="doxygen-awesome.css" rel="stylesheet" type="text/css"/>
|
||||
</head>
|
||||
<body>
|
||||
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
|
||||
<div id="titlearea">
|
||||
<table cellspacing="0" cellpadding="0">
|
||||
<tbody>
|
||||
<tr id="projectrow">
|
||||
<td id="projectalign">
|
||||
<div id="projectname">Penning Trap Simulation
|
||||
</div>
|
||||
<div id="projectbrief">Simulate particle behavior inside a Penning Trap</div>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
<!-- end header part -->
|
||||
<!-- Generated by Doxygen 1.9.6 -->
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
||||
var searchBox = new SearchBox("searchBox", "search/",'.html');
|
||||
/* @license-end */
|
||||
</script>
|
||||
<script type="text/javascript" src="menudata.js"></script>
|
||||
<script type="text/javascript" src="menu.js"></script>
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
||||
$(function() {
|
||||
initMenu('',true,false,'search.php','Search');
|
||||
$(document).ready(function() { init_search(); });
|
||||
});
|
||||
/* @license-end */
|
||||
</script>
|
||||
<div id="main-nav"></div>
|
||||
</div><!-- top -->
|
||||
<div id="side-nav" class="ui-resizable side-nav-resizable">
|
||||
<div id="nav-tree">
|
||||
<div id="nav-tree-contents">
|
||||
<div id="nav-sync" class="sync"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="splitbar" style="-moz-user-select:none;"
|
||||
class="ui-resizable-handle">
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
||||
$(document).ready(function(){initNavTree('plot__single__particle_8py_source.html',''); initResizable(); });
|
||||
/* @license-end */
|
||||
</script>
|
||||
<div id="doc-content">
|
||||
<!-- window showing the filter options -->
|
||||
<div id="MSearchSelectWindow"
|
||||
onmouseover="return searchBox.OnSearchSelectShow()"
|
||||
onmouseout="return searchBox.OnSearchSelectHide()"
|
||||
onkeydown="return searchBox.OnSearchSelectKey(event)">
|
||||
</div>
|
||||
|
||||
<!-- iframe showing the search results (closed by default) -->
|
||||
<div id="MSearchResultsWindow">
|
||||
<div id="MSearchResults">
|
||||
<div class="SRPage">
|
||||
<div id="SRIndex">
|
||||
<div id="SRResults"></div>
|
||||
<div class="SRStatus" id="Loading">Loading...</div>
|
||||
<div class="SRStatus" id="Searching">Searching...</div>
|
||||
<div class="SRStatus" id="NoMatches">No Matches</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="header">
|
||||
<div class="headertitle"><div class="title">plot_single_particle.py</div></div>
|
||||
</div><!--header-->
|
||||
<div class="contents">
|
||||
<div class="fragment"><div class="line"><a id="l00001" name="l00001"></a><span class="lineno"> 1</span><span class="keyword">import</span> matplotlib.pyplot <span class="keyword">as</span> plt</div>
|
||||
<div class="line"><a id="l00002" name="l00002"></a><span class="lineno"> 2</span><span class="keyword">import</span> numpy <span class="keyword">as</span> np</div>
|
||||
<div class="line"><a id="l00003" name="l00003"></a><span class="lineno"> 3</span> </div>
|
||||
<div class="line"><a id="l00004" name="l00004"></a><span class="lineno"> 4</span><span class="keyword">def </span>z(t):</div>
|
||||
<div class="line"><a id="l00005" name="l00005"></a><span class="lineno"> 5</span> V_0 = 25.*9.64852558 * 10**4</div>
|
||||
<div class="line"><a id="l00006" name="l00006"></a><span class="lineno"> 6</span> m = 40.</div>
|
||||
<div class="line"><a id="l00007" name="l00007"></a><span class="lineno"> 7</span> d = 500.</div>
|
||||
<div class="line"><a id="l00008" name="l00008"></a><span class="lineno"> 8</span> w_z = np.sqrt((2.*V_0)/(m*d*d))</div>
|
||||
<div class="line"><a id="l00009" name="l00009"></a><span class="lineno"> 9</span> <span class="keywordflow">return</span> 20.*np.cos(w_z*t)</div>
|
||||
<div class="line"><a id="l00010" name="l00010"></a><span class="lineno"> 10</span> </div>
|
||||
<div class="line"><a id="l00011" name="l00011"></a><span class="lineno"> 11</span><span class="keyword">def </span>main():</div>
|
||||
<div class="line"><a id="l00012" name="l00012"></a><span class="lineno"> 12</span> filename = <span class="stringliteral">"output/simulate_single_particle/particle_0_r.txt"</span></div>
|
||||
<div class="line"><a id="l00013" name="l00013"></a><span class="lineno"> 13</span> r = t = []</div>
|
||||
<div class="line"><a id="l00014" name="l00014"></a><span class="lineno"> 14</span> <span class="keyword">with</span> open(filename) <span class="keyword">as</span> f:</div>
|
||||
<div class="line"><a id="l00015" name="l00015"></a><span class="lineno"> 15</span> lines = f.readlines()</div>
|
||||
<div class="line"><a id="l00016" name="l00016"></a><span class="lineno"> 16</span> t = np.linspace(0, 50, len(lines))</div>
|
||||
<div class="line"><a id="l00017" name="l00017"></a><span class="lineno"> 17</span> r = np.array([list(map(float, line.strip().split(<span class="stringliteral">","</span>))) <span class="keywordflow">for</span> line <span class="keywordflow">in</span> lines])</div>
|
||||
<div class="line"><a id="l00018" name="l00018"></a><span class="lineno"> 18</span> </div>
|
||||
<div class="line"><a id="l00019" name="l00019"></a><span class="lineno"> 19</span> plt.plot(t, r[:, 2], label=<span class="stringliteral">"approximation"</span>)</div>
|
||||
<div class="line"><a id="l00020" name="l00020"></a><span class="lineno"> 20</span> plt.plot(t, z(t), label=<span class="stringliteral">"analytical"</span>)</div>
|
||||
<div class="line"><a id="l00021" name="l00021"></a><span class="lineno"> 21</span> plt.xlabel(<span class="stringliteral">r"time $(\mu s)$"</span>)</div>
|
||||
<div class="line"><a id="l00022" name="l00022"></a><span class="lineno"> 22</span> plt.ylabel(<span class="stringliteral">r"z $(\mu m)$"</span>)</div>
|
||||
<div class="line"><a id="l00023" name="l00023"></a><span class="lineno"> 23</span> plt.title(<span class="stringliteral">r"Movement of a single particle in the x direction"</span>)</div>
|
||||
<div class="line"><a id="l00024" name="l00024"></a><span class="lineno"> 24</span> plt.legend()</div>
|
||||
<div class="line"><a id="l00025" name="l00025"></a><span class="lineno"> 25</span> <span class="comment"># plt.savefig("../latex/images/single_particle.pdf")</span></div>
|
||||
<div class="line"><a id="l00026" name="l00026"></a><span class="lineno"> 26</span> plt.show()</div>
|
||||
<div class="line"><a id="l00027" name="l00027"></a><span class="lineno"> 27</span> </div>
|
||||
<div class="line"><a id="l00028" name="l00028"></a><span class="lineno"> 28</span> </div>
|
||||
<div class="line"><a id="l00029" name="l00029"></a><span class="lineno"> 29</span><span class="keywordflow">if</span> __name__ == <span class="stringliteral">"__main__"</span>:</div>
|
||||
<div class="line"><a id="l00030" name="l00030"></a><span class="lineno"> 30</span> main()</div>
|
||||
</div><!-- fragment --></div><!-- contents -->
|
||||
</div><!-- doc-content -->
|
||||
<!-- start footer part -->
|
||||
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
|
||||
<ul>
|
||||
<li class="navelem"><a class="el" href="dir_68267d1309a1af8e8297ef4c3efbcdba.html">src</a></li><li class="navelem"><a class="el" href="dir_634e799a3947388232110823971192a8.html">scripts</a></li><li class="navelem"><b>plot_single_particle.py</b></li>
|
||||
<li class="footer">Generated by <a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.9.6 </li>
|
||||
</ul>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
@@ -1,4 +1,4 @@
|
||||
var searchData=
|
||||
[
|
||||
['add_5fparticle_0',['add_particle',['../classPenningTrap.html#a6e9776ff5b149f01080800716455d7c8',1,'PenningTrap']]]
|
||||
['_5f_5fmethod_5fname_5f_5f_0',['__METHOD_NAME__',['../utils_8hpp.html#a60dca3177fb9cb5256609adc7af55168',1,'utils.hpp']]]
|
||||
];
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
var searchData=
|
||||
[
|
||||
['b_5f0_0',['B_0',['../classPenningTrap.html#a0cac3509aa96e71a26d3b2c902e27716',1,'PenningTrap']]],
|
||||
['bug_20list_1',['Bug List',['../bug.html',1,'']]]
|
||||
['add_5fparticle_0',['add_particle',['../classPenningTrap.html#a6e9776ff5b149f01080800716455d7c8',1,'PenningTrap']]],
|
||||
['analytical_5fsolution_5fparticle_5f1_1',['analytical_solution_particle_1',['../main_8cpp.html#a8d92fb2ad085065fbd14718647551657',1,'main.cpp']]],
|
||||
['assert_2',['ASSERT',['../utils_8hpp.html#a73d4f21ad937dbc50a0c0538c78fd4f9',1,'utils.hpp']]]
|
||||
];
|
||||
|
||||
4
docs/search/all_10.js
Normal file
4
docs/search/all_10.js
Normal file
@@ -0,0 +1,4 @@
|
||||
var searchData=
|
||||
[
|
||||
['write_5fsimulation_5fto_5fdir_0',['write_simulation_to_dir',['../classPenningTrap.html#ad8bc4df7ab3eed53b16cfdff38e7760b',1,'PenningTrap']]]
|
||||
];
|
||||
@@ -1,4 +1,5 @@
|
||||
var searchData=
|
||||
[
|
||||
['constants_2ehpp_0',['constants.hpp',['../constants_8hpp.html',1,'']]]
|
||||
['b_5f0_0',['B_0',['../classPenningTrap.html#a0cac3509aa96e71a26d3b2c902e27716',1,'PenningTrap']]],
|
||||
['bug_20list_1',['Bug List',['../bug.html',1,'']]]
|
||||
];
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
var searchData=
|
||||
[
|
||||
['d_0',['d',['../classPenningTrap.html#a66dfe89c68716b9502927b97f59c27d2',1,'PenningTrap']]],
|
||||
['debug_1',['DEBUG',['../utils_8hpp.html#aecc1f7a8a2493b9e021e5bff76a00a5b',1,'utils.hpp']]]
|
||||
['ca_5fcharge_0',['CA_CHARGE',['../constants_8hpp.html#af7602a3a314957137ad1cd719aa23789',1,'constants.hpp']]],
|
||||
['ca_5fmass_1',['CA_MASS',['../constants_8hpp.html#a2ff491cc7958ffd5e749c518a4a60ec8',1,'constants.hpp']]],
|
||||
['close_5fto_2',['close_to',['../utils_8hpp.html#ab3e0cf669bddc59bd53998490ffb68b9',1,'close_to(arma::vec &a, arma::vec &b, double tol=1e-8): utils.cpp'],['../utils_8cpp.html#a6be6f938bcbb235ebb6a2ed9d08411b2',1,'close_to(arma::vec &a, arma::vec &b, double tol): utils.cpp']]],
|
||||
['constants_2ehpp_3',['constants.hpp',['../constants_8hpp.html',1,'']]]
|
||||
];
|
||||
|
||||
@@ -1,7 +1,5 @@
|
||||
var searchData=
|
||||
[
|
||||
['evolve_5fforward_5feuler_0',['evolve_forward_euler',['../classPenningTrap.html#a56544b6f4befb42984e9650cf2a40965',1,'PenningTrap']]],
|
||||
['evolve_5frk4_1',['evolve_RK4',['../classPenningTrap.html#ab891b839c40eeb38d8a2a636c70090a9',1,'PenningTrap']]],
|
||||
['external_5fb_5ffield_2',['external_B_field',['../classPenningTrap.html#a2a3e7f480ba52e9f24d4c50c3981a784',1,'PenningTrap']]],
|
||||
['external_5fe_5ffield_3',['external_E_field',['../classPenningTrap.html#a978a2e2026a4b5308d5184712f81704b',1,'PenningTrap']]]
|
||||
['d_0',['d',['../classPenningTrap.html#a66dfe89c68716b9502927b97f59c27d2',1,'PenningTrap']]],
|
||||
['debug_1',['DEBUG',['../utils_8hpp.html#aecc1f7a8a2493b9e021e5bff76a00a5b',1,'utils.hpp']]]
|
||||
];
|
||||
|
||||
@@ -1,4 +1,7 @@
|
||||
var searchData=
|
||||
[
|
||||
['force_5fon_5fparticle_0',['force_on_particle',['../classPenningTrap.html#a4790f41e4fbc6ede4991aa7bbda92182',1,'PenningTrap']]]
|
||||
['evolve_5fforward_5feuler_0',['evolve_forward_euler',['../classPenningTrap.html#ab9ea97a406534bbe621a95215144875e',1,'PenningTrap']]],
|
||||
['evolve_5frk4_1',['evolve_RK4',['../classPenningTrap.html#a36946152fd951b1f7c346c51ff900d8e',1,'PenningTrap']]],
|
||||
['external_5fb_5ffield_2',['external_B_field',['../classPenningTrap.html#a361f2c4862c90b5e8e2a2f50c6a95655',1,'PenningTrap']]],
|
||||
['external_5fe_5ffield_3',['external_E_field',['../classPenningTrap.html#a5846c8f75cdc543fd9cf0b2185a3ef22',1,'PenningTrap']]]
|
||||
];
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
var searchData=
|
||||
[
|
||||
['k_5fe_0',['K_E',['../constants_8hpp.html#a4e451456ad7e9276ed0afa42826e7ccb',1,'constants.hpp']]]
|
||||
['force_5fon_5fparticle_0',['force_on_particle',['../classPenningTrap.html#a7f210bb2768a5d79ced4b0df0df97598',1,'PenningTrap']]],
|
||||
['fraction_5fof_5fparticles_5fleft_1',['fraction_of_particles_left',['../classPenningTrap.html#ac529aa26c288f34eae184a67e6bac41f',1,'PenningTrap']]]
|
||||
];
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
var searchData=
|
||||
[
|
||||
['m_0',['m',['../classParticle.html#aedcc7e1bc53b0e2b1a4a07c9a1b47563',1,'Particle']]],
|
||||
['main_2ecpp_1',['main.cpp',['../main_8cpp.html',1,'']]]
|
||||
['k_5fe_0',['K_E',['../constants_8hpp.html#a4e451456ad7e9276ed0afa42826e7ccb',1,'constants.hpp']]],
|
||||
['k_5fr_1',['k_r',['../classPenningTrap.html#a2f168622587709b9e3c49077f0b9a640',1,'PenningTrap']]],
|
||||
['k_5fv_2',['k_v',['../classPenningTrap.html#ae9b5afdaa5cd366e94bd294452a1eed4',1,'PenningTrap']]]
|
||||
];
|
||||
|
||||
@@ -1,11 +1,7 @@
|
||||
var searchData=
|
||||
[
|
||||
['particle_0',['Particle',['../classParticle.html',1,'Particle'],['../classParticle.html#a00e108823877a25513ccae7cac011b4c',1,'Particle::Particle()']]],
|
||||
['particle_2ecpp_1',['Particle.cpp',['../Particle_8cpp.html',1,'']]],
|
||||
['particle_2ehpp_2',['Particle.hpp',['../Particle_8hpp.html',1,'']]],
|
||||
['particles_3',['particles',['../classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f',1,'PenningTrap']]],
|
||||
['penning_20trap_20simulation_4',['Penning trap simulation',['../index.html',1,'']]],
|
||||
['penningtrap_5',['PenningTrap',['../classPenningTrap.html',1,'PenningTrap'],['../classParticle.html#aa797d319549dc2a0beb06cdbfd430232',1,'Particle::PenningTrap()'],['../classPenningTrap.html#a81add5063bd5f29d77f0b5c299c6c560',1,'PenningTrap::PenningTrap()']]],
|
||||
['penningtrap_2ecpp_6',['PenningTrap.cpp',['../PenningTrap_8cpp.html',1,'']]],
|
||||
['penningtrap_2ehpp_7',['PenningTrap.hpp',['../PenningTrap_8hpp.html',1,'']]]
|
||||
['m_0',['m',['../classParticle.html#aedcc7e1bc53b0e2b1a4a07c9a1b47563',1,'Particle']]],
|
||||
['m_5fassert_1',['m_assert',['../utils_8hpp.html#a2cc3a2cdb635bac3c8b02e89d4d6af38',1,'m_assert(bool expr, std::string expr_str, std::string func, std::string file, int line, std::string msg): utils.cpp'],['../utils_8cpp.html#aff5e07c3c1d321709b0cc38e999f427b',1,'m_assert(bool expr, std::string expr_str, std::string f, std::string file, int line, std::string msg): utils.cpp']]],
|
||||
['main_2ecpp_2',['main.cpp',['../main_8cpp.html',1,'']]],
|
||||
['mkpath_3',['mkpath',['../utils_8hpp.html#a6fdd7217b750aff5b6295ece7cbdeffa',1,'mkpath(std::string path, int mode=0777): utils.cpp'],['../utils_8cpp.html#acf13f4e492199cb7231bfa646dbd08de',1,'mkpath(std::string path, int mode): utils.cpp']]]
|
||||
];
|
||||
|
||||
@@ -1,4 +1,18 @@
|
||||
var searchData=
|
||||
[
|
||||
['q_0',['q',['../classParticle.html#a566dcc1de4bdc01251776948798ea8e1',1,'Particle']]]
|
||||
['p1_0',['p1',['../main_8cpp.html#a2efa69bb9d93049429ce4637075f1d30',1,'main.cpp']]],
|
||||
['p2_1',['p2',['../main_8cpp.html#ac70b61df65f4336f57ea9b4c35250df7',1,'main.cpp']]],
|
||||
['particle_2',['Particle',['../classParticle.html#af1d7535fb8311eaa77d2b7b345882ec4',1,'Particle::Particle()'],['../classParticle.html',1,'Particle']]],
|
||||
['particle_2ecpp_3',['Particle.cpp',['../Particle_8cpp.html',1,'']]],
|
||||
['particle_2ehpp_4',['Particle.hpp',['../Particle_8hpp.html',1,'']]],
|
||||
['particles_5',['particles',['../classPenningTrap.html#a0112525d9e79a472e761f8ef402a339f',1,'PenningTrap']]],
|
||||
['penning_20trap_20simulation_6',['Penning trap simulation',['../index.html',1,'']]],
|
||||
['penningtrap_7',['PenningTrap',['../classPenningTrap.html#a5b6c6d4636f3a6e279ccde59d4a345e8',1,'PenningTrap::PenningTrap(double B_0=T, double V_0=(25. *V)/1000., double d=500., double t=0.)'],['../classPenningTrap.html#addc96789dcfec07b75156e19fee82f4f',1,'PenningTrap::PenningTrap(std::vector< Particle > particles, double B_0=T, double V_0=(25. *V)/1000., double d=500., double t=0.)'],['../classPenningTrap.html#a830be1b8cbf59664e060b6edbeaa302f',1,'PenningTrap::PenningTrap(uint i, double B_0=T, double V_0=(25. *V)/1000., double d=500., double t=0.)'],['../classParticle.html#aa797d319549dc2a0beb06cdbfd430232',1,'Particle::PenningTrap()'],['../classPenningTrap.html',1,'PenningTrap']]],
|
||||
['penningtrap_2ecpp_8',['PenningTrap.cpp',['../PenningTrap_8cpp.html',1,'']]],
|
||||
['penningtrap_2ehpp_9',['PenningTrap.hpp',['../PenningTrap_8hpp.html',1,'']]],
|
||||
['penningtraptest_10',['PenningTrapTest',['../classPenningTrap.html#a869f032f37d0569ed16f224b4c4356ae',1,'PenningTrap::PenningTrapTest()'],['../classPenningTrapTest.html',1,'PenningTrapTest']]],
|
||||
['perturbation_11',['perturbation',['../classPenningTrap.html#ae915f6ad0eef1fb46530e836b6e071e5',1,'PenningTrap']]],
|
||||
['potential_5fresonance_5fnarrow_5fsweep_12',['potential_resonance_narrow_sweep',['../main_8cpp.html#a33d9b1c76c3c80902f89a58b1a6d96ea',1,'main.cpp']]],
|
||||
['potential_5fresonance_5fnarrow_5fsweep_5finteraction_13',['potential_resonance_narrow_sweep_interaction',['../main_8cpp.html#ac1816f70ec612edc27848ef7f0875fdb',1,'main.cpp']]],
|
||||
['potential_5fresonance_5fwide_5fsweep_14',['potential_resonance_wide_sweep',['../main_8cpp.html#a6b38b477c18e2f4268779751a88edab1',1,'main.cpp']]]
|
||||
];
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
var searchData=
|
||||
[
|
||||
['r_5fvec_0',['r_vec',['../classParticle.html#acf1a0f3c978b06d76df5bb4279594467',1,'Particle']]]
|
||||
['q_0',['q',['../classParticle.html#a566dcc1de4bdc01251776948798ea8e1',1,'Particle']]]
|
||||
];
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
var searchData=
|
||||
[
|
||||
['scientific_5fformat_0',['scientific_format',['../utils_8hpp.html#adfb618b2fdff47ef30a4a2b62c04f384',1,'scientific_format(double d, int width=20, int prec=10): utils.cpp'],['../utils_8hpp.html#ad54b96a1074f9df4dc892a41d115b72d',1,'scientific_format(const std::vector< double > &v, int width=20, int prec=10): utils.cpp'],['../utils_8cpp.html#acd2a9c7a7d5a7fe9163be8c4cc110746',1,'scientific_format(double d, int width, int prec): utils.cpp'],['../utils_8cpp.html#a58565270b643b24e3132f38c653e0199',1,'scientific_format(const std::vector< double > &v, int width, int prec): utils.cpp']]]
|
||||
['r_5ffunc_0',['r_func',['../classPenningTrap.html#a826b7fa8e709d481eb1dee7d0c2cdc08',1,'PenningTrap']]],
|
||||
['r_5fvec_1',['r_vec',['../classParticle.html#a1c59101411db43624828b766f87ad460',1,'Particle']]],
|
||||
['reinitialize_2',['reinitialize',['../classPenningTrap.html#aaee129f177657455348d0c8ae1441dea',1,'PenningTrap']]]
|
||||
];
|
||||
|
||||
@@ -1,9 +1,15 @@
|
||||
var searchData=
|
||||
[
|
||||
['t_0',['T',['../constants_8hpp.html#a0acb682b8260ab1c60b918599864e2e5',1,'constants.hpp']]],
|
||||
['test_5fsuite_2ecpp_1',['test_suite.cpp',['../test__suite_8cpp.html',1,'']]],
|
||||
['todo_20list_2',['Todo List',['../todo.html',1,'']]],
|
||||
['total_5fforce_3',['total_force',['../classPenningTrap.html#a83cc7a04dae009ed8e75453c38fdf8be',1,'PenningTrap']]],
|
||||
['total_5fforce_5fexternal_4',['total_force_external',['../classPenningTrap.html#a045adb85e97a8e0c38fb36d2fd74eeee',1,'PenningTrap']]],
|
||||
['total_5fforce_5fparticles_5',['total_force_particles',['../classPenningTrap.html#a135db7d991d9b88b00fde4edee71f78d',1,'PenningTrap']]]
|
||||
['scientific_5fformat_0',['scientific_format',['../utils_8hpp.html#adfb618b2fdff47ef30a4a2b62c04f384',1,'scientific_format(double d, int width=20, int prec=10): utils.cpp'],['../utils_8hpp.html#ad54b96a1074f9df4dc892a41d115b72d',1,'scientific_format(const std::vector< double > &v, int width=20, int prec=10): utils.cpp'],['../utils_8cpp.html#acd2a9c7a7d5a7fe9163be8c4cc110746',1,'scientific_format(double d, int width, int prec): utils.cpp'],['../utils_8cpp.html#a58565270b643b24e3132f38c653e0199',1,'scientific_format(const std::vector< double > &v, int width, int prec): utils.cpp']]],
|
||||
['set_5fpertubation_1',['set_pertubation',['../classPenningTrap.html#a9d1d8e90ca839b928aee1ad0cd4aff43',1,'PenningTrap']]],
|
||||
['sim_5farr_2',['sim_arr',['../typedefs_8hpp.html#aec69d34220fff45de238b9e01f2686af',1,'typedefs.hpp']]],
|
||||
['sim_5fcols_3',['sim_cols',['../typedefs_8hpp.html#a46482a2697556c00556c9d73f461784f',1,'typedefs.hpp']]],
|
||||
['sim_5frows_4',['sim_rows',['../typedefs_8hpp.html#a33418f31f28663b8414c8f7182998c22',1,'typedefs.hpp']]],
|
||||
['simulate_5',['simulate',['../classPenningTrap.html#a7a1d9f0528a12308de25bc30718da20a',1,'PenningTrap']]],
|
||||
['simulate_5f100_5fparticles_6',['simulate_100_particles',['../main_8cpp.html#a213713d6ecc02a32b588ffd179dc7513',1,'main.cpp']]],
|
||||
['simulate_5fsingle_5fparticle_7',['simulate_single_particle',['../main_8cpp.html#a8fdbe2d5a872e50ef5ec1263243589d6',1,'main.cpp']]],
|
||||
['simulate_5fsingle_5fparticle_5fwith_5fdifferent_5fsteps_8',['simulate_single_particle_with_different_steps',['../main_8cpp.html#ac67e0d59227856c4d42e7d01c75e0ad2',1,'main.cpp']]],
|
||||
['simulate_5ftwo_5fparticles_9',['simulate_two_particles',['../main_8cpp.html#a783789519f97c6430081171cacb0ffb1',1,'main.cpp']]],
|
||||
['simulation_10',['simulation',['../structsimulation.html',1,'']]],
|
||||
['simulation_5ft_11',['simulation_t',['../typedefs_8hpp.html#a784799c37b5e4fb8bf4f6368e004dec6',1,'typedefs.hpp']]]
|
||||
];
|
||||
|
||||
@@ -1,5 +1,15 @@
|
||||
var searchData=
|
||||
[
|
||||
['utils_2ecpp_0',['utils.cpp',['../utils_8cpp.html',1,'']]],
|
||||
['utils_2ehpp_1',['utils.hpp',['../utils_8hpp.html',1,'']]]
|
||||
['t_0',['t',['../classPenningTrap.html#a8ca4e21291f60fde619c14099d8c4e8e',1,'PenningTrap']]],
|
||||
['t_1',['T',['../constants_8hpp.html#a0acb682b8260ab1c60b918599864e2e5',1,'constants.hpp']]],
|
||||
['test_5fexternal_5fb_5ffield_2',['test_external_B_field',['../classPenningTrapTest.html#ad668d7d875bdc1909a42426bf9dead9e',1,'PenningTrapTest']]],
|
||||
['test_5fexternal_5fe_5ffield_3',['test_external_E_field',['../classPenningTrapTest.html#a6a303be62039ca2ecccd8252744d4dc8',1,'PenningTrapTest']]],
|
||||
['test_5fforce_5fon_5fparticle_4',['test_force_on_particle',['../classPenningTrapTest.html#a5f4f0b150e54ce463bb29f76d49883f9',1,'PenningTrapTest']]],
|
||||
['test_5fsuite_2ecpp_5',['test_suite.cpp',['../test__suite_8cpp.html',1,'']]],
|
||||
['test_5ftotal_5fforce_5fexternal_6',['test_total_force_external',['../classPenningTrapTest.html#ae6d0c8e0d80338fb7c7edefc97331046',1,'PenningTrapTest']]],
|
||||
['test_5ftotal_5fforce_5fparticles_7',['test_total_force_particles',['../classPenningTrapTest.html#a68449d508e66205bc8b27fa5f60db508',1,'PenningTrapTest']]],
|
||||
['total_5fforce_8',['total_force',['../classPenningTrap.html#a9a301b0540078c36697880ef204afdf3',1,'PenningTrap']]],
|
||||
['total_5fforce_5fexternal_9',['total_force_external',['../classPenningTrap.html#a2c01108b52c8e2a003cf9170da9e7682',1,'PenningTrap']]],
|
||||
['total_5fforce_5fparticles_10',['total_force_particles',['../classPenningTrap.html#a2fe1cefbae18fa5808155ee0d2df713c',1,'PenningTrap']]],
|
||||
['typedefs_2ehpp_11',['typedefs.hpp',['../typedefs_8hpp.html',1,'']]]
|
||||
];
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
var searchData=
|
||||
[
|
||||
['v_0',['V',['../constants_8hpp.html#af40a326b23c68a27cebe60f16634a2cb',1,'constants.hpp']]],
|
||||
['v_5f0_1',['V_0',['../classPenningTrap.html#a715329844d75ec4c04f8391421fb4e89',1,'PenningTrap']]],
|
||||
['v_5fvec_2',['v_vec',['../classParticle.html#a4a5d22c7aeca66f67d083f270cba25df',1,'Particle']]]
|
||||
['utils_2ecpp_0',['utils.cpp',['../utils_8cpp.html',1,'']]],
|
||||
['utils_2ehpp_1',['utils.hpp',['../utils_8hpp.html',1,'']]]
|
||||
];
|
||||
|
||||
8
docs/search/all_f.js
Normal file
8
docs/search/all_f.js
Normal file
@@ -0,0 +1,8 @@
|
||||
var searchData=
|
||||
[
|
||||
['v_0',['V',['../constants_8hpp.html#af40a326b23c68a27cebe60f16634a2cb',1,'constants.hpp']]],
|
||||
['v_5f0_1',['V_0',['../classPenningTrap.html#a715329844d75ec4c04f8391421fb4e89',1,'PenningTrap']]],
|
||||
['v_5ffunc_2',['v_func',['../classPenningTrap.html#a3c0a44e4e0a94366ff609e81fe463fa2',1,'PenningTrap']]],
|
||||
['v_5fvec_3',['v_vec',['../classParticle.html#a3a10400add8dd22b8031330c2aafb6fe',1,'Particle']]],
|
||||
['vec3_4',['vec3',['../typedefs_8hpp.html#a3bdfb73a02f88ae32b6128ef747c4aea',1,'typedefs.hpp']]]
|
||||
];
|
||||
@@ -1,5 +1,6 @@
|
||||
var searchData=
|
||||
[
|
||||
['particle_0',['Particle',['../classParticle.html',1,'']]],
|
||||
['penningtrap_1',['PenningTrap',['../classPenningTrap.html',1,'']]]
|
||||
['penningtrap_1',['PenningTrap',['../classPenningTrap.html',1,'']]],
|
||||
['penningtraptest_2',['PenningTrapTest',['../classPenningTrapTest.html',1,'']]]
|
||||
];
|
||||
|
||||
4
docs/search/classes_1.js
Normal file
4
docs/search/classes_1.js
Normal file
@@ -0,0 +1,4 @@
|
||||
var searchData=
|
||||
[
|
||||
['simulation_0',['simulation',['../structsimulation.html',1,'']]]
|
||||
];
|
||||
@@ -1,4 +1,4 @@
|
||||
var searchData=
|
||||
[
|
||||
['debug_0',['DEBUG',['../utils_8hpp.html#aecc1f7a8a2493b9e021e5bff76a00a5b',1,'utils.hpp']]]
|
||||
['_5f_5fmethod_5fname_5f_5f_0',['__METHOD_NAME__',['../utils_8hpp.html#a60dca3177fb9cb5256609adc7af55168',1,'utils.hpp']]]
|
||||
];
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
var searchData=
|
||||
[
|
||||
['k_5fe_0',['K_E',['../constants_8hpp.html#a4e451456ad7e9276ed0afa42826e7ccb',1,'constants.hpp']]]
|
||||
['assert_0',['ASSERT',['../utils_8hpp.html#a73d4f21ad937dbc50a0c0538c78fd4f9',1,'utils.hpp']]]
|
||||
];
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
var searchData=
|
||||
[
|
||||
['t_0',['T',['../constants_8hpp.html#a0acb682b8260ab1c60b918599864e2e5',1,'constants.hpp']]]
|
||||
['ca_5fcharge_0',['CA_CHARGE',['../constants_8hpp.html#af7602a3a314957137ad1cd719aa23789',1,'constants.hpp']]],
|
||||
['ca_5fmass_1',['CA_MASS',['../constants_8hpp.html#a2ff491cc7958ffd5e749c518a4a60ec8',1,'constants.hpp']]]
|
||||
];
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
var searchData=
|
||||
[
|
||||
['v_0',['V',['../constants_8hpp.html#af40a326b23c68a27cebe60f16634a2cb',1,'constants.hpp']]]
|
||||
['debug_0',['DEBUG',['../utils_8hpp.html#aecc1f7a8a2493b9e021e5bff76a00a5b',1,'utils.hpp']]]
|
||||
];
|
||||
|
||||
4
docs/search/defines_4.js
Normal file
4
docs/search/defines_4.js
Normal file
@@ -0,0 +1,4 @@
|
||||
var searchData=
|
||||
[
|
||||
['k_5fe_0',['K_E',['../constants_8hpp.html#a4e451456ad7e9276ed0afa42826e7ccb',1,'constants.hpp']]]
|
||||
];
|
||||
4
docs/search/defines_5.js
Normal file
4
docs/search/defines_5.js
Normal file
@@ -0,0 +1,4 @@
|
||||
var searchData=
|
||||
[
|
||||
['t_0',['T',['../constants_8hpp.html#a0acb682b8260ab1c60b918599864e2e5',1,'constants.hpp']]]
|
||||
];
|
||||
4
docs/search/defines_6.js
Normal file
4
docs/search/defines_6.js
Normal file
@@ -0,0 +1,4 @@
|
||||
var searchData=
|
||||
[
|
||||
['v_0',['V',['../constants_8hpp.html#af40a326b23c68a27cebe60f16634a2cb',1,'constants.hpp']]]
|
||||
];
|
||||
@@ -1,4 +1,5 @@
|
||||
var searchData=
|
||||
[
|
||||
['test_5fsuite_2ecpp_0',['test_suite.cpp',['../test__suite_8cpp.html',1,'']]]
|
||||
['test_5fsuite_2ecpp_0',['test_suite.cpp',['../test__suite_8cpp.html',1,'']]],
|
||||
['typedefs_2ehpp_1',['typedefs.hpp',['../typedefs_8hpp.html',1,'']]]
|
||||
];
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
var searchData=
|
||||
[
|
||||
['add_5fparticle_0',['add_particle',['../classPenningTrap.html#a6e9776ff5b149f01080800716455d7c8',1,'PenningTrap']]]
|
||||
['add_5fparticle_0',['add_particle',['../classPenningTrap.html#a6e9776ff5b149f01080800716455d7c8',1,'PenningTrap']]],
|
||||
['analytical_5fsolution_5fparticle_5f1_1',['analytical_solution_particle_1',['../main_8cpp.html#a8d92fb2ad085065fbd14718647551657',1,'main.cpp']]]
|
||||
];
|
||||
|
||||
@@ -1,7 +1,4 @@
|
||||
var searchData=
|
||||
[
|
||||
['evolve_5fforward_5feuler_0',['evolve_forward_euler',['../classPenningTrap.html#a56544b6f4befb42984e9650cf2a40965',1,'PenningTrap']]],
|
||||
['evolve_5frk4_1',['evolve_RK4',['../classPenningTrap.html#ab891b839c40eeb38d8a2a636c70090a9',1,'PenningTrap']]],
|
||||
['external_5fb_5ffield_2',['external_B_field',['../classPenningTrap.html#a2a3e7f480ba52e9f24d4c50c3981a784',1,'PenningTrap']]],
|
||||
['external_5fe_5ffield_3',['external_E_field',['../classPenningTrap.html#a978a2e2026a4b5308d5184712f81704b',1,'PenningTrap']]]
|
||||
['close_5fto_0',['close_to',['../utils_8hpp.html#ab3e0cf669bddc59bd53998490ffb68b9',1,'close_to(arma::vec &a, arma::vec &b, double tol=1e-8): utils.cpp'],['../utils_8cpp.html#a6be6f938bcbb235ebb6a2ed9d08411b2',1,'close_to(arma::vec &a, arma::vec &b, double tol): utils.cpp']]]
|
||||
];
|
||||
|
||||
@@ -1,4 +1,7 @@
|
||||
var searchData=
|
||||
[
|
||||
['force_5fon_5fparticle_0',['force_on_particle',['../classPenningTrap.html#a4790f41e4fbc6ede4991aa7bbda92182',1,'PenningTrap']]]
|
||||
['evolve_5fforward_5feuler_0',['evolve_forward_euler',['../classPenningTrap.html#ab9ea97a406534bbe621a95215144875e',1,'PenningTrap']]],
|
||||
['evolve_5frk4_1',['evolve_RK4',['../classPenningTrap.html#a36946152fd951b1f7c346c51ff900d8e',1,'PenningTrap']]],
|
||||
['external_5fb_5ffield_2',['external_B_field',['../classPenningTrap.html#a361f2c4862c90b5e8e2a2f50c6a95655',1,'PenningTrap']]],
|
||||
['external_5fe_5ffield_3',['external_E_field',['../classPenningTrap.html#a5846c8f75cdc543fd9cf0b2185a3ef22',1,'PenningTrap']]]
|
||||
];
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
var searchData=
|
||||
[
|
||||
['particle_0',['Particle',['../classParticle.html#a00e108823877a25513ccae7cac011b4c',1,'Particle']]],
|
||||
['penningtrap_1',['PenningTrap',['../classPenningTrap.html#a81add5063bd5f29d77f0b5c299c6c560',1,'PenningTrap']]]
|
||||
['force_5fon_5fparticle_0',['force_on_particle',['../classPenningTrap.html#a7f210bb2768a5d79ced4b0df0df97598',1,'PenningTrap']]],
|
||||
['fraction_5fof_5fparticles_5fleft_1',['fraction_of_particles_left',['../classPenningTrap.html#ac529aa26c288f34eae184a67e6bac41f',1,'PenningTrap']]]
|
||||
];
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
var searchData=
|
||||
[
|
||||
['scientific_5fformat_0',['scientific_format',['../utils_8hpp.html#adfb618b2fdff47ef30a4a2b62c04f384',1,'scientific_format(double d, int width=20, int prec=10): utils.cpp'],['../utils_8hpp.html#ad54b96a1074f9df4dc892a41d115b72d',1,'scientific_format(const std::vector< double > &v, int width=20, int prec=10): utils.cpp'],['../utils_8cpp.html#acd2a9c7a7d5a7fe9163be8c4cc110746',1,'scientific_format(double d, int width, int prec): utils.cpp'],['../utils_8cpp.html#a58565270b643b24e3132f38c653e0199',1,'scientific_format(const std::vector< double > &v, int width, int prec): utils.cpp']]]
|
||||
['m_5fassert_0',['m_assert',['../utils_8hpp.html#a2cc3a2cdb635bac3c8b02e89d4d6af38',1,'m_assert(bool expr, std::string expr_str, std::string func, std::string file, int line, std::string msg): utils.cpp'],['../utils_8cpp.html#aff5e07c3c1d321709b0cc38e999f427b',1,'m_assert(bool expr, std::string expr_str, std::string f, std::string file, int line, std::string msg): utils.cpp']]],
|
||||
['mkpath_1',['mkpath',['../utils_8hpp.html#a6fdd7217b750aff5b6295ece7cbdeffa',1,'mkpath(std::string path, int mode=0777): utils.cpp'],['../utils_8cpp.html#acf13f4e492199cb7231bfa646dbd08de',1,'mkpath(std::string path, int mode): utils.cpp']]]
|
||||
];
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
var searchData=
|
||||
[
|
||||
['total_5fforce_0',['total_force',['../classPenningTrap.html#a83cc7a04dae009ed8e75453c38fdf8be',1,'PenningTrap']]],
|
||||
['total_5fforce_5fexternal_1',['total_force_external',['../classPenningTrap.html#a045adb85e97a8e0c38fb36d2fd74eeee',1,'PenningTrap']]],
|
||||
['total_5fforce_5fparticles_2',['total_force_particles',['../classPenningTrap.html#a135db7d991d9b88b00fde4edee71f78d',1,'PenningTrap']]]
|
||||
['particle_0',['Particle',['../classParticle.html#af1d7535fb8311eaa77d2b7b345882ec4',1,'Particle']]],
|
||||
['penningtrap_1',['PenningTrap',['../classPenningTrap.html#a5b6c6d4636f3a6e279ccde59d4a345e8',1,'PenningTrap::PenningTrap(double B_0=T, double V_0=(25. *V)/1000., double d=500., double t=0.)'],['../classPenningTrap.html#a830be1b8cbf59664e060b6edbeaa302f',1,'PenningTrap::PenningTrap(uint i, double B_0=T, double V_0=(25. *V)/1000., double d=500., double t=0.)'],['../classPenningTrap.html#addc96789dcfec07b75156e19fee82f4f',1,'PenningTrap::PenningTrap(std::vector< Particle > particles, double B_0=T, double V_0=(25. *V)/1000., double d=500., double t=0.)']]],
|
||||
['potential_5fresonance_5fnarrow_5fsweep_2',['potential_resonance_narrow_sweep',['../main_8cpp.html#a33d9b1c76c3c80902f89a58b1a6d96ea',1,'main.cpp']]],
|
||||
['potential_5fresonance_5fnarrow_5fsweep_5finteraction_3',['potential_resonance_narrow_sweep_interaction',['../main_8cpp.html#ac1816f70ec612edc27848ef7f0875fdb',1,'main.cpp']]],
|
||||
['potential_5fresonance_5fwide_5fsweep_4',['potential_resonance_wide_sweep',['../main_8cpp.html#a6b38b477c18e2f4268779751a88edab1',1,'main.cpp']]]
|
||||
];
|
||||
|
||||
5
docs/search/functions_6.js
Normal file
5
docs/search/functions_6.js
Normal file
@@ -0,0 +1,5 @@
|
||||
var searchData=
|
||||
[
|
||||
['r_5ffunc_0',['r_func',['../classPenningTrap.html#a826b7fa8e709d481eb1dee7d0c2cdc08',1,'PenningTrap']]],
|
||||
['reinitialize_1',['reinitialize',['../classPenningTrap.html#aaee129f177657455348d0c8ae1441dea',1,'PenningTrap']]]
|
||||
];
|
||||
10
docs/search/functions_7.js
Normal file
10
docs/search/functions_7.js
Normal file
@@ -0,0 +1,10 @@
|
||||
var searchData=
|
||||
[
|
||||
['scientific_5fformat_0',['scientific_format',['../utils_8hpp.html#adfb618b2fdff47ef30a4a2b62c04f384',1,'scientific_format(double d, int width=20, int prec=10): utils.cpp'],['../utils_8hpp.html#ad54b96a1074f9df4dc892a41d115b72d',1,'scientific_format(const std::vector< double > &v, int width=20, int prec=10): utils.cpp'],['../utils_8cpp.html#acd2a9c7a7d5a7fe9163be8c4cc110746',1,'scientific_format(double d, int width, int prec): utils.cpp'],['../utils_8cpp.html#a58565270b643b24e3132f38c653e0199',1,'scientific_format(const std::vector< double > &v, int width, int prec): utils.cpp']]],
|
||||
['set_5fpertubation_1',['set_pertubation',['../classPenningTrap.html#a9d1d8e90ca839b928aee1ad0cd4aff43',1,'PenningTrap']]],
|
||||
['simulate_2',['simulate',['../classPenningTrap.html#a7a1d9f0528a12308de25bc30718da20a',1,'PenningTrap']]],
|
||||
['simulate_5f100_5fparticles_3',['simulate_100_particles',['../main_8cpp.html#a213713d6ecc02a32b588ffd179dc7513',1,'main.cpp']]],
|
||||
['simulate_5fsingle_5fparticle_4',['simulate_single_particle',['../main_8cpp.html#a8fdbe2d5a872e50ef5ec1263243589d6',1,'main.cpp']]],
|
||||
['simulate_5fsingle_5fparticle_5fwith_5fdifferent_5fsteps_5',['simulate_single_particle_with_different_steps',['../main_8cpp.html#ac67e0d59227856c4d42e7d01c75e0ad2',1,'main.cpp']]],
|
||||
['simulate_5ftwo_5fparticles_6',['simulate_two_particles',['../main_8cpp.html#a783789519f97c6430081171cacb0ffb1',1,'main.cpp']]]
|
||||
];
|
||||
11
docs/search/functions_8.js
Normal file
11
docs/search/functions_8.js
Normal file
@@ -0,0 +1,11 @@
|
||||
var searchData=
|
||||
[
|
||||
['test_5fexternal_5fb_5ffield_0',['test_external_B_field',['../classPenningTrapTest.html#ad668d7d875bdc1909a42426bf9dead9e',1,'PenningTrapTest']]],
|
||||
['test_5fexternal_5fe_5ffield_1',['test_external_E_field',['../classPenningTrapTest.html#a6a303be62039ca2ecccd8252744d4dc8',1,'PenningTrapTest']]],
|
||||
['test_5fforce_5fon_5fparticle_2',['test_force_on_particle',['../classPenningTrapTest.html#a5f4f0b150e54ce463bb29f76d49883f9',1,'PenningTrapTest']]],
|
||||
['test_5ftotal_5fforce_5fexternal_3',['test_total_force_external',['../classPenningTrapTest.html#ae6d0c8e0d80338fb7c7edefc97331046',1,'PenningTrapTest']]],
|
||||
['test_5ftotal_5fforce_5fparticles_4',['test_total_force_particles',['../classPenningTrapTest.html#a68449d508e66205bc8b27fa5f60db508',1,'PenningTrapTest']]],
|
||||
['total_5fforce_5',['total_force',['../classPenningTrap.html#a9a301b0540078c36697880ef204afdf3',1,'PenningTrap']]],
|
||||
['total_5fforce_5fexternal_6',['total_force_external',['../classPenningTrap.html#a2c01108b52c8e2a003cf9170da9e7682',1,'PenningTrap']]],
|
||||
['total_5fforce_5fparticles_7',['total_force_particles',['../classPenningTrap.html#a2fe1cefbae18fa5808155ee0d2df713c',1,'PenningTrap']]]
|
||||
];
|
||||
4
docs/search/functions_9.js
Normal file
4
docs/search/functions_9.js
Normal file
@@ -0,0 +1,4 @@
|
||||
var searchData=
|
||||
[
|
||||
['v_5ffunc_0',['v_func',['../classPenningTrap.html#a3c0a44e4e0a94366ff609e81fe463fa2',1,'PenningTrap']]]
|
||||
];
|
||||
4
docs/search/functions_a.js
Normal file
4
docs/search/functions_a.js
Normal file
@@ -0,0 +1,4 @@
|
||||
var searchData=
|
||||
[
|
||||
['write_5fsimulation_5fto_5fdir_0',['write_simulation_to_dir',['../classPenningTrap.html#ad8bc4df7ab3eed53b16cfdff38e7760b',1,'PenningTrap']]]
|
||||
];
|
||||
@@ -1,4 +1,5 @@
|
||||
var searchData=
|
||||
[
|
||||
['penningtrap_0',['PenningTrap',['../classParticle.html#aa797d319549dc2a0beb06cdbfd430232',1,'Particle']]]
|
||||
['penningtrap_0',['PenningTrap',['../classParticle.html#aa797d319549dc2a0beb06cdbfd430232',1,'Particle']]],
|
||||
['penningtraptest_1',['PenningTrapTest',['../classPenningTrap.html#a869f032f37d0569ed16f224b4c4356ae',1,'PenningTrap']]]
|
||||
];
|
||||
|
||||
@@ -1,13 +1,14 @@
|
||||
var indexSectionsWithContent =
|
||||
{
|
||||
0: "abcdefkmpqrstuv",
|
||||
1: "p",
|
||||
0: "_abcdefkmpqrstuvw",
|
||||
1: "ps",
|
||||
2: "cmptu",
|
||||
3: "aefpst",
|
||||
4: "bdmpqrv",
|
||||
5: "p",
|
||||
6: "dktv",
|
||||
7: "bpt"
|
||||
3: "acefmprstvw",
|
||||
4: "bdkmpqrtv",
|
||||
5: "sv",
|
||||
6: "p",
|
||||
7: "_acdktv",
|
||||
8: "bp"
|
||||
};
|
||||
|
||||
var indexSectionNames =
|
||||
@@ -17,9 +18,10 @@ var indexSectionNames =
|
||||
2: "files",
|
||||
3: "functions",
|
||||
4: "variables",
|
||||
5: "related",
|
||||
6: "defines",
|
||||
7: "pages"
|
||||
5: "typedefs",
|
||||
6: "related",
|
||||
7: "defines",
|
||||
8: "pages"
|
||||
};
|
||||
|
||||
var indexSectionLabels =
|
||||
@@ -29,8 +31,9 @@ var indexSectionLabels =
|
||||
2: "Files",
|
||||
3: "Functions",
|
||||
4: "Variables",
|
||||
5: "Friends",
|
||||
6: "Macros",
|
||||
7: "Pages"
|
||||
5: "Typedefs",
|
||||
6: "Friends",
|
||||
7: "Macros",
|
||||
8: "Pages"
|
||||
};
|
||||
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user