<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
<html>
Yes, there is a solution to use an experimental profile for the simulation
source.
<p>First position a normal source (Source_flat or Source_gen, or ...).
<br>Then, you may use the Filter_gen component (in the optics) to read
the contents a a file, with options="lambda, set weight". Then the first
column of the table is assumed to be the wavelength, and the second should
be the flux to set.
<br>A rebinning/interpolation is done when loading the table. This will
set the weight of neutrons. You may also choose to multiply or add to the
existing weight.
<br>The Filter_gen (McStas v1.7) is a replacement to the old Flux_adapter.
<p>Just look at the MCSTASLIB/optics/Filter_gen component (or 'mcdoc Filter_gen').
<p>pwilk wrote:
<blockquote TYPE=CITE><span class=633424313-26082003><font face="Arial"><font color="#0000FF"><font size=-1>Thanks
for the quick reply! I'll give that a go.I think you are right about the
zero velocity neutrons.</span><span class=633424313-26082003></span><span class=633424313-26082003>I
have another quick question for you: </span><span class=633424313-26082003>Is
there an easy way to simulate a source from a 2D file of (measured) Intensity
vs. Wavelength ?</span><span class=633424313-26082003></span><span class=633424313-26082003>Cheers,</span><span class=633424313-26082003>Philip</font></font></font></span>
<blockquote
style="PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #0000ff 2px solid; MARGIN-RIGHT: 0px">
<div class="OutlookMessageHeader" lang="en-us" dir="ltr"><font face="Tahoma"><font size=-1>-----Original
Message-----</font></font>
<br><font face="Tahoma"><font size=-1><b>From:</b> farhi@ill.fr [<A HREF="mailto:farhi@ill.fr">mailto:farhi@ill.fr</A>]</font></font>
<br><font face="Tahoma"><font size=-1><b>Sent:</b> Tuesday, August 26,
2003 3:18 PM</font></font>
<br><font face="Tahoma"><font size=-1><b>To:</b> pwilk-radiochem@hahnium.com;
neutron-mc@risoe.dk</font></font>
<br><font face="Tahoma"><font size=-1><b>Subject:</b> Re: sqrt: DOMAIN
error</font></font></div>
Hy Philip,
<p>You probably have some zero velocity neutrons or such huge velocities
that the square gets hawfull (before getting the sqrt), else I can not
figure out how the 'sqrt' can fail in the speed in L_monitor.comp.
<br>You may copy this component locally and change the line #76 so that
it tests the speed norm to be non zero or reasonable value (not huge).
<p>You may also try replacing with the Monitor_nD(options="auto lambda",
filename="...")
<p>Cheers, Emmanuel.
<p>Philip Wilk wrote:
<blockquote TYPE="CITE">Hi,
<p>I am using the new version 1.7
<p>I keep getting "sqrt: DOMAIN error"
<p>Just like I was getting with version 1.6.4 , should I be worried about
this?
<br>It seems to be associated with the wavelength detector component.
<p>See example output:
<p>Detector: psd_begin_I=75.9887 psd_begin_ERR=0.0701353
<br>psd_begin_N=3.65191e+06 "p
<br>sd1.dat"
<br>Detector: lambda_begin_I=75.9887 lambda_begin_ERR=0.0701353
<br>lambda_begin_N=3.651
<br>91e+06 "erg1.dat"
<br>Detector: psd_middle_I=6.2552 psd_middle_ERR=0.017862
<br>psd_middle_N=1.68387e+06 "
<br>psd2.dat"
<p>sqrt: DOMAIN error
<br>Detector: lambda_middle_I=6.2552 lambda_middle_ERR=0.017862
<br>lambda_middle_N=1.68
<br>387e+06 "erg2.dat"
<br>Detector: psd_middle2_I=1.20321 psd_middle2_ERR=0.00418768
<br>psd_middle2_N=1.08584
<br>e+06 "psd3.dat"
<br>Detector: lambda_middle2_I=1.20321 lambda_middle2_ERR=0.00418768
<br>lambda_middle2_
<br>N=1.08584e+06 "erg3.dat"
<br>Detector: psd_end_I=0.65266 psd_end_ERR=0.002805 psd_end_N=389221 "psd4.dat"
<br>Detector: lambda_end_I=0.65266 lambda_end_ERR=0.002805 lambda_end_N=389221
<br>"erg4
<br>.dat"
<p>Cheers,
<br>Philip</blockquote>
<pre>--
What's up Doc ?
--------------------------------------------
Emmanuel FARHI, <a href="http://www.ill.fr/tas/people/Farhi.html">http://www.ill.fr/tas/people/Farhi.html</a> \|/ ____ \|/
CS-Group ILL4/156, Institut Laue-Langevin (ILL) Grenoble ~@-/ oO \-@~
6 rue J. Horowitz, BP 156, 38042 Grenoble Cedex 9,France /_( \__/ )_\
Work :Tel (33/0) 4 76 20 71 35. Fax (33/0) 4 76 20 76 48 \__U_/</pre>
</blockquote>
</blockquote>
<pre>--
What's up Doc ?
--------------------------------------------
Emmanuel FARHI, <A HREF="http://www.ill.fr/tas/people/Farhi.html">http://www.ill.fr/tas/people/Farhi.html</A> \|/ ____ \|/
CS-Group ILL4/156, Institut Laue-Langevin (ILL) Grenoble ~@-/ oO \-@~
6 rue J. Horowitz, BP 156, 38042 Grenoble Cedex 9,France /_( \__/ )_\
Work :Tel (33/0) 4 76 20 71 35. Fax (33/0) 4 76 20 76 48 \__U_/</pre>
</html>