src issueshttps://gitlab.psi.ch/OPAL/src/-/issues2017-07-24T10:29:37+02:00https://gitlab.psi.ch/OPAL/src/-/issues/117Distribution.cpp2017-07-24T10:29:37+02:00adelmannDistribution.cppCan you explain me the additional particles
we add at line 518 and the for loop starting
at line 531.Can you explain me the additional particles
we add at line 518 and the for loop starting
at line 531.OPAL 1.9.xkrauskraushttps://gitlab.psi.ch/OPAL/src/-/issues/116CollimatorPhysics::EnergyLoss2021-02-16T08:39:33+01:00adelmannCollimatorPhysics::EnergyLossis hard coded for protons. Need also make clear in the manual (exception in code) that electrons are not supported.is hard coded for protons. Need also make clear in the manual (exception in code) that electrons are not supported.OPAL 2021.1ext-calvo_ppedro.calvo@ciemat.esext-calvo_ppedro.calvo@ciemat.eshttps://gitlab.psi.ch/OPAL/src/-/issues/115Emission2017-06-17T20:38:35+02:00adelmannEmissionEmission is very slow and hardly can be used above 1E7 particles. Reason the algorithm does not scale.Emission is very slow and hardly can be used above 1E7 particles. Reason the algorithm does not scale.OPAL 1.9.xadelmannadelmannhttps://gitlab.psi.ch/OPAL/src/-/issues/114Help command gives error2017-06-17T20:38:35+02:00adelmannHelp command gives error```
==>help, source;
1 help, source;
OPAL>
OPAL> The "SOURCE" element defines a Source.
Attributes:
OPAL> string TYPE The element design type (the project name)
OPAL> string APERTURE The ...```
==>help, source;
1 help, source;
OPAL>
OPAL> The "SOURCE" element defines a Source.
Attributes:
OPAL> string TYPE The element design type (the project name)
OPAL> string APERTURE The element aperture
OPAL> real L The element length in m
OPAL> real ELEMEDGE The position of the element in path length (in m)
OPAL> string WAKEF Defines the wake function
Error>
Error> *** Error:
Error> *** in line 1 of file "standard input":
Error> HELP,SOURCE;
Error> basic_string::_M_create
Error>
```OPAL 1.9.xkrauskraushttps://gitlab.psi.ch/OPAL/src/-/issues/113Static cuda libraries2017-07-24T10:29:38+02:00Uldis LocansStatic cuda librarieslink to static cuda libraries when compiling with DKSlink to static cuda libraries when compiling with DKSOPAL 1.9.xhttps://gitlab.psi.ch/OPAL/src/-/issues/112ID0 particle replaced in the h5 file2020-07-02T08:17:04+02:00Valeria RizzoglioID0 particle replaced in the h5 filePlease check:
- if the ID0 is still replaced in the h5
- if the reference particle is stored as ID0. If yes, we could have the same problem with the beam sizePlease check:
- if the ID0 is still replaced in the h5
- if the reference particle is stored as ID0. If yes, we could have the same problem with the beam sizeOPAL 2.4.0adelmannadelmannhttps://gitlab.psi.ch/OPAL/src/-/issues/111Move download page from Trac to gitlab2017-07-24T10:29:38+02:00krausMove download page from Trac to gitlabCurrently the download page is a page in the old Trac instance. Move it to gitlab.Currently the download page is a page in the old Trac instance. Move it to gitlab.OPAL 1.6.0gsellgsellhttps://gitlab.psi.ch/OPAL/src/-/issues/110PartBunch::get_bounds can produce NaNs2019-10-25T13:47:36+02:00snuverink_jjochem.snuverink@psi.chPartBunch::get_bounds can produce NaNsWhile trying to update the [PSI-Ring](https://gitlab.psi.ch/AMAS-BDModels/PSI-Ring) simulations to the master branch, I encountered the following running error:
```
OPAL> PartBunch.cpp: 1574 nan 2.000000e-02
Error>
Error> *** User...While trying to update the [PSI-Ring](https://gitlab.psi.ch/AMAS-BDModels/PSI-Ring) simulations to the master branch, I encountered the following running error:
```
OPAL> PartBunch.cpp: 1574 nan 2.000000e-02
Error>
Error> *** User error detected by function "PartBunch::boundp() "
Error> *** in line 311 of file "Ring.in":
Error> RUN,METHOD="CYCLOTRON-T",BEAM=BEAM1,FIELDSOLVER=FS1,DISTRIBUTION=DIST;
Error> h<0, can not build a mesh
```
The `nan` gets introduced in line 1521: `get_bounds(rmin_m, rmax_m);`
Printing out rmax and rmin before and after this line gives (ymmv):
before:
```
(i,rmax, rmin) 0 0.0000000000000000e+00 0.0000000000000000e+00
(i,rmax, rmin) 1 0.0000000000000000e+00 0.0000000000000000e+00
(i,rmax, rmin) 2 0.0000000000000000e+00 0.0000000000000000e+00
```
after
```
(i,rmax, rmin) 0 7.1153710538428058e-03 -6.9640951722910538e-03
(i,rmax, rmin) 1 4.0421699390708048e-02 -4.0512781208033796e-02
(i,rmax, rmin) 2 -nan -nan
```
I likely do something wrong with my input, but I believe the code should not get this far and produce a better error message.
This can be reproduced with OPAL master (0469d1ac), and the latest version of [PSI-Ring](https://gitlab.psi.ch/AMAS-BDModels/PSI-Ring) and executing `runOpal --nobatch`
**Edit 20 July:**
https://gitlab.psi.ch/OPAL/src/issues/110#note_1914: Simplified input file [Ring.in](https://gitlab.psi.ch/OPAL/src/uploads/ec9579a7c5009c1b7465266afe4373c0/Ring.in)
https://gitlab.psi.ch/OPAL/src/issues/110#note_1916: Regression test `RingCyclotron` has the same bug when one changes the distribution from gauss to either single particle or binomial. snuverink_jjochem.snuverink@psi.chsnuverink_jjochem.snuverink@psi.chhttps://gitlab.psi.ch/OPAL/src/-/issues/109OPAL does not compile with AMR Solver and unit tests2017-07-24T10:29:38+02:00snuverink_jjochem.snuverink@psi.chOPAL does not compile with AMR Solver and unit testsCompiling OPAL with ENABLE_AMR_SOLVER=1 and DBUILD_OPAL_UNIT_TESTS=1 gives the following compile error:
```
/home/scratch/OPAL/src/tests/opal_src/Distribution/GaussTest.cpp: In member function ‘virtual void GaussTest_FullSigmaTest1_Tes...Compiling OPAL with ENABLE_AMR_SOLVER=1 and DBUILD_OPAL_UNIT_TESTS=1 gives the following compile error:
```
/home/scratch/OPAL/src/tests/opal_src/Distribution/GaussTest.cpp: In member function ‘virtual void GaussTest_FullSigmaTest1_Test::TestBody()’:
<command-line>:0:6: error: expected unqualified-id before numeric constant
/home/scratch/OPAL/src/tests/opal_src/Distribution/GaussTest.cpp:74:15: note: in expansion of macro ‘OPAL’
OpalData *OPAL = OpalData::getInstance();
^
```
This is because OPAL is defined as preprocessor macro within CMake (with value 1):
```
[ 93%] Building CXX object tests/CMakeFiles/opal_unit_tests.dir/opal_src/Distribution/GaussTest.cpp.o
g++ -DBL_FORT_USE_UNDERSCORE -DBL_Linux -DBL_NOLINEVALUES -DBL_PARALLEL_IO -DBL_SPACEDIM=3 -DBL_USE_DOUBLE -DBL_USE_MPI -DMG_USE_F90_SOLVERS -DMG_USE_FBOXLIB -DNDEBUG -DOPAL .... tests/opal_src/Distribution/GaussTest.cpp
```
This is done in [CMakeModules/CCSEOptions.cmake](https://gitlab.psi.ch/OPAL/src/blob/master/CMakeModules/CCSEOptions.cmake#L74)
:
`list(APPEND BL_DEFINES "OPAL")`
I don't see a reason to add OPAL here since afaik it is not used anywhere as such.
That said it might good to adopt [camelCase for the variable name](https://gitlab.psi.ch/OPAL/src/wikis/for-developers#28-method-argument-and-local-variable-names).https://gitlab.psi.ch/OPAL/src/-/issues/108Revise macros such as DBG_SCALARFIELD and replace them with an Option command2017-07-24T10:29:38+02:00snuverink_jjochem.snuverink@psi.chRevise macros such as DBG_SCALARFIELD and replace them with an Option commandCompiling OPAL with the option DBG_SCALARFIELD gives the following compiler error:
```
src/Classic/Algorithms/PartBunch.cpp: In member function ‘void PartBunch::computeSelfFields(int)’:
/home/scratch/OPAL/src/src/Classic/Algorithms/...Compiling OPAL with the option DBG_SCALARFIELD gives the following compiler error:
```
src/Classic/Algorithms/PartBunch.cpp: In member function ‘void PartBunch::computeSelfFields(int)’:
/home/scratch/OPAL/src/src/Classic/Algorithms/PartBunch.cpp:715:29: error: ‘rmin’ was not declared in this scope
*gmsg << (rmin(0) - origin(0)) / spacing(0) << "\t"
^
```
This was introduced in commit https://gitlab.psi.ch/OPAL/src/commit/595b4b83818596b5f7a72e086cbbda4325f70aa8#852edcbb7804c7416aa51f7264a7a36fc1fa3fef_781_683snuverink_jjochem.snuverink@psi.chsnuverink_jjochem.snuverink@psi.chhttps://gitlab.psi.ch/OPAL/src/-/issues/107keyword register2017-07-24T10:29:38+02:00snuverink_jjochem.snuverink@psi.chkeyword registerThe source code contains at several locations the keyword `register`. This is of no use anymore (see e.g. http://www.drdobbs.com/keywords-that-arent-or-comments-by-anoth/184403859). And with gcc compilers this might also gives some warni...The source code contains at several locations the keyword `register`. This is of no use anymore (see e.g. http://www.drdobbs.com/keywords-that-arent-or-comments-by-anoth/184403859). And with gcc compilers this might also gives some warnings:
```
src/Solvers/TaperDomain.cpp:89:66: warning: address requested for ‘y’, which is declared ‘register’ [-Wextra]
IntersectXDir.insert(std::pair<int, double>(y, xd));
```
Therefore, I propose to remove this keyword from the code everywhere.snuverink_jjochem.snuverink@psi.chsnuverink_jjochem.snuverink@psi.chhttps://gitlab.psi.ch/OPAL/src/-/issues/106Segfault in case of Material at beginning of beamline2017-07-24T10:29:37+02:00frey_mSegfault in case of Material at beginning of beamlineWe run [sim.in](/uploads/94c1f0db20f572ae97a6a320574d9545/sim.in).
Error output:
```
OPAL>
OPAL> --- BEGIN FIELD LIST ---------------------------------------------------------------
OPAL>
OPAL> --- 0.2 m -- 0.200228 m -- has surface...We run [sim.in](/uploads/94c1f0db20f572ae97a6a320574d9545/sim.in).
Error output:
```
OPAL>
OPAL> --- BEGIN FIELD LIST ---------------------------------------------------------------
OPAL>
OPAL> --- 0.2 m -- 0.200228 m -- has surface physics ------------------------------------
OPAL> DMA_DEG1
OPAL> --- 0.200228 m -- 1.20023 m -- -----------------------------------------------------
OPAL> D1
OPAL>
OPAL> --- END FIELD LIST -----------------------------------------------------------------
OPAL>
[opalrunner:18498] *** Process received signal ***
[opalrunner:18498] Signal: Segmentation fault (11)
[opalrunner:18498] Signal code: Address not mapped (1)
[opalrunner:18498] Failing at address: 0x30
[opalrunner:18498] [ 0] /lib64/libpthread.so.0[0x32ea20f7e0]
[opalrunner:18498] [ 1] opal(_ZN12OpalBeamline14switchElementsERKdS1_S1_RKb+0x1cf)[0xf1829f]
[opalrunner:18498] [ 2] opal[0x10758bd]
[opalrunner:18498] [ 3] opal(_ZN16ParallelTTracker21executeDefaultTrackerEv+0x2c0)[0x107c520]
[opalrunner:18498] [ 4] opal(_ZN16ParallelTTracker7executeEv+0x1f)[0x107d35f]
[opalrunner:18498] [ 5] opal(_ZN8TrackRun7executeEv+0x751)[0x1043b51]
[opalrunner:18498] [ 6] opal(_ZNK10OpalParser7executeEP6ObjectRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE+0x35)[0xcac6c5]
[opalrunner:18498] [ 7] opal(_ZNK10OpalParser11parseActionER9Statement+0x11a)[0xcb062a]
[opalrunner:18498] [ 8] opal(_ZNK10OpalParser5parseER9Statement+0x186)[0xcb0076]
[opalrunner:18498] [ 9] opal(_ZNK10OpalParser3runEv+0x2c)[0xcb158c]
[opalrunner:18498] [10] opal(_ZN8TrackCmd7executeEv+0x343)[0xd63cb3]
[opalrunner:18498] [11] opal(_ZNK10OpalParser7executeEP6ObjectRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE+0x35)[0xcac6c5]
[opalrunner:18498] [12] opal(_ZNK10OpalParser11parseActionER9Statement+0x11a)[0xcb062a]
[opalrunner:18498] [13] opal(_ZNK10OpalParser5parseER9Statement+0x186)[0xcb0076]
[opalrunner:18498] [14] opal(_ZNK10OpalParser3runEv+0x2c)[0xcb158c]
[opalrunner:18498] [15] opal(_ZNK10OpalParser3runEP11TokenStream+0x6a)[0xcb0a8a]
[opalrunner:18498] [16] opal(main+0x8e8)[0xc3f858]
[opalrunner:18498] [17] /lib64/libc.so.6(__libc_start_main+0xfd)[0x32e961ed1d]
[opalrunner:18498] [18] opal[0xc36cb5]
[opalrunner:18498] *** End of error message ***
--------------------------------------------------------------------------
mpirun noticed that process rank 0 with PID 18498 on node opalrunner exited on signal 11 (Segmentation fault).
```
We doesn't crash when we add a drift in front of the material.OPAL 1.6.1adelmannadelmannhttps://gitlab.psi.ch/OPAL/src/-/issues/105RectangularDomain::getBoundaryStencil typo2017-06-17T20:38:34+02:00snuverink_jjochem.snuverink@psi.chRectangularDomain::getBoundaryStencil typolines [51-53](https://gitlab.psi.ch/OPAL/src/blob/master/src/Solvers/RectangularDomain.cpp#L51):
```c++
S = -hr[0] * hr[2] / hr[1];
F = -hr[0] * hr[1] / hr[2];
S = -hr[0] * hr[1] / hr[2];
```
The second `S` assignment is lik...lines [51-53](https://gitlab.psi.ch/OPAL/src/blob/master/src/Solvers/RectangularDomain.cpp#L51):
```c++
S = -hr[0] * hr[2] / hr[1];
F = -hr[0] * hr[1] / hr[2];
S = -hr[0] * hr[1] / hr[2];
```
The second `S` assignment is likely a typo and should be `B`, but it would be good if someone could check the formulas.OPAL 1.6.1https://gitlab.psi.ch/OPAL/src/-/issues/104--version or --help crashes OPAL2017-06-17T20:38:34+02:00adelmann--version or --help crashes OPAL--version or --help crashes OPAL--version or --help crashes OPALOPAL 1.9.xadelmannadelmannhttps://gitlab.psi.ch/OPAL/src/-/issues/103Overlap of field maps OPAL-cycl2017-07-24T10:29:37+02:00adelmannOverlap of field maps OPAL-cyclCommunicated by @zhang_h
Case maps for COMET.
We have four non-superpose RF maps and one superpose electrostatic map. The read-in loop could be stopped at the third RF map, without reading the electrostatic map. We may put the ...Communicated by @zhang_h
Case maps for COMET.
We have four non-superpose RF maps and one superpose electrostatic map. The read-in loop could be stopped at the third RF map, without reading the electrostatic map. We may put the electrostatic map in front, but it could cause other problem.OPAL 1.9.xadelmannadelmannhttps://gitlab.psi.ch/OPAL/src/-/issues/102PSDUMPFRAME report is wrong in OPTIOn TELL=TRUE2017-06-17T20:38:34+02:00adelmannPSDUMPFRAME report is wrong in OPTIOn TELL=TRUEThe following trivial OPAL input file:
```
OPTION, TELL=TRUE;
OPTION, PSDUMPFRAME=REFERENCE;
QUIT;
```
shows
OPAL> Current settings of options:
OPAL> OPTION,ECHO=FALSE,INFO=TRUE,TRACE=FALSE,VERIFY=FALSE,WARN=TRUE,
OPAL> SEED=1.2...The following trivial OPAL input file:
```
OPTION, TELL=TRUE;
OPTION, PSDUMPFRAME=REFERENCE;
QUIT;
```
shows
OPAL> Current settings of options:
OPAL> OPTION,ECHO=FALSE,INFO=TRUE,TRACE=FALSE,VERIFY=FALSE,WARN=TRUE,
OPAL> SEED=1.23457e+08,TELL=TRUE,PSDUMPFREQ=10,STATDUMPFREQ=10,
OPAL> PSDUMPEACHTURN=FALSE,PSDUMPLOCALFRAME=FALSE,**PSDUMPFRAME="GLOBAL"**,
OPAL> SPTDUMPFREQ=1,REPARTFREQ=10,REBINFREQ=100,SCSOLVEFREQ=1,
OPAL> MTSSUBSTEPS=1,REMOTEPARTDEL=0,SCAN=FALSE,RHODUMP=FALSE,
OPAL> EBDUMP=FALSE,CSRDUMP=FALSE,AUTOPHASE=0,PPDEBUG=FALSE,
OPAL> SURFDUMPFREQ=-1,NUMBLOCKS=0,RECYCLEBLOCKS=0,NLHS=1,CZERO=FALSE,
OPAL> RNGTYPE="RANDOM",SCHOTTKYCORR=FALSE,SCHOTTKYRENO=-1,ENABLEHDF5=TRUE,
OPAL> ASCIIDUMP=FALSE,BOUNDPDESTROYFQ=10,BEAMHALOBOUNDARY=0,
OPAL> CLOTUNEONLY=FALSE,VERSION=10000;OPAL 1.6.1adelmannadelmannhttps://gitlab.psi.ch/OPAL/src/-/issues/100Kickers with field maps2021-06-10T18:07:13+02:00krausKickers with field mapsKickers at bERLinPro are far from perfect dipoles. Instead they have a strong higher order components. The current implementation only provides a hard-edge model. Let the user add field maps to better model them.Kickers at bERLinPro are far from perfect dipoles. Instead they have a strong higher order components. The current implementation only provides a hard-edge model. Let the user add field maps to better model them.krauskraushttps://gitlab.psi.ch/OPAL/src/-/issues/99When APVETO=TRUE set phase relative to arrival time2017-07-24T10:29:38+02:00krausWhen APVETO=TRUE set phase relative to arrival timeThe phase of a cavity at time $`t`$ is given by
```math
\varphi (t) = \omega \cdot t + \varphi_{\text{LAG}} + \varphi_0.
```
When running the auto-phasing algorithm we set the phase of a cavity relative to the phase at which a cavity...The phase of a cavity at time $`t`$ is given by
```math
\varphi (t) = \omega \cdot t + \varphi_{\text{LAG}} + \varphi_0.
```
When running the auto-phasing algorithm we set the phase of a cavity relative to the phase at which a cavity yields maximal energy. Thus $`\varphi_0 = \varphi_{\text{max}}`$. In some cases we want or have to set APVETO=TRUE. Currently we set $`\varphi_0 = 0`$ but we should set it such that $`\varphi (t_{\text{ELEMEDGE}}) = 0`$. Here $`t_{\text{ELEMEDGE}}`$ is the time at which the reference particle enters the element (either physically or alternatively the region in which field of the cavity is non-zero).OPAL 2.0.0krauskraushttps://gitlab.psi.ch/OPAL/src/-/issues/98Placement of elements in 3D coordinates not possible anymore2017-06-17T20:38:34+02:00krausPlacement of elements in 3D coordinates not possible anymorePlacement of elements in 3D coordinates (see attachment) was possible, this isn't the case anymore.
This issue has to do with the fact that I added the attribute ELEMEDGE and introduced access methods.
[Niowave_first_korrektur.dat](/u...Placement of elements in 3D coordinates (see attachment) was possible, this isn't the case anymore.
This issue has to do with the fact that I added the attribute ELEMEDGE and introduced access methods.
[Niowave_first_korrektur.dat](/uploads/ad152c3a3e13fa0ec231105ec4711817/Niowave_first_korrektur.dat)[Banana_ref.in](/uploads/68db2ec88393f764cfebd520466bf2de/Banana_ref.in)[ez_normalizedcathodepos_4.txt](/uploads/8015defbc8c4082e95296f6ff3133670/ez_normalizedcathodepos_4.txt)OPAL 1.9.xkrauskraushttps://gitlab.psi.ch/OPAL/src/-/issues/97Collimator/Probe2018-08-14T07:51:06+02:00adelmannCollimator/ProbeSuggestions from @zhang_h :
Distinguish between probes and collimator and name the collimators on the stdout.
Write probe and collimator data in one line for easy post processing
Add angles back per defaultSuggestions from @zhang_h :
Distinguish between probes and collimator and name the collimators on the stdout.
Write probe and collimator data in one line for easy post processing
Add angles back per defaultOPAL 1.9.xadelmannadelmann