Comments (3)
Hello,
This element has issues, see #749, and I would not recommend to use it for the moment.
These issues are being addressed in #759 and will hopefully be released soon. You may get in touch with @ZeusMarti and @joanarenillas for details.
Depending on what you are trying to model, you may alternatively use kick maps or the energy loss element to approximate your wiggler.
from at.
Hello @ustc-cheese,
There is a bug in both GWigSymplecticPass.c
and its radiative version GWigSymplecticRadPass.c
, that produces the AttributeError you mention. The current versions in the master branch take the energy for the wiggler from the element rather than the structure. In the Mex part of the integrators, instead of
Energy = atGetDouble(ElemData, "Energy"); check_error();
there should be
Energy=atGetOptionalDouble(ElemData,"Energy",Param->energy); check_error();
.
If you just want to get around this issue, you can change this line of code in your local wiggler passmethods. Nevertheless, I would not recommend doing this, since these passmetods have additional bugs which can lead you to incorrect results. As @swhite2401 suggested, I would avoid using the current distribution of GWigSymplecticPass.c
and GWigSymplecticRadPass.c
, unless it is strictly necessary.
All these bugs are fixed for both GWigSymplecticPass.c
and GWigSymplecticRadPass.c
(in Matlab and Python) in my branch wigglerintegrator_debugged
. You can base your work in my branch to get around these issues, but I must warn you that this branch includes several other changes (see #759) and has still not been merged to the master branch (we are intending to merge it soon).
Hope this helps,
Joan
from at.
Thank you all! Hoping for your soon correction!
from at.
Related Issues (20)
- pyAT Distinguish between a sector bending magnet and a rectangular bending magnet HOT 2
- Reduce behaves differently in Matlab and python
- B0 added twice in exactkickrad HOT 2
- python: ringparam not well identified by lattice_load HOT 6
- bug is saving lattice HOT 4
- Bug: atwiggler HOT 13
- problem with display of correctly initialised VariableMultipole element HOT 1
- Change Legend Labels for plot_trajectory() function HOT 12
- fast_ring when having harmonic cavities in the lattice HOT 4
- AT_2_Elegant uses deprecated N_KICKS
- Factor 4 missing in Touschek scattering B2 expression HOT 5
- Rotation of dipoles HOT 18
- matlab atlinopt4 check on 6d is disabled
- Severe bug introduced by #766 HOT 2
- Bug in Lattice.avlinopt HOT 7
- ring.get_lifetime fails if list of reference indexes has only one valid element HOT 1
- Compilation error when building from repository HOT 27
- VariableMultipole Usage HOT 7
- Inherited fields don't exist unless first explictly set HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from at.