-
Notifications
You must be signed in to change notification settings - Fork 225
Start simulation with neutral atoms #768
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -36,9 +36,23 @@ namespace SI | |
|
|
||
| /* ionization energy for ground state hydrogen: 13.6 eV --> converted to Joule */ | ||
| /* Joule = kg * m^2 / s^2 */ | ||
| const double IONIZATION_ENERGY = 2.179e-18; | ||
| /* ionization field strength (E-field) for -""-: in Volt / meter */ | ||
| const double IONIZATION_EFIELD = 5.14e11; | ||
| PMACC_CONST_VECTOR(float_X,1,IONIZATION_ENERGY, | ||
| 2.179e-18 | ||
| ); | ||
| /* ionization field strength (E-field) for hydrogen: in Volt / meter | ||
| * | ||
| * usage: | ||
| * PMACC_CONST_VECTOR(float_X,<NUMBER_OF_PROTONS>,IONIZATION_EFIELD, | ||
| * <value_1>, | ||
| * ... | ||
| * <value_Z> | ||
| * ); | ||
| * | ||
| * Do not forget to change the weight of the ion and the atomic numbers in | ||
| * their respective `.param` file */ | ||
| PMACC_CONST_VECTOR(float_X,1,IONIZATION_EFIELD, | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. what do I do if I have two ion species in my simulation that can both be ionized?
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. (can be answered by opening an issue for that; feel free to address that in a follow up pull request)
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yep ... it would be possible but very inelegant to just add another differently named array of ionization energies and use them. Therefore let's think about it together in #771 . |
||
| 5.14e11 | ||
| ); | ||
|
|
||
| } // namespace SI | ||
| } // namespace picongpu | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,35 @@ | ||
| /** | ||
| * Copyright 2015 Marco Garten | ||
| * | ||
| * This file is part of PIConGPU. | ||
| * | ||
| * PIConGPU is free software: you can redistribute it and/or modify | ||
| * it under the terms of the GNU General Public License as published by | ||
| * the Free Software Foundation, either version 3 of the License, or | ||
| * (at your option) any later version. | ||
| * | ||
| * PIConGPU is distributed in the hope that it will be useful, | ||
| * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| * GNU General Public License for more details. | ||
| * | ||
| * You should have received a copy of the GNU General Public License | ||
| * along with PIConGPU. | ||
| * If not, see <http://www.gnu.org/licenses/>. | ||
| */ | ||
|
|
||
| #pragma once | ||
|
|
||
| namespace picongpu | ||
| { | ||
| namespace particles | ||
| { | ||
| namespace manipulators | ||
| { | ||
|
|
||
| template<typename T_ParamClass, typename T_ValueFunctor, typename T_SpeciesType = bmpl::_1> | ||
| struct SetAttributeImpl; | ||
|
|
||
| } //namespace manipulators | ||
| } //namespace particles | ||
| } //namespace picongpu |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,67 @@ | ||
| /** | ||
| * Copyright 2015 Marco Garten | ||
| * | ||
| * This file is part of PIConGPU. | ||
| * | ||
| * PIConGPU is free software: you can redistribute it and/or modify | ||
| * it under the terms of the GNU General Public License as published by | ||
| * the Free Software Foundation, either version 3 of the License, or | ||
| * (at your option) any later version. | ||
| * | ||
| * PIConGPU is distributed in the hope that it will be useful, | ||
| * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| * GNU General Public License for more details. | ||
| * | ||
| * You should have received a copy of the GNU General Public License | ||
| * along with PIConGPU. | ||
| * If not, see <http://www.gnu.org/licenses/>. | ||
| */ | ||
|
|
||
| #pragma once | ||
|
|
||
| #include "simulation_defines.hpp" | ||
|
|
||
|
|
||
| namespace picongpu | ||
| { | ||
| namespace particles | ||
| { | ||
| namespace manipulators | ||
| { | ||
|
|
||
| template<typename T_ParamClass, typename T_ValueFunctor, typename T_SpeciesType> | ||
| struct SetAttributeImpl : private T_ValueFunctor | ||
| { | ||
| typedef T_ParamClass ParamClass; | ||
| typedef T_SpeciesType SpeciesType; | ||
| typedef typename MakeIdentifier<SpeciesType>::type SpeciesName; | ||
|
|
||
| typedef T_ValueFunctor ValueFunctor; | ||
|
|
||
| HINLINE SetAttributeImpl(uint32_t currentStep) | ||
| { | ||
|
|
||
| } | ||
|
|
||
| template<typename T_Particle> | ||
| DINLINE void operator()(const DataSpace<simDim>& localCellIdx, T_Particle& particle, const bool isParticle) | ||
| { | ||
| typedef typename SpeciesType::FrameType FrameType; | ||
|
|
||
| if (isParticle) | ||
| { | ||
| /** Number of bound electrons at initial state of the neutral atom */ | ||
| const float_X protonNumber = GetAtomicNumbers<T_Particle>::type::numberOfProtons; | ||
|
|
||
| /* in this case: 'assign' the number of protons to the number of bound electrons | ||
| * \see particleConfig.param for the ValueFunctor */ | ||
| ValueFunctor::operator()(particle[boundElectrons_], protonNumber); | ||
| } | ||
| } | ||
|
|
||
| }; | ||
|
|
||
| } //namespace manipulators | ||
| } //namespace particles | ||
| } //namespace picongpu |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hm, why did you change that? do you mind reverting that change (or moving gasSphereFlanks up to
DIM2would also be ok).There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I removed it because @psychocoderHPC 's big pull request #730 removed all of the gas configuration via cmake flags. Test case 12 was originally introduced by me anyway. I plan to make gas droplet studies later but for now this
-DPARAM_GASPROFILE=gasSphereFlankswas totally without effect for all of the structure was changed.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ah true, thanks!