<div dir="ltr"><div dir="ltr">Hi all,</div><div dir="ltr"><br><div> I am interested in how many reflection happened with one guide_gravity component. I am able to printf() the number of bounces (<i>nbounces</i>) in the EXTEND section after the guide_gravity. But the monitor_nD component is not giving any data. It outputs only zeros. And on the "variables" line in the output file it shows "I I_err N"</div><div><br></div><div> <b> COMPONENT UserMonitor = Monitor_nD(</b></div><div><b><span style="white-space:pre"> </span>user1 = nbounces,</b></div><div><b><span style="white-space:pre"> </span>username1 = "Number of bounces",</b></div><div><b><span style="white-space:pre"> </span>options = "auto user1")</b></div><div><b> AT(......)</b></div><div><b><br></b></div><div><b> </b> How should I use the Monitor_nD component for displaying the number of bounces in the guide?</div><div><br></div><div>Sincerely,</div><div>Lingnan Shen</div></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Sat, Feb 9, 2019 at 5:44 PM Markus Appel <<a href="mailto:masolomaster3000@googlemail.com">masolomaster3000@googlemail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Hi,<br>
"it didn't work" is kind of a vague error to work with, but on first<br>
glance your problem might be that the nbounces variable is not reset in<br>
the TRACE section, it will just keep counting up through the simulation.<br>
<br>
Check again the example in the manual, there is an Arm component before<br>
the guide with an EXTEND that sets nbounces=0 for each iteration.<br>
<br>
Best,<br>
Markus<br>
<br>
On 09/02/2019 22:56, Lingnan Shen wrote:<br>
> Hi all,<br>
> <br>
> I now have my reflectivity file working and I'm trying to<br>
> understand how many reflections happened in the guide. I followed the<br>
> example in the component manual in the end of section 9.8.7. It didn't<br>
> work. I attached the .instr and .rfl file to this email.<br>
> Thanks for all the great help.<br>
> <br>
> Sincerely,<br>
> Lingnan Shen<br>
> <br>
> On Sat, Feb 9, 2019 at 2:42 AM Kim Lefmann <<a href="mailto:lefmann@nbi.ku.dk" target="_blank">lefmann@nbi.ku.dk</a><br>
> <mailto:<a href="mailto:lefmann@nbi.ku.dk" target="_blank">lefmann@nbi.ku.dk</a>>> wrote:<br>
> <br>
> Hi Shen,<br>
> <br>
> It is also my understanding that the k value is the momentum transfer.<br>
> <br>
> Sorry, I do not have the time to look into you problem now.<br>
> <br>
> best, Kim<br>
> <br>
> <br>
> On 2/7/19 4:53 PM, <a href="mailto:ls8vm@virginia.edu" target="_blank">ls8vm@virginia.edu</a> <mailto:<a href="mailto:ls8vm@virginia.edu" target="_blank">ls8vm@virginia.edu</a>> wrote:<br>
>><br>
>> Hi all,____<br>
>><br>
>> __ __<br>
>><br>
>> I checked the supermirror_m3.rfl file and it ranges<br>
>> from 0 to 0.09 [Angs-1] so I’m really confused with the k value in<br>
>> the first column of reflectivity file. I thought it represent the<br>
>> total momentum transferred. Can you explain more on “better the k<br>
>> values in the reflectivity file to be around e.g. 1.0 Angs-1.”<br>
>> Does the guide_gravity component have a different definition on<br>
>> reflectivity file? My actual source wavelength ranges from 0 to 10<br>
>> [Angs].____<br>
>><br>
>> __ __<br>
>><br>
>> And also for Peter, my actual problem is to optimize a polarizer<br>
>> which is built by stack of supermirror. I’m trying to find a way<br>
>> to get the most transmission through that setup. So I want to<br>
>> calculate the ratio neutron_out/neutron_in. Now it seems that I<br>
>> should just divide the intensity instead of event numbers?____<br>
>><br>
>> __ __<br>
>><br>
>> __ __<br>
>><br>
>> Happy Lunar New Year,____<br>
>><br>
>> Lingnan Shen____<br>
>><br>
>> __ __<br>
>><br>
>> *From: *Peter Kjær Willendrup <mailto:<a href="mailto:pkwi@fysik.dtu.dk" target="_blank">pkwi@fysik.dtu.dk</a>><br>
>> *Sent: *Tuesday, February 5, 2019 4:20 AM<br>
>> *To: *Lingnan Shen <mailto:<a href="mailto:ls8vm@virginia.edu" target="_blank">ls8vm@virginia.edu</a>><br>
>> *Cc: *Emmanuel Farhi <mailto:<a href="mailto:farhi@ill.fr" target="_blank">farhi@ill.fr</a>><br>
>> *Subject: *Re: [mcstas-users] Guide_gravity Problem<br>
>><br>
>> __ __<br>
>><br>
>> Hello again, ____<br>
>><br>
>> __ __<br>
>><br>
>> __ __<br>
>><br>
>> A better starting point for understanding Guide_gravity and<br>
>> reflectivity files may be the instrument file Test_Guides which is<br>
>> included with your McStas installation, in combination with one of<br>
>> the example reflectivity files from the data folder - e.g.<br>
>> supermirror_m3.rdl.____<br>
>><br>
>> __ __<br>
>><br>
>> Also, for a pencil beam with controllable divergence, an option is<br>
>> to use Source_div.____<br>
>><br>
>> __ __<br>
>><br>
>> Hope this helps - otherwise you are welcome to write again,<br>
>> preferably with a good description of what exact problem you are<br>
>> trying to solve. :-)____<br>
>><br>
>> __ __<br>
>><br>
>> Best,____<br>
>><br>
>> __ __<br>
>><br>
>> Peter____<br>
>><br>
>><br>
>><br>
>> ____<br>
>><br>
>> On 5 Feb 2019, at 10.12, Peter Kjær Willendrup<br>
>> <<a href="mailto:pkwi@fysik.dtu.dk" target="_blank">pkwi@fysik.dtu.dk</a> <mailto:<a href="mailto:pkwi@fysik.dtu.dk" target="_blank">pkwi@fysik.dtu.dk</a>>> wrote:____<br>
>><br>
>> __ __<br>
>><br>
>> Hello Lingnan, ____<br>
>><br>
>> __ __<br>
>><br>
>> __ __<br>
>><br>
>> Agree with Emmanuel. ____<br>
>><br>
>> __ __<br>
>><br>
>> Further, the combination of a pencil-beam, i.e. almost<br>
>> non-divergent source and using 500 channels in a rotated<br>
>> Guide_gravity means that transport through the guide becomes<br>
>> close to impossible. ____<br>
>><br>
>> __ __<br>
>><br>
>> With regard to your second question you should always consider<br>
>> the transported intensity I. The event count is simply a<br>
>> measure of statistics (of "neutron rays", not “neutrons”).____<br>
>><br>
>> __ __<br>
>><br>
>> __ __<br>
>><br>
>> Best,____<br>
>><br>
>> __ __<br>
>><br>
>> Peter Willendrup____<br>
>><br>
>> __ __<br>
>><br>
>> __ __<br>
>><br>
>> On 5 Feb 2019, at 10.01, Emmanuel FARHI <<a href="mailto:farhi@ill.fr" target="_blank">farhi@ill.fr</a><br>
>> <mailto:<a href="mailto:farhi@ill.fr" target="_blank">farhi@ill.fr</a>>> wrote:____<br>
>><br>
>> __ __<br>
>><br>
>> Hello Lingnan,<br>
>><br>
>> Your reflectivity file is given for k=0 to 0.14 Angs-1.<br>
>> This is very small and covers neutrons around lambda=60<br>
>> Angs, which are not even created by your source. Change<br>
>> either the lambda setting at the source, or better the k<br>
>> values in the reflectivity file to be around e.g. 1.0 Angs-1.<br>
>><br>
>> Cheers, Emmanuel.<br>
>><br>
>> __ __<br>
>><br>
>> On 2/5/19 7:17 AM, Lingnan Shen wrote:____<br>
>><br>
>> Hi all, ____<br>
>><br>
>> __ __<br>
>><br>
>> I was trying to learn how to use the<br>
>> guide_gravity component. I tried to define the<br>
>> reflectivity curve but I get zero neutrons at the<br>
>> wavelength monitor in the end of guide. I have<br>
>> attached my .instr and .rfl file. I also found that<br>
>> even if the neutron beam just go through the guide.<br>
>> The detector at the end still see nothing.____<br>
>><br>
>> Also another question about transmission of<br>
>> certain setup. To calculate the ratio of neutron_in /<br>
>> neutron_out. I want to know how much neutron remained<br>
>> after passing through that setup. Should I use the<br>
>> flux or the events count?____<br>
>><br>
>> __ __<br>
>><br>
>> Sincerely,____<br>
>><br>
>> Lingnan Shen____<br>
>><br>
>><br>
>><br>
>> ____<br>
>><br>
>> _______________________________________________<br>
>><br>
>> mcstas-users mailing list<br>
>><br>
>> <a href="mailto:mcstas-users@mcstas.org" target="_blank">mcstas-users@mcstas.org</a> <mailto:<a href="mailto:mcstas-users@mcstas.org" target="_blank">mcstas-users@mcstas.org</a>><br>
>><br>
>> <a href="https://mailman2.mcstas.org/mailman/listinfo/mcstas-users" rel="noreferrer" target="_blank">https://mailman2.mcstas.org/mailman/listinfo/mcstas-users</a><br>
>><br>
>> -- <br>
>><br>
>> Emmanuel FARHI, \|/ ____ \|/<br>
>><br>
>> Spectroscopy Group Institut Laue-Langevin (ILL) Grenoble ~@-/ oO \-@~<br>
>><br>
>> 71 av des Martyrs,CS 20156,38042 Grenoble Cedex 9,France /_( \__/ )_\<br>
>><br>
>> Work :Tel (33/0) 4 76 20 71 35. Fax (33/0) 4 76 48 39 06 \__U_/ <br>
>><br>
>> _______________________________________________<br>
>> mcstas-users mailing list<br>
>> <a href="mailto:mcstas-users@mcstas.org" target="_blank">mcstas-users@mcstas.org</a> <mailto:<a href="mailto:mcstas-users@mcstas.org" target="_blank">mcstas-users@mcstas.org</a>><br>
>> <a href="https://mailman2.mcstas.org/mailman/listinfo/mcstas-users____" rel="noreferrer" target="_blank">https://mailman2.mcstas.org/mailman/listinfo/mcstas-users____</a><br>
>><br>
>> __ __<br>
>><br>
>><br>
>> Peter Kjær Willendrup<br>
>> Forskningsingeniør, Specialkonsulent<br>
>> Næstformand for DTU Fysik LSU<br>
>><br>
>> DTU Physics____<br>
>><br>
>><br>
>> <image001.gif><br>
>><br>
>><br>
>> Technical University of Denmark<br>
>><br>
>><br>
>> <image002.gif><br>
>><br>
>><br>
>><br>
>> Department of Physics<br>
>> Fysikvej<br>
>> Building 307<br>
>> DK-2800 Kongens Lyngby<br>
>> Direct +45 2125 4612<br>
>> Mobil +45 2125 4612<br>
>> Fax +45 4593 2399<br>
>> <a href="mailto:pkwi@fysik.dtu.dk" target="_blank">pkwi@fysik.dtu.dk</a> <mailto:<a href="mailto:pkwi@fysik.dtu.dk" target="_blank">pkwi@fysik.dtu.dk</a>> ____<br>
>><br>
>> __ __<br>
>><br>
>> __ __<br>
>><br>
>><br>
>> Peter Kjær Willendrup<br>
>> Forskningsingeniør, Specialkonsulent<br>
>> Næstformand for DTU Fysik LSU<br>
>><br>
>> DTU Physics____<br>
>><br>
>><br>
>> <a href="mailto:cid%3Ab6339554-7f28-441d-9f31-5944f811397c@win.dtu.dk" target="_blank">cid:b6339554-7f28-441d-9f31-5944f811397c@win.dtu.dk</a><br>
>><br>
>><br>
>> Technical University of Denmark<br>
>><br>
>><br>
>> <a href="mailto:cid%3Ae108e480-fcab-46e2-9531-b38165079572@win.dtu.dk" target="_blank">cid:e108e480-fcab-46e2-9531-b38165079572@win.dtu.dk</a><br>
>><br>
>><br>
>><br>
>> Department of Physics<br>
>> Fysikvej<br>
>> Building 307<br>
>> DK-2800 Kongens Lyngby<br>
>> Direct +45 2125 4612<br>
>> Mobil +45 2125 4612<br>
>> Fax +45 4593 2399<br>
>> <a href="mailto:pkwi@fysik.dtu.dk" target="_blank">pkwi@fysik.dtu.dk</a> <mailto:<a href="mailto:pkwi@fysik.dtu.dk" target="_blank">pkwi@fysik.dtu.dk</a>> ____<br>
>><br>
>> __ __<br>
>><br>
>> __ __<br>
>><br>
>><br>
>> _______________________________________________<br>
>> mcstas-users mailing list<br>
>> <a href="mailto:mcstas-users@mcstas.org" target="_blank">mcstas-users@mcstas.org</a> <mailto:<a href="mailto:mcstas-users@mcstas.org" target="_blank">mcstas-users@mcstas.org</a>><br>
>> <a href="https://mailman2.mcstas.org/mailman/listinfo/mcstas-users" rel="noreferrer" target="_blank">https://mailman2.mcstas.org/mailman/listinfo/mcstas-users</a><br>
> _______________________________________________<br>
> mcstas-users mailing list<br>
> <a href="mailto:mcstas-users@mcstas.org" target="_blank">mcstas-users@mcstas.org</a> <mailto:<a href="mailto:mcstas-users@mcstas.org" target="_blank">mcstas-users@mcstas.org</a>><br>
> <a href="https://mailman2.mcstas.org/mailman/listinfo/mcstas-users" rel="noreferrer" target="_blank">https://mailman2.mcstas.org/mailman/listinfo/mcstas-users</a><br>
> <br>
> <br>
> _______________________________________________<br>
> mcstas-users mailing list<br>
> <a href="mailto:mcstas-users@mcstas.org" target="_blank">mcstas-users@mcstas.org</a><br>
> <a href="https://mailman2.mcstas.org/mailman/listinfo/mcstas-users" rel="noreferrer" target="_blank">https://mailman2.mcstas.org/mailman/listinfo/mcstas-users</a><br>
> <br>
<br>
</blockquote></div>