Skip to Content.
Sympa Menu

opal - Re: [Opal] Reference particle in OPAL

opal AT lists.psi.ch

Subject: The OPAL Discussion Forum

List archive

Re: [Opal] Reference particle in OPAL


Chronological Thread  
  • From: Wei Hou Tan <tanweihou AT outlook.com>
  • To: "Adelmann Andreas (PSI)" <andreas.adelmann AT psi.ch>
  • Cc: Nicole R Neveu <nneveu AT stanford.edu>, "opal AT lists.psi.ch" <opal AT lists.psi.ch>
  • Subject: Re: [Opal] Reference particle in OPAL
  • Date: Thu, 28 Jan 2021 19:12:40 +0000
  • Accept-language: en-US
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=M1jev0Pg103wVUgerB9sdeyvmIHuLz90OAq05gp1uZI=; b=ZByCwpI+kbnrSsBfaTG5Zpv7NDCBC7HS+kWKGjtJ9Zq7lHI3JUDXg5WN7Nt9LXGVmsSP4OMGNML6Yc4hd2sI13Tw135XJrmNUn6URLxzGJNsvY4Mg9hWHXW2s2o5ZuK+UAsjRGB0fjm+fSKsMRTS0WXmsc3NYuW3KIAaPO2PcoG+LG88ssp/Q+nSfN+oDzSTOb1WLEIyb2A+bFRVARHwHAmJL+9nulY3S3X/qCDDX9Br+SFrfzZtn7//v7UsVEDYA0hDB2gQZj7LLDSENp14BVPPgLKD7uI753X+K1YFNdAfLm591HO5MzWzkADzxuvLFUUeJC5n3Kfjj5DUbt6dRg==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=TWE2aF9YJ7RvXSnhJ9bLYjI6r/mHWxpIj9UIsyOCdp4+C2/lJQkTd/2GPyINnj1DdR3dxbm2LTgIvxGMyV++77VNPhm9frHtnuZWHJt4HB5RUP4n/B/v9nFMa8g+0BmSXR+yaVn5YPxj3QULQ4dcP2/DycloQ/NxpZcuc2IUg9bWjWhl5m9LJdufh7J7Z7LsfOYWIeaYUkeFoVc0+fQ2talgfplowqq7STBKij45m2dFt8NkzylQBjAyY102NimW47s1eL5zVJvvURitgwFq/ytxd1DWUP2qdjh4gQGGNRVMb+YPsaydhOPNgLrlqIRTClifUyouhIpGvyc+Ons2Iw==
  • Authentication-results: localhost; iprev=pass (mail-oln040092254017.outbound.protection.outlook.com) smtp.remote-ip=40.92.254.17; spf=pass smtp.mailfrom=outlook.com; dkim=pass header.d=outlook.com header.s=selector1 header.a=rsa-sha256; dmarc=pass header.from=outlook.com

Dear Andreas,

Thank you very much for those suggestions.
Regarding space charge, I turned off its calculation for both OPAL and ASTRA.
I set FSTYPE=NONE in OPAL, is this the correct way to turn off space charge calculation ?

FS_SC: Fieldsolver, FSTYPE = NONE,
            MX = 16, MY = 16, MT = 64,
            PARFFTX = true,
            PARFFTY = true,
            PARFFTT = true,
            BCFFTX = open,
            BCFFTY = open,
            BCFFTT = open,
            BBOXINCR = 1,
            GREENSF = INTEGRATED;

Thank you.

Regards
Wei Hou




From: Adelmann Andreas (PSI) <andreas.adelmann AT psi.ch>
Sent: Friday, January 29, 2021 3:01 AM
To: Wei Hou Tan <tanweihou AT outlook.com>
Cc: Nicole R Neveu <nneveu AT stanford.edu>; opal AT lists.psi.ch <opal AT lists.psi.ch>
Subject: Re: [Opal] Reference particle in OPAL
 
Hello Wei Hou, you are reading correctly the h5 file. 

Here a few more thought: 

a) of course I do not know how you run the other code and how the final
distribution is obtained: at a fixed time or at a fixed position. 

b) furthermore what type of emission model does the other code use? 

c) last but not least what is the space charge model that the other code is using.

Given the small differences in the energy spread, these things matters. At some
point if the is important to you we would need to look at the source codes. 

I would also ask the question of the relevance of the difference. 

Hope this helps to unravel the mysteries. 


Cheers A
------
Dr. sc. math. Andreas (Andy) Adelmann
Head a.i. Labor for Scientific Computing and Modelling 
Paul Scherrer Institut OHSA/ CH-5232 Villigen PSI
Phone Office: xx41 56 310 42 33 Fax: xx41 56 310 31 91
Zoom ID: 470-582-4086 Password: AdA
Zoom Link: https://ethz.zoom.us/j/4705824086?pwd=dFcvT1pMMGY0bHg0dTNncUNZZTJkZz09

-------------------------------------------------------
Friday: ETH HPK G 28   +41 44 633 3076
============================================
The more exotic, the more abstract the knowledge, 
the more profound will be its consequences.
Leon Lederman 
============================================

On 28 Jan 2021, at 05:21, Wei Hou Tan <tanweihou AT outlook.com> wrote:

Dear Andreas,

Thank you, unfortunately it still does not work.
Here is how I read the final output distribution from HDF5 file. Is it correct ?

<Screenshot 2021-01-27 222038.jpg>
Thanks.

Regards
Wei Hou

From: Adelmann Andreas (PSI) <andreas.adelmann AT psi.ch>
Sent: Tuesday, January 26, 2021 5:07 AM
To: Wei Hou Tan <tanweihou AT outlook.com>
Cc: Nicole R Neveu <nneveu AT stanford.edu>; opal AT lists.psi.ch <opal AT lists.psi.ch>
Subject: Re: [Opal] Reference particle in OPAL
 
Hello Wei Hou can you change EMISSIONSTEPS = 200, 
to lower values and see if the distribution changes? 
These small changes in dE are maybe caused by slightly 
different emission models. 




Cheers A
------
Dr. sc. math. Andreas (Andy) Adelmann
Head a.i. Labor for Scientific Computing and Modelling 
Paul Scherrer Institut OHSA/ CH-5232 Villigen PSI
Phone Office: xx41 56 310 42 33 Fax: xx41 56 310 31 91
Zoom ID: 470-582-4086 Password: AdA
Zoom Link: https://ethz.zoom.us/j/4705824086?pwd=dFcvT1pMMGY0bHg0dTNncUNZZTJkZz09

-------------------------------------------------------
Friday: ETH HPK G 28   +41 44 633 3076
============================================
The more exotic, the more abstract the knowledge, 
the more profound will be its consequences.
Leon Lederman 
============================================

On 23 Jan 2021, at 15:57, Wei Hou Tan <tanweihou AT outlook.com> wrote:

Hi Andreas,

Thanks for the suggestion, my apology for misunderstanding "energy" in <output>.stat.
It seems like the OPAL and ASTRA agree for the reference particle, but 

My input bunch is quite long, about 90ps full length, and here is my distribution command.

Dist: DISTRIBUTION, TYPE = FROMFILE,
        FNAME = "opal.ini",
        EMISSIONMODEL = NONE,
        EKIN=0,
        EMITTED = True,
        WRITETOFILE=True,
        EMISSIONSTEPS = 200,
        NBIN = 200;

Is there anything wrong with it ?

<Screenshot 2021-01-23 082555.jpg>
<Screenshot 2021-01-23 085210.jpg>

Thanks.

Regards
Wei Hou

From: Adelmann Andreas (PSI) <andreas.adelmann AT psi.ch>
Sent: Saturday, January 23, 2021 4:59 PM
To: Wei Hou Tan <tanweihou AT outlook.com>
Cc: Nicole R Neveu <nneveu AT stanford.edu>; opal AT lists.psi.ch <opal AT lists.psi.ch>
Subject: Re: [Opal] Reference particle in OPAL
 
here you see what type of output you have. 

Consider to plot column 23 (Z-component of normalized momentum of reference particle in floor coordinate system)

Cheers A
------
Dr. sc. math. Andreas (Andy) Adelmann
Head a.i. Labor for Scientific Computing and Modelling 
Paul Scherrer Institut OHSA/ CH-5232 Villigen PSI
Phone Office: xx41 56 310 42 33 Fax: xx41 56 310 31 91
Zoom ID: 470-582-4086 Password: AdA
Zoom Link: https://ethz.zoom.us/j/4705824086?pwd=dFcvT1pMMGY0bHg0dTNncUNZZTJkZz09

-------------------------------------------------------
Friday: ETH HPK G 28   +41 44 633 3076
============================================
The more exotic, the more abstract the knowledge, 
the more profound will be its consequences.
Leon Lederman 
============================================

On 23 Jan 2021, at 00:30, Wei Hou Tan <tanweihou AT outlook.com> wrote:

Dear Nicole,

Thanks for your suggestion.
Unfortunately, it did not help much.
For my example, I did not turn on space charge calculation.
From the plot below, it seems like there is a mismatch in RF phase, as seen by the reference particle.

Is there a way to check which reference particle that OPAL uses for its calculation ? (For ASTRA, it is the bunch centroid)

<dasdasdas.jpg>
Thanks.

Regards
Wei Hou

From: Nicole R Neveu <nneveu AT stanford.edu>
Sent: Saturday, January 23, 2021 6:25 AM
To: Wei Hou Tan <tanweihou AT outlook.com>; opal <opal AT lists.psi.ch>
Subject: Re: [Opal] Reference particle in OPAL
 
Have you tried more emission steps?
I think the default is only ‘1’, and this value was too low for my case.
Here’s my standard distribution:
 
Dist:DISTRIBUTION, TYPE = FROMFILE,
                   FNAME = "opal_emitted.txt",
                   EMITTED = TRUE,
                   EMISSIONMODEL = NONE,
                   EMISSIONSTEPS = 100,
                   EKIN=0;
 
Other things that I needed to adjust were: 
  • Grid size / # particles ratio (maybe you’ve already done a convergence study?)
  • Number of Fourier samples in the field maps (originally I had this number too high)
 
Thanks, 
 
Nicole
 
From: Wei Hou Tan <tanweihou AT outlook.com>
Date: Friday, January 22, 2021 at 2:16 PM
To: Nicole R Neveu <nneveu AT stanford.edu>, opal <opal AT lists.psi.ch>
Subject: Re: [Opal] Reference particle in OPAL
 
Dear Nicole,
 
The distribution was generated by external scripts, which then converted into ASTRA and OPAL inputs.
The distribution comes with initial momentum pz, I did not add extra Ekin as shown in the code below.
 
Here's the distribution command look like
 
Dist: DISTRIBUTION, TYPE = FROMFILE,
        FNAME = "opal.ini",
        EMISSIONMODEL = NONE,
        EKIN=0,
        EMITTED = True,
        WRITETOFILE=True,
        NBIN = 100;
 
Thanks.
 
Regards
Wei Hou

From: Nicole R Neveu <nneveu AT stanford.edu>
Sent: Saturday, January 23, 2021 6:07 AM
To: Wei Hou Tan <tanweihou AT outlook.com>; opal <opal AT lists.psi.ch>
Subject: Re: [Opal] Reference particle in OPAL
 
Hi Wei Hou, 
 
When I did a similar exercise for the LCLS-II injector, one cause of discrepancy for me was the definition of Ekin.
Are you suppling the same particles distribution to ASTRA and OPAL?
Or letting the codes generate the distribution?
What does your distribution command look like?
 
Thanks, 
 
Nicole
 
 
From: <opal-request AT lists.psi.ch> on behalf of Wei Hou Tan <tanweihou AT outlook.com>
Reply-To: Wei Hou Tan <tanweihou AT outlook.com>
Date: Friday, January 22, 2021 at 1:59 PM
To: opal <opal AT lists.psi.ch>
Subject: [Opal] Reference particle in OPAL
 
Dear OPAL developers,
 
This is Wei Hou TAN, graduate student working with Prof. Philippe Piot in the Northern Illinois University.
 
I would like to learn OPAL, starting by cross-checking its results with ASTRA.
 
In my toy example, I simulated a rf gun with both ASTRA and OPAL.
However, I am having problems getting same results in OPAL.
I have checked that both ASTRA and OPAL have the same distributions, same RF phase.
 
I suspected that OPAL has a different definition of reference particle but I could not find any documentations on it.
 
What is OPAL convention of reference particle ?
 
Thank you.
 
Regards
Wei Hou




Archive powered by MHonArc 2.6.19.

Top of Page