src issueshttps://gitlab.psi.ch/OPAL/src/-/issues2020-02-25T17:26:17+01:00https://gitlab.psi.ch/OPAL/src/-/issues/476missing include of <algorithm> and usage of std::minmax()2020-02-25T17:26:17+01:00gsellmissing include of <algorithm> and usage of std::minmax()In `bet/profile.cpp` the header `<algorithm>` must be included. Don't now why it compiles on macOS without ...
`std::minmax()` has been removed from C++17! This should be replaced.In `bet/profile.cpp` the header `<algorithm>` must be included. Don't now why it compiles on macOS without ...
`std::minmax()` has been removed from C++17! This should be replaced.OPAL 2.4.0gsellgsellhttps://gitlab.psi.ch/OPAL/src/-/issues/477Missing include in Algorithms/bet/math/savgol.cpp2020-02-26T09:37:55+01:00snuverink_jjochem.snuverink@psi.chMissing include in Algorithms/bet/math/savgol.cppWith gcc 7.3.0 from psi modules on linux I get the compiler error:
```
src/Algorithms/bet/math/savgol.cpp:406:5: error: ‘memcpy’ was not declared in this scope
memcpy(&cIn[1], c, sizeof(double)*n);
^~~~~~
/home/scratch/OPAL/OP...With gcc 7.3.0 from psi modules on linux I get the compiler error:
```
src/Algorithms/bet/math/savgol.cpp:406:5: error: ‘memcpy’ was not declared in this scope
memcpy(&cIn[1], c, sizeof(double)*n);
^~~~~~
/home/scratch/OPAL/OPAL-fork/OPAL-src/src/Algorithms/bet/math/savgol.cpp:406:5: note: suggested alternative: ‘wmemcpy’
memcpy(&cIn[1], c, sizeof(double)*n);
^~~~~~
wmemcpy
```
This is due to a missing include `<cstring>`.OPAL 2.4.0snuverink_jjochem.snuverink@psi.chsnuverink_jjochem.snuverink@psi.chhttps://gitlab.psi.ch/OPAL/src/-/issues/479IPPL tests and Boost timer2020-03-04T19:38:57+01:00frey_mIPPL tests and Boost timer### Summary
Yesterday, I had to compile OPAL together with a student. He requires the IPPL tests since he will work on P3M.
However, missing `${Boost_LIBRARY_DIRS}` in the `link_directories` command of the CMakeLists.txt of IPPL test ca...### Summary
Yesterday, I had to compile OPAL together with a student. He requires the IPPL tests since he will work on P3M.
However, missing `${Boost_LIBRARY_DIRS}` in the `link_directories` command of the CMakeLists.txt of IPPL test caused the error of not finding `boost_timer`.
**2 Questions:**
* Is `boost_timer` really required in the `target_link_libraries` command (e.g. [here](https://gitlab.psi.ch/OPAL/src/blob/master/ippl/test/particle/CMakeLists.txt#L37))?
* @snuverink\_j You cleaned up these tests in one of the MRs of https://gitlab.psi.ch/OPAL/src/issues/291. You didn't get this error when compiling, right?
### Steps to reproduce
Configure OPAL with: `-DENABLE_IPPLTESTS=1`
### What is the current *bug* behavior?
Cannot find the `boost_timer` library since `-L ${BOOST_LIBRARY_DIR}` is missing when compiling.
### What is the expected *correct* behavior?
It compiles properly.
### Possible fixes
@wyssling_t and I fixed it in his fork. The corresponding commit: https://gitlab.psi.ch/wyssling_t/src/commit/e7f9345447dda6757774e9b837c1757a2492eaf1https://gitlab.psi.ch/OPAL/src/-/issues/480`VALUE` command does not print variable names2020-07-06T11:41:02+02:00snuverink_jjochem.snuverink@psi.ch`VALUE` command does not print variable names### Summary
The `VALUE` command does not print according to the example in the [manual](https://gitlab.psi.ch/OPAL/manual-master/blob/master/control.asciidoc#sec.control.value). The variable value is printed, but not its name.
### Ste...### Summary
The `VALUE` command does not print according to the example in the [manual](https://gitlab.psi.ch/OPAL/manual-master/blob/master/control.asciidoc#sec.control.value). The variable value is printed, but not its name.
### Steps to reproduce
Run the manual example
```
REAL A=4;
VALUE,VALUE=TABLE(5,#*A);
REAL P1=5;
REAL P2=7;
VALUE,VALUE={P1,P2,P1*P2-3};
```
### What is the current *bug* behavior?
Current output:
```
value: = {0,4,8,12,16}
value: = {5,7,32}
```
### What is the expected *correct* behavior?
Ideal output (also with spaces):
```
value: {0*A,1*A,2*A,3*A,4*A} = {0, 4, 8, 12, 16}
value: {P1,P2,P1*P2-3} = {5, 7, 32}
```
### Observations
After some debugging I found that this is due to the direct evaluation in the parser after which the equations that are evaluated are no longer in memory (only the variable name of the array `VALUE`). An definition (with `:=`) gives the correct output.
From the [manual](https://gitlab.psi.ch/OPAL/manual-master/blob/master/format.asciidoc):
_When the attribute value is a constant or an expression preceded by the delimiter `=` it is evaluated immediately and the result is assigned to the attribute as a constant. When the attribute value is an expression preceded by the delimiter `:=` the expression is retained and re-evaluated whenever one of its operands changes._
For example:
```
VALUE,VALUE:=TABLE(5,#*A);
```
gives:
```
value: TABLE(1:5:1,(#*A)) = {4,8,12,16,20}
```
Note that the table output is still different from the manual output.
### Possible fixes
No direct evaluation in the `VALUE` command, also with the `=` delimiter.OPAL 2.4.0snuverink_jjochem.snuverink@psi.chsnuverink_jjochem.snuverink@psi.chhttps://gitlab.psi.ch/OPAL/src/-/issues/483Compiler warnings from boost headers stops compilation2020-03-17T16:36:38+01:00snuverink_jjochem.snuverink@psi.chCompiler warnings from boost headers stops compilation### Summary
Warnings from boost headers result in compilation error.
### Steps to reproduce
System specifications:
```
Host OS System: Darwin-14.5.0
The C++ compiler identification is: AppleClang
The C++ compiler version is: 7.0.2.70...### Summary
Warnings from boost headers result in compilation error.
### Steps to reproduce
System specifications:
```
Host OS System: Darwin-14.5.0
The C++ compiler identification is: AppleClang
The C++ compiler version is: 7.0.2.7000181
Boost version: 1.66.0
```
### What is the current *bug* behavior?
Compiler warnings from boost files result in compilation error.
### What is the expected *correct* behavior?
Boost or dependent libraries should not trigger compiler errors.
### Relevant logs and/or screenshots
```
In file included from /Users/jsnuverink/Documents/OPAL/fork/src/src/Distribution/Distribution.cpp:10:
In file included from /Users/jsnuverink/Documents/OPAL/fork/src/src/Distribution/SigmaGenerator.h:37:
In file included from /opt/local/include/boost/numeric/ublas/matrix_sparse.hpp:16:
In file included from /opt/local/include/boost/numeric/ublas/vector_sparse.hpp:16:
/opt/local/include/boost/numeric/ublas/storage_sparse.hpp:401:35: error: unused parameter
'hint' [-Werror,-Wunused-parameter]
iterator insert (iterator hint, const value_type &p) {
^
```
### Possible fixes
Include the boost headers as system headers so that gcc and clang don't issue warnings (with `-isystem`)
In CMake this can be done with:
```cmake
include_directories (SYSTEM ${Boost_INCLUDE_DIRS})
```
As a side note it seems `include_directories` is deprecated and it is advised to use `target_include_directories` instead.OPAL 2.4.0snuverink_jjochem.snuverink@psi.chsnuverink_jjochem.snuverink@psi.chhttps://gitlab.psi.ch/OPAL/src/-/issues/484clang compiler error for VerticalFFAMagnet (-Wabsolute-value)2020-03-17T10:48:05+01:00snuverink_jjochem.snuverink@psi.chclang compiler error for VerticalFFAMagnet (-Wabsolute-value)### Summary
Compiler error for VerticalFFAMagnet
### Steps to reproduce
```
Host OS System: Darwin-14.5.0
The C++ compiler identification is: AppleClang
The C++ compiler version is: 7.0.2.7000181
```
### Relevant logs and/or screensh...### Summary
Compiler error for VerticalFFAMagnet
### Steps to reproduce
```
Host OS System: Darwin-14.5.0
The C++ compiler identification is: AppleClang
The C++ compiler version is: 7.0.2.7000181
```
### Relevant logs and/or screenshots
```
src/Classic/AbsBeamline/VerticalFFAMagnet.cpp:82:9: error:
using integer absolute value function 'abs' when argument is of floating point type
[-Werror,-Wabsolute-value]
if (abs(R[0]) > halfWidth_m ||
^
/Users/jsnuverink/Documents/OPAL/fork/src/src/Classic/AbsBeamline/VerticalFFAMagnet.cpp:82:9: note:
use function 'std::abs' instead
if (abs(R[0]) > halfWidth_m ||
^~~
std::abs
```
### Possible fixes
Use `std::` namespaceOPAL 2.4.0snuverink_jjochem.snuverink@psi.chsnuverink_jjochem.snuverink@psi.chhttps://gitlab.psi.ch/OPAL/src/-/issues/485clang compiler errors for MPI_AllReduce (-Wtype-safety)2020-03-18T14:13:52+01:00snuverink_jjochem.snuverink@psi.chclang compiler errors for MPI_AllReduce (-Wtype-safety)### Summary
Clang compiler errors with MPI_AllReduce (-Wtype-safety)
### Steps to reproduce
```
-- The C compiler identification is Clang 9.0.1
-- The CXX compiler identification is Clang 9.0.1
-- Check for working C compiler: /opt/lo...### Summary
Clang compiler errors with MPI_AllReduce (-Wtype-safety)
### Steps to reproduce
```
-- The C compiler identification is Clang 9.0.1
-- The CXX compiler identification is Clang 9.0.1
-- Check for working C compiler: /opt/local/bin/mpicc-mpich-clang90
```
### Relevant logs and/or screenshots
1.
```
src/Algorithms/ParallelSliceTracker.cpp:291:41: error: argument type
'bool *' doesn't match specified 'MPI' type tag that requires 'int *' [-Werror,-Wtype-safety]
MPI_Allreduce(MPI_IN_PLACE, &globalEOL_m, 1, MPI_INT, MPI_LAND, Ippl::getComm());
^~~~~~~~~~~~ ~~~~~~~
```
2.
```
src/Algorithms/bet/EnvelopeBunch.cpp:1458:33: error: argument type
'size_t *' (aka 'unsigned long *') doesn't match specified 'MPI' type tag that requires 'long *'
[-Werror,-Wtype-safety]
MPI_Allreduce(MPI_IN_PLACE, &count, 1, MPI_LONG, MPI_SUM, Ippl::getComm());
^~~~~~ ~~~~~~~~
```
3. some more similar to 2.
### Possible fixes
1.
https://gitlab.psi.ch/OPAL/src/blob/4868efe8cf31c3646c49387a293852acf215c2bb/src/Algorithms/ParallelSliceTracker.cpp#L291
```c++
MPI_Allreduce(MPI_IN_PLACE, &globalEOL_m, 1, MPI_INT, MPI_LAND, Ippl::getComm());
```
`globalEOL_m` is a boolean and this doesn't combine properly with `MPI_INT`.
Instead, the commented out line above:
```
reduce(&globalEOL_m, &globalEOL_m + 1, &globalEOL_m, OpBitwiseAndAssign());
```
compiles fine.
@kraus: there is a similar line in `ParallelTTracker.cpp`. Is that line correct in this case as well?
2.
https://gitlab.psi.ch/OPAL/src/blob/4868efe8cf31c3646c49387a293852acf215c2bb/src/Algorithms/bet/EnvelopeBunch.cpp#L1458
```c++
MPI_Allreduce(MPI_IN_PLACE, &count, 1, MPI_LONG, MPI_SUM, Ippl::getComm());
```
should rather be:
```c++
MPI_Allreduce(MPI_IN_PLACE, &count, 1, MPI_UNSIGNED_LONG, MPI_SUM, Ippl::getComm());
```OPAL 2.4.0snuverink_jjochem.snuverink@psi.chsnuverink_jjochem.snuverink@psi.chhttps://gitlab.psi.ch/OPAL/src/-/issues/487Clang compiler warning for IntTSC (-Wsign-compare)2020-03-20T11:54:33+01:00snuverink_jjochem.snuverink@psi.chClang compiler warning for IntTSC (-Wsign-compare)### Summary
Clang compiler warning for IntTSC (-Wsign-compare).
### Steps to reproduce
```
-- The C compiler identification is Clang 9.0.1
-- The CXX compiler identification is Clang 9.0.1
-- Check for working C compiler: /opt/local/b...### Summary
Clang compiler warning for IntTSC (-Wsign-compare).
### Steps to reproduce
```
-- The C compiler identification is Clang 9.0.1
-- The CXX compiler identification is Clang 9.0.1
-- Check for working C compiler: /opt/local/bin/mpicc-mpich-clang90
```
### Relevant logs and/or screenshots
```
ippl/src/Particle/IntTSC.h:284:8: error: comparison of integers of
different signs: 'unsigned int' and 'int' [-Werror,-Wsign-compare]
if (p==-1) return .125*(1.-4.*dpos(i)+4.*dpos(i)*dpos(i));
~^ ~~
```
and many similar ones
### Possible fixes
The warning comes from
https://gitlab.psi.ch/OPAL/src/blob/master/ippl/src/Particle/IntTSC.h#L283
```c
auto W = [dpos](unsigned p, unsigned i) {
if (p==-1) return .125*(1.-4.*dpos(i)+4.*dpos(i)*dpos(i));
else if (p==0) return .25*(3.-4.*dpos(i)*dpos(i));
else if (p==+1) return .125*(1.+4.*dpos(i)+4.*dpos(i)*dpos(i)); };
```
`p` should be a signed integer instead of unsiged.OPAL 2.4.0snuverink_jjochem.snuverink@psi.chsnuverink_jjochem.snuverink@psi.chhttps://gitlab.psi.ch/OPAL/src/-/issues/488clang compiler error: unmatched template parameter `const CenteringEnum*`2020-03-18T10:54:28+01:00snuverink_jjochem.snuverink@psi.chclang compiler error: unmatched template parameter `const CenteringEnum*`### Summary
Clang compiler errors for ippl unit test BCond.
### Steps to reproduce
```
-- The C compiler identification is Clang 9.0.1
-- The CXX compiler identification is Clang 9.0.1
-- Check for working C compiler: /opt/local/bin/m...### Summary
Clang compiler errors for ippl unit test BCond.
### Steps to reproduce
```
-- The C compiler identification is Clang 9.0.1
-- The CXX compiler identification is Clang 9.0.1
-- Check for working C compiler: /opt/local/bin/mpicc-mpich-clang90
```
### Relevant logs and/or screenshots
```
[ 97%] Building CXX object tests/CMakeFiles/opal_unit_tests.dir/ippl_src/Field/BCond.cpp.o
In file included from /Users/jsnuverink/Documents/OPAL/fork/src/tests/ippl_src/Field/BCond.cpp:7:
In file included from /Users/jsnuverink/Documents/OPAL/fork/src/ippl/src/FieldLayout/CenteredFieldLayout.h:127:
/Users/jsnuverink/Documents/OPAL/fork/src/ippl/src/FieldLayout/CenteredFieldLayout.hpp:313:3: error: no matching
function for call to 'centeredInitialize'
centeredInitialize(*this, mesh, p, vnodes);
^~~~~~~~~~~~~~~~~~
/Users/jsnuverink/Documents/OPAL/fork/src/tests/ippl_src/Field/BCond.cpp:411:38: note: in instantiation of member
function 'CenteredFieldLayout<2, UniformCartesian<2, double>, CartesianCentering<&CCCEnums<2, 2,
0>::vectorFace, 2, 2> >::CenteredFieldLayout' requested here
CenteredFieldLayout<Dim,M,vFace> layoutVFace(mesh);
^
/Users/jsnuverink/Documents/OPAL/fork/src/ippl/src/FieldLayout/CenteredFieldLayout.hpp:93:1: note: candidate
template ignored: substitution failure : deduced non-type template argument does not have the same type as
the corresponding template parameter ('CenteringEnum *' vs 'const CenteringEnum *')
centeredInitialize(CenteredFieldLayout<Dim,Mesh,
^
...
```
### Possible fixes
The template parameter CenteringEnum* always has a const qualifier, for example,
https://gitlab.psi.ch/OPAL/src/blob/master/ippl/src/Meshes/CartesianCentering.h#L35:
```c++
template<const CenteringEnum* CE, unsigned Dim, unsigned NComponents=1U>
class CartesianCentering
{
```
However the const qualifier seems too restrictive and I propose to remove it.OPAL 2.4.0snuverink_jjochem.snuverink@psi.chsnuverink_jjochem.snuverink@psi.chhttps://gitlab.psi.ch/OPAL/src/-/issues/489clang compiler warnings in unit tests2020-03-18T21:09:58+01:00snuverink_jjochem.snuverink@psi.chclang compiler warnings in unit testsThere are some clang (9.0.1) compiler warnings (-Wunused, -Wuninitialized) in the unit tests.There are some clang (9.0.1) compiler warnings (-Wunused, -Wuninitialized) in the unit tests.OPAL 2.4.0snuverink_jjochem.snuverink@psi.chsnuverink_jjochem.snuverink@psi.chhttps://gitlab.psi.ch/OPAL/src/-/issues/490BEAM without particles specified crashes2020-07-06T08:44:02+02:00snuverink_jjochem.snuverink@psi.chBEAM without particles specified crashes### Summary
When the `BEAM` command has no particles (`NPARTS`) specified, OPAL crashes.
### Steps to reproduce
[drift-noparts.in](/uploads/a9848fe46eceb6059924d5971f621442/drift-noparts.in)
### What is the current *bug* behavior?
C...### Summary
When the `BEAM` command has no particles (`NPARTS`) specified, OPAL crashes.
### Steps to reproduce
[drift-noparts.in](/uploads/a9848fe46eceb6059924d5971f621442/drift-noparts.in)
### What is the current *bug* behavior?
Crash.
### What is the expected *correct* behavior?
Exit with error that no particles are specified.
### Relevant logs and/or screenshots
traceback:
```
Program received signal SIGSEGV, Segmentation fault.
Distribution::createOpalT(PartBunchBase<double, 3u>*, unsigned long&) ()
at /home/scratch/OPAL/OPAL-fork/OPAL-src/src/Distribution/Distribution.cpp:2820
2820 double maxTOrZ = *longIt;
Missing separate debuginfos, use: debuginfo-install glibc-2.12-1.212.el6.x86_64 infinipath-psm-3.0.1-115.1015_open.2.el6.x86_64 libnl-1.1.4-2.el6.x86_64 nss-pam-ldapd-0.7.5-20.el6_6.3.x86_64 zlib-1.2.3-29.el6.x86_64
(gdb) bt
#0 Distribution::createOpalT(PartBunchBase<double, 3u>*, unsigned long&) ()
at /home/scratch/OPAL/OPAL-fork/OPAL-src/src/Distribution/Distribution.cpp:2820
#1 0x0000000000885814 in TrackRun::setDistributionParallelT(Beam*) ()
at /home/scratch/OPAL/OPAL-fork/OPAL-src/src/Classic/Algorithms/PartBunchBase.hpp:254
#2 0x000000000088861f in TrackRun::setupTTracker() () at /home/scratch/OPAL/OPAL-fork/OPAL-src/src/Track/TrackRun.cpp:505
#3 0x000000000088914c in TrackRun::execute() () at /home/scratch/OPAL/OPAL-fork/OPAL-src/src/Track/TrackRun.cpp:197
#4 0x00000000006ea0aa in OpalParser::execute(Object*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&) const () at /home/scratch/OPAL/OPAL-fork/OPAL-src/src/OpalParser/OpalParser.cpp:139
#5 0x00000000006ee452 in OpalParser::parseAction(Statement&) const ()
at /home/scratch/OPAL/OPAL-fork/OPAL-src/src/OpalParser/OpalParser.cpp:172
#6 0x00000000006edcf3 in OpalParser::parse(Statement&) const ()
at /home/scratch/OPAL/OPAL-fork/OPAL-src/src/OpalParser/OpalParser.cpp:90
#7 0x00000000006e9d4c in OpalParser::run() const ()
at /home/scratch/OPAL/OPAL-fork/OPAL-src/src/OpalParser/OpalParser.cpp:607
#8 0x000000000088276a in TrackCmd::execute() () at /home/scratch/OPAL/OPAL-fork/OPAL-src/src/Track/TrackCmd.cpp:212
#9 0x00000000006ea0aa in OpalParser::execute(Object*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&) const () at /home/scratch/OPAL/OPAL-fork/OPAL-src/src/OpalParser/OpalParser.cpp:139
#10 0x00000000006ee452 in OpalParser::parseAction(Statement&) const ()
at /home/scratch/OPAL/OPAL-fork/OPAL-src/src/OpalParser/OpalParser.cpp:172
#11 0x00000000006edcf3 in OpalParser::parse(Statement&) const ()
at /home/scratch/OPAL/OPAL-fork/OPAL-src/src/OpalParser/OpalParser.cpp:90
#12 0x00000000006e9d4c in OpalParser::run() const ()
at /home/scratch/OPAL/OPAL-fork/OPAL-src/src/OpalParser/OpalParser.cpp:607
#13 0x00000000006eeb90 in OpalParser::run(TokenStream*) const ()
at /home/scratch/OPAL/OPAL-fork/OPAL-src/src/OpalParser/OpalParser.cpp:632
#14 0x0000000000642812 in main () at /home/scratch/OPAL/OPAL-fork/OPAL-src/src/Main.cpp:360
```
### Possible fixes
The method that crashes, takes the first entry without checking its size:
https://gitlab.psi.ch/OPAL/src/blob/master/src/Distribution/Distribution.cpp#L2817
```cpp
double Distribution::getMaxTOrZ() {
std::vector<double>::iterator longIt = tOrZDist_m.begin();
double maxTOrZ = *longIt;
```
This should be fixed. But in addition, it would be good to catch this when parsing, and OPAL can exit with an exception.OPAL 2.4.0snuverink_jjochem.snuverink@psi.chsnuverink_jjochem.snuverink@psi.chhttps://gitlab.psi.ch/OPAL/src/-/issues/493Template directory not found when path contains spaces2020-03-31T17:10:45+02:00bellotti_rTemplate directory not found when path contains spacesFor OPAL sampler runs, the template file is not found when the path contains spaces. This could be easily solved by adding quotes `"` around the template directory path.For OPAL sampler runs, the template file is not found when the path contains spaces. This could be easily solved by adding quotes `"` around the template directory path.OPAL 2.4.0krauskraushttps://gitlab.psi.ch/OPAL/src/-/issues/494Orbit threader throws an exception when TRACKBACK = TRUE and traveling wave s...2020-06-20T13:33:16+02:00krausOrbit threader throws an exception when TRACKBACK = TRUE and traveling wave structure present### Summary
When tracking the bunch back in time through a traveling wave structure then an exception is thrown in the method `TravelingWave::trackOnAxisParticle` which is used in the OrbitThreader.
### Steps to reproduce
Set `TRACK...### Summary
When tracking the bunch back in time through a traveling wave structure then an exception is thrown in the method `TravelingWave::trackOnAxisParticle` which is used in the OrbitThreader.
### Steps to reproduce
Set `TRACKBACK = TRUE` and add a traveling wave to the beamline.
### What is the current *bug* behavior?
Throws an exception.
### What is the expected *correct* behavior?
It should track the bunch back in time through a TWS.
### Possible fixes
Don't override the method of the base class RFCavity.OPAL 2.4.0krauskraushttps://gitlab.psi.ch/OPAL/src/-/issues/509OrbitThreader::computeMaximalImplicitDrift not yielding correct results2020-07-22T09:47:42+02:00krausOrbitThreader::computeMaximalImplicitDrift not yielding correct results### Summary
The method OrbitThreader::computeMaximalImplicitDrift doesn't yield correct results if elements are placed in 3D in the input file.
### Steps to reproduce
Download and unpack the attached [tar file](/uploads/b1fb3a7ed314c...### Summary
The method OrbitThreader::computeMaximalImplicitDrift doesn't yield correct results if elements are placed in 3D in the input file.
### Steps to reproduce
Download and unpack the attached [tar file](/uploads/b1fb3a7ed314c1a6d3141f6a4fa53646/3dplacedElement.tgz) and then run it with the current master version of OPAL.
### What is the current *bug* behavior?
The rotated quadrupole in the beam line is neglected in the output of the orbit threader and stops tracking after the second element.
### What is the expected *correct* behavior?
OPAL should track the beam through all elements.
### Relevant logs and/or screenshots
### Possible fixes
Track with a single particle until it leaves the bounding box which encloses all elements.
(If you can, link to the line of code that might be responsible for the problem)OPAL 2.4.0krauskraus2020-07-24https://gitlab.psi.ch/OPAL/src/-/issues/510compiler errors in ippl/test with clang92020-04-17T09:43:25+02:00snuverink_jjochem.snuverink@psi.chcompiler errors in ippl/test with clang9### Summary
Reported by @adelmann.
Compiler errors with clang with `ENABLE_IPPLTESTS=ON`
### Steps to reproduce
```
-- The C compiler identification is Clang 9.0.1
-- The CXX compiler identification is Clang 9.0.1
-- Check for worki...### Summary
Reported by @adelmann.
Compiler errors with clang with `ENABLE_IPPLTESTS=ON`
### Steps to reproduce
```
-- The C compiler identification is Clang 9.0.1
-- The CXX compiler identification is Clang 9.0.1
-- Check for working C compiler: /opt/local/bin/mpicc-mpich-clang90
```
### Relevant logs and/or screenshots
```
clang: error: optimization flag '-fno-tree-vrp'
```
```
ippl/test/particle/p3m3d.cpp:170:72: error: implicit instantiation of
undefined template 'ApplyField<double>'
HPB.for_each(RadiusCondition<double, Dim>(interaction_radius), ApplyField<double>(-1,interaction_radius));
```
```
ippl/test/particle/ChargedParticleFactory.hpp:564:73: error: unused
parameter 'extend_l' [-Werror,-Wunused-parameter]
void createParticleDistributionEquiPart(Particles & P, Vektor<double,3> extend_l, Vektor<double,3> extend_r...
```
### Possible fixes
* remove the `-fno-tree-vrp` flag
* comment out function parameters
* reorder code to avoid undefined template errorOPAL 2.4.0snuverink_jjochem.snuverink@psi.chsnuverink_jjochem.snuverink@psi.chhttps://gitlab.psi.ch/OPAL/src/-/issues/511Link error if OpenMP is enabled2020-04-16T15:42:52+02:00gsellLink error if OpenMP is enabled### Summary
The linker reports undefined symbols if OpenMP is enabled.
### Steps to reproduce
```
cmake -DENABLE_OPENMP=TRUE ...
```
### What is the current *bug* behavior?
```
libOPAL.a(EnvelopeBunch.cpp.o): En la función `Envelo...### Summary
The linker reports undefined symbols if OpenMP is enabled.
### Steps to reproduce
```
cmake -DENABLE_OPENMP=TRUE ...
```
### What is the current *bug* behavior?
```
libOPAL.a(EnvelopeBunch.cpp.o): En la función `EnvelopeBunch::calcI() [clone ._omp_fn.0]':
EnvelopeBunch.cpp:(.text+0x82): referencia a `omp_get_num_threads' sin definir
EnvelopeBunch.cpp:(.text+0x89): referencia a `omp_get_thread_num' sin definir
libOPAL.a(EnvelopeBunch.cpp.o): En la función `EnvelopeBunch::calcI()':
EnvelopeBunch.cpp:(.text+0x9451): referencia a `GOMP_parallel' sin definir
../ippl/src/libippl.a(CommMPI.cpp.o): En la función `CommMPI::CommMPI(int&, char**&, int, bool, ompi_communicator_t*)':
CommMPI.cpp:(.text+0xf40): referencia a `omp_get_max_threads' sin definir
collect2: error: ld devolvió el estado de salida 1
make[2]: *** [src/CMakeFiles/opal.dir/build.make:117: src/opal] Error 1
make[1]: *** [CMakeFiles/Makefile2:738: src/CMakeFiles/opal.dir/all] Error 2
make: *** [Makefile:130: all] Error 2
```
### Possible fixes
Set `-fopenmp` as a linker option.OPAL 2.4.0gsellgsellhttps://gitlab.psi.ch/OPAL/src/-/issues/512compiler errors in tests/ippl_src with clang92021-01-13T22:09:20+01:00snuverink_jjochem.snuverink@psi.chcompiler errors in tests/ippl_src with clang9### Summary
Compiler errors with clang with `BUILD_OPAL_UNIT_TESTS=ON`
### Steps to reproduce
```
-- The C compiler identification is Clang 9.0.1
-- The CXX compiler identification is Clang 9.0.1
-- Check for working C compiler: /opt/...### Summary
Compiler errors with clang with `BUILD_OPAL_UNIT_TESTS=ON`
### Steps to reproduce
```
-- The C compiler identification is Clang 9.0.1
-- The CXX compiler identification is Clang 9.0.1
-- Check for working C compiler: /opt/local/bin/mpicc-mpich-clang90
```
### Relevant logs and/or screenshots
```
src/tests/ippl_src/Field/Field.cpp:1205:57: error: using integer absolute
value function 'abs' when argument is of floating point type [-Werror,-Wabsolute-value]
Vektor<unsigned,D3> N(static_cast<unsigned> (ceil( (abs(boxMin[0])+boxMax[0])/h[0])),
^
src/tests/ippl_src/Field/Field.cpp:1205:57: note: use function 'std::abs'
instead
```OPAL 2.4.0snuverink_jjochem.snuverink@psi.chsnuverink_jjochem.snuverink@psi.chhttps://gitlab.psi.ch/OPAL/src/-/issues/513Improving reading of pressure data2020-07-06T11:54:52+02:00ext-calvo_ppedro.calvo@ciemat.esImproving reading of pressure dataThe pressure data from field map include holes from components as part of the geometry. To skip the LogicalError when particles hit with boundaries of the geometry (with pressure value null), the `checkPressure` function has been improvedThe pressure data from field map include holes from components as part of the geometry. To skip the LogicalError when particles hit with boundaries of the geometry (with pressure value null), the `checkPressure` function has been improvedOPAL 2.4.0ext-calvo_ppedro.calvo@ciemat.esext-calvo_ppedro.calvo@ciemat.eshttps://gitlab.psi.ch/OPAL/src/-/issues/514Fix error message in MGPoissonSolver2020-05-08T13:50:00+02:00frey_mFix error message in MGPoissonSolverThe following discussion from !327 should be addressed:
- [ ] @snuverink_j started a [discussion](https://gitlab.psi.ch/OPAL/src/merge_requests/327#note_20154):
> This message seems completely wrong. Can you fix it (or resolve by ...The following discussion from !327 should be addressed:
- [ ] @snuverink_j started a [discussion](https://gitlab.psi.ch/OPAL/src/merge_requests/327#note_20154):
> This message seems completely wrong. Can you fix it (or resolve by opening a new issue?)
```cpp
throw OpalException("ArbitraryDomain::compute",
"The class ArbitraryDomain only works with parallelization\n"
"in z-direction.\n"
"Please set PARFFTX=FALSE, PARFFTY=FALSE, PARFFTT=TRUE in \n"
"the definition of the field solver in the input file.\n");
```OPAL 2.4.0snuverink_jjochem.snuverink@psi.chsnuverink_jjochem.snuverink@psi.chhttps://gitlab.psi.ch/OPAL/src/-/issues/515Not all (Opal-T) field maps expect same origin for position2020-07-16T22:35:05+02:00krausNot all (Opal-T) field maps expect same origin for positionIn the method `getFieldstrength` some field maps expect the origin of the position at which the field should be evaluated to be at the beginning of the field map others at the origin of the element (`z = 0` in the field map).
All field ...In the method `getFieldstrength` some field maps expect the origin of the position at which the field should be evaluated to be at the beginning of the field map others at the origin of the element (`z = 0` in the field map).
All field maps should expect the position to be at the origin of the element.krauskraus