source: sasview/sansmodels/docs/sphinx/html/api/FractalCoreShellModel.html @ dcbd084f

ESS_GUIESS_GUI_DocsESS_GUI_batch_fittingESS_GUI_bumps_abstractionESS_GUI_iss1116ESS_GUI_iss879ESS_GUI_iss959ESS_GUI_openclESS_GUI_orderingESS_GUI_sync_sascalccostrafo411magnetic_scattrelease-4.1.1release-4.1.2release-4.2.2release_4.0.1ticket-1009ticket-1094-headlessticket-1242-2d-resolutionticket-1243ticket-1249ticket885unittest-saveload
Last change on this file since dcbd084f was c0d873f, checked in by Gervaise Alina <gervyh@…>, 13 years ago

edit docs for models

  • Property mode set to 100644
File size: 18.2 KB
Line 
1
2
3<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
4  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
5
6
7<html xmlns="http://www.w3.org/1999/xhtml">
8  <head>
9    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
10   
11    <title>FractalCoreShellModel &mdash; sansmodels 0.1.0 documentation</title>
12   
13    <link rel="stylesheet" href="../_static/default.css" type="text/css" />
14    <link rel="stylesheet" href="../_static/pygments.css" type="text/css" />
15   
16    <script type="text/javascript">
17      var DOCUMENTATION_OPTIONS = {
18        URL_ROOT:    '../',
19        VERSION:     '0.1.0',
20        COLLAPSE_INDEX: false,
21        FILE_SUFFIX: '.html',
22        HAS_SOURCE:  true
23      };
24    </script>
25    <script type="text/javascript" src="../_static/jquery.js"></script>
26    <script type="text/javascript" src="../_static/underscore.js"></script>
27    <script type="text/javascript" src="../_static/doctools.js"></script>
28    <link rel="top" title="sansmodels 0.1.0 documentation" href="../index.html" />
29    <link rel="up" title="Reference" href="index.html" />
30    <link rel="next" title="FractalModel" href="FractalModel.html" />
31    <link rel="prev" title="FractalAbsModel" href="FractalAbsModel.html" /> 
32  </head>
33  <body>
34    <div class="related">
35      <h3>Navigation</h3>
36      <ul>
37        <li class="right" style="margin-right: 10px">
38          <a href="../genindex.html" title="General Index"
39             accesskey="I">index</a></li>
40        <li class="right" >
41          <a href="../py-modindex.html" title="Python Module Index"
42             >modules</a> |</li>
43        <li class="right" >
44          <a href="FractalModel.html" title="FractalModel"
45             accesskey="N">next</a> |</li>
46        <li class="right" >
47          <a href="FractalAbsModel.html" title="FractalAbsModel"
48             accesskey="P">previous</a> |</li>
49        <li><a href="../index.html">sansmodels 0.1.0 documentation</a> &raquo;</li>
50          <li><a href="index.html" accesskey="U">Reference</a> &raquo;</li> 
51      </ul>
52    </div> 
53
54    <div class="document">
55      <div class="documentwrapper">
56        <div class="bodywrapper">
57          <div class="body">
58           
59  <div class="section" id="fractalcoreshellmodel">
60<h1>FractalCoreShellModel<a class="headerlink" href="#fractalcoreshellmodel" title="Permalink to this headline">¶</a></h1>
61<div class="section" id="sans-models-fractalcoreshellmodel">
62<h2><a class="reference internal" href="#module-sans.models.FractalCoreShellModel" title="sans.models.FractalCoreShellModel"><tt class="xref py py-mod docutils literal"><span class="pre">sans.models.FractalCoreShellModel</span></tt></a><a class="headerlink" href="#sans-models-fractalcoreshellmodel" title="Permalink to this headline">¶</a></h2>
63<span class="target" id="module-sans.models.FractalCoreShellModel"></span><dl class="class">
64<dt id="sans.models.FractalCoreShellModel.FractalCoreShellModel">
65<em class="property">class </em><tt class="descclassname">sans.models.FractalCoreShellModel.</tt><tt class="descname">FractalCoreShellModel</tt><a class="headerlink" href="#sans.models.FractalCoreShellModel.FractalCoreShellModel" title="Permalink to this definition">¶</a></dt>
66<dd><p>Bases: <a class="reference internal" href="BaseComponent.html#sans.models.BaseComponent.BaseComponent" title="sans.models.BaseComponent.BaseComponent"><tt class="xref py py-class docutils literal"><span class="pre">sans.models.BaseComponent.BaseComponent</span></tt></a></p>
67<p>Class that evaluates a FractalCoreShellModel
68List of default parameters:
69volfraction     = 0.05
70radius          = 20.0 [A]
71thickness       = 5.0 [A]
72frac_dim        = 2.0
73cor_length      = 100 [A]
74core_sld        = 3.5e-006 [1/A^(2)]
75shell_sld       = 1.0e-006 [1/A^(2)]
76solvent_sld     = 6.35e-006 [1/A^(2)]
77background      = 0.0 [1/cm]</p>
78<dl class="method">
79<dt id="sans.models.FractalCoreShellModel.FractalCoreShellModel.__add__">
80<tt class="descname">__add__</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.FractalCoreShellModel.FractalCoreShellModel.__add__" title="Permalink to this definition">¶</a></dt>
81<dd></dd></dl>
82
83<dl class="method">
84<dt id="sans.models.FractalCoreShellModel.FractalCoreShellModel.__div__">
85<tt class="descname">__div__</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.FractalCoreShellModel.FractalCoreShellModel.__div__" title="Permalink to this definition">¶</a></dt>
86<dd></dd></dl>
87
88<dl class="method">
89<dt id="sans.models.FractalCoreShellModel.FractalCoreShellModel.__init__">
90<tt class="descname">__init__</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.FractalCoreShellModel.FractalCoreShellModel.__init__" title="Permalink to this definition">¶</a></dt>
91<dd></dd></dl>
92
93<dl class="attribute">
94<dt id="sans.models.FractalCoreShellModel.FractalCoreShellModel.__module__">
95<tt class="descname">__module__</tt><em class="property"> = 'sans.models.FractalCoreShellModel'</em><a class="headerlink" href="#sans.models.FractalCoreShellModel.FractalCoreShellModel.__module__" title="Permalink to this definition">¶</a></dt>
96<dd></dd></dl>
97
98<dl class="method">
99<dt id="sans.models.FractalCoreShellModel.FractalCoreShellModel.__mul__">
100<tt class="descname">__mul__</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.FractalCoreShellModel.FractalCoreShellModel.__mul__" title="Permalink to this definition">¶</a></dt>
101<dd></dd></dl>
102
103<dl class="method">
104<dt id="sans.models.FractalCoreShellModel.FractalCoreShellModel.__str__">
105<tt class="descname">__str__</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.FractalCoreShellModel.FractalCoreShellModel.__str__" title="Permalink to this definition">¶</a></dt>
106<dd><table class="docutils field-list" frame="void" rules="none">
107<col class="field-name" />
108<col class="field-body" />
109<tbody valign="top">
110<tr class="field-odd field"><th class="field-name">Returns:</th><td class="field-body">string representatio</td>
111</tr>
112</tbody>
113</table>
114</dd></dl>
115
116<dl class="method">
117<dt id="sans.models.FractalCoreShellModel.FractalCoreShellModel.__sub__">
118<tt class="descname">__sub__</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.FractalCoreShellModel.FractalCoreShellModel.__sub__" title="Permalink to this definition">¶</a></dt>
119<dd></dd></dl>
120
121<dl class="method">
122<dt id="sans.models.FractalCoreShellModel.FractalCoreShellModel._clone">
123<tt class="descname">_clone</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.FractalCoreShellModel.FractalCoreShellModel._clone" title="Permalink to this definition">¶</a></dt>
124<dd><p>Internal utility function to copy the internal
125data members to a fresh copy.</p>
126</dd></dl>
127
128<dl class="method">
129<dt id="sans.models.FractalCoreShellModel.FractalCoreShellModel._fractalcore">
130<tt class="descname">_fractalcore</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.FractalCoreShellModel.FractalCoreShellModel._fractalcore" title="Permalink to this definition">¶</a></dt>
131<dd><p>Define model function</p>
132<p>return S(q): Fractal Structure</p>
133</dd></dl>
134
135<dl class="method">
136<dt id="sans.models.FractalCoreShellModel.FractalCoreShellModel._setParamHelper">
137<tt class="descname">_setParamHelper</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.FractalCoreShellModel.FractalCoreShellModel._setParamHelper" title="Permalink to this definition">¶</a></dt>
138<dd><p>Helper function to setParam</p>
139</dd></dl>
140
141<dl class="method">
142<dt id="sans.models.FractalCoreShellModel.FractalCoreShellModel._set_details">
143<tt class="descname">_set_details</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.FractalCoreShellModel.FractalCoreShellModel._set_details" title="Permalink to this definition">¶</a></dt>
144<dd><p>Concatenate details of the original model to create
145this model details</p>
146</dd></dl>
147
148<dl class="method">
149<dt id="sans.models.FractalCoreShellModel.FractalCoreShellModel._set_dispersion">
150<tt class="descname">_set_dispersion</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.FractalCoreShellModel.FractalCoreShellModel._set_dispersion" title="Permalink to this definition">¶</a></dt>
151<dd><p>model dispersions</p>
152</dd></dl>
153
154<dl class="method">
155<dt id="sans.models.FractalCoreShellModel.FractalCoreShellModel._set_params">
156<tt class="descname">_set_params</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.FractalCoreShellModel.FractalCoreShellModel._set_params" title="Permalink to this definition">¶</a></dt>
157<dd><p>Concatenate the parameters of the model to create
158this model parameters</p>
159</dd></dl>
160
161<dl class="method">
162<dt id="sans.models.FractalCoreShellModel.FractalCoreShellModel.calculate_ER">
163<tt class="descname">calculate_ER</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.FractalCoreShellModel.FractalCoreShellModel.calculate_ER" title="Permalink to this definition">¶</a></dt>
164<dd></dd></dl>
165
166<dl class="method">
167<dt id="sans.models.FractalCoreShellModel.FractalCoreShellModel.clone">
168<tt class="descname">clone</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.FractalCoreShellModel.FractalCoreShellModel.clone" title="Permalink to this definition">¶</a></dt>
169<dd><p>Returns a new object identical to the current object</p>
170</dd></dl>
171
172<dl class="method">
173<dt id="sans.models.FractalCoreShellModel.FractalCoreShellModel.evalDistribution">
174<tt class="descname">evalDistribution</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.FractalCoreShellModel.FractalCoreShellModel.evalDistribution" title="Permalink to this definition">¶</a></dt>
175<dd><p>Evaluate a distribution of q-values.</p>
176<ul>
177<li><p class="first">For 1D, a numpy array is expected as input:</p>
178<blockquote>
179<div><p>evalDistribution(q)</p>
180</div></blockquote>
181</li>
182</ul>
183<p>where q is a numpy array.</p>
184<ul class="simple">
185<li>For 2D, a list of numpy arrays are expected: [qx_prime,qy_prime],
186where 1D arrays,</li>
187</ul>
188<p>qx_prime = [ qx[0], qx[1], qx[2], ....]
189and
190qy_prime = [ qy[0], qy[1], qy[2], ....]</p>
191<p>Then get
192q = numpy.sqrt(qx_prime^2+qy_prime^2)</p>
193<p>that is a qr in 1D array;
194q = [q[0], q[1], q[2], ....]</p>
195<table class="docutils field-list" frame="void" rules="none">
196<col class="field-name" />
197<col class="field-body" />
198<tbody valign="top">
199<tr class="field-odd field"><th class="field-name">Note :</th><td class="field-body"><p class="first">Due to 2D speed issue, no anisotropic scattering
200is supported for python models, thus C-models should have</p>
201<blockquote class="last">
202<div><p>their own evalDistribution methods.</p>
203</div></blockquote>
204</td>
205</tr>
206</tbody>
207</table>
208<p>The method is then called the following way:</p>
209<p>evalDistribution(q)
210where q is a numpy array.</p>
211<table class="docutils field-list" frame="void" rules="none">
212<col class="field-name" />
213<col class="field-body" />
214<tbody valign="top">
215<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>qdist</strong> &#8211; ndarray of scalar q-values or list [qx,qy]
216where qx,qy are 1D ndarrays</td>
217</tr>
218</tbody>
219</table>
220</dd></dl>
221
222<dl class="method">
223<dt id="sans.models.FractalCoreShellModel.FractalCoreShellModel.getDispParamList">
224<tt class="descname">getDispParamList</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.FractalCoreShellModel.FractalCoreShellModel.getDispParamList" title="Permalink to this definition">¶</a></dt>
225<dd><p>Return a list of all available parameters for the model</p>
226</dd></dl>
227
228<dl class="method">
229<dt id="sans.models.FractalCoreShellModel.FractalCoreShellModel.getParam">
230<tt class="descname">getParam</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.FractalCoreShellModel.FractalCoreShellModel.getParam" title="Permalink to this definition">¶</a></dt>
231<dd><p>Set the value of a model parameter</p>
232<table class="docutils field-list" frame="void" rules="none">
233<col class="field-name" />
234<col class="field-body" />
235<tbody valign="top">
236<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>name</strong> &#8211; name of the parameter</td>
237</tr>
238</tbody>
239</table>
240</dd></dl>
241
242<dl class="method">
243<dt id="sans.models.FractalCoreShellModel.FractalCoreShellModel.getParamList">
244<tt class="descname">getParamList</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.FractalCoreShellModel.FractalCoreShellModel.getParamList" title="Permalink to this definition">¶</a></dt>
245<dd><p>Return a list of all available parameters for the model</p>
246</dd></dl>
247
248<dl class="method">
249<dt id="sans.models.FractalCoreShellModel.FractalCoreShellModel.getParamListWithToken">
250<tt class="descname">getParamListWithToken</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.FractalCoreShellModel.FractalCoreShellModel.getParamListWithToken" title="Permalink to this definition">¶</a></dt>
251<dd></dd></dl>
252
253<dl class="method">
254<dt id="sans.models.FractalCoreShellModel.FractalCoreShellModel.getParamWithToken">
255<tt class="descname">getParamWithToken</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.FractalCoreShellModel.FractalCoreShellModel.getParamWithToken" title="Permalink to this definition">¶</a></dt>
256<dd></dd></dl>
257
258<dl class="method">
259<dt id="sans.models.FractalCoreShellModel.FractalCoreShellModel.is_fittable">
260<tt class="descname">is_fittable</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.FractalCoreShellModel.FractalCoreShellModel.is_fittable" title="Permalink to this definition">¶</a></dt>
261<dd><p>Check if a given parameter is fittable or not</p>
262<table class="docutils field-list" frame="void" rules="none">
263<col class="field-name" />
264<col class="field-body" />
265<tbody valign="top">
266<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>par_name</strong> &#8211; the parameter name to check</td>
267</tr>
268</tbody>
269</table>
270</dd></dl>
271
272<dl class="method">
273<dt id="sans.models.FractalCoreShellModel.FractalCoreShellModel.run">
274<tt class="descname">run</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.FractalCoreShellModel.FractalCoreShellModel.run" title="Permalink to this definition">¶</a></dt>
275<dd><p>Evaluate the model</p>
276<p>: param x: input q-value (float or [float, float] as [r, theta])
277: return: (DAB value)</p>
278</dd></dl>
279
280<dl class="method">
281<dt id="sans.models.FractalCoreShellModel.FractalCoreShellModel.runXY">
282<tt class="descname">runXY</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.FractalCoreShellModel.FractalCoreShellModel.runXY" title="Permalink to this definition">¶</a></dt>
283<dd><p>Evaluate the model</p>
284<p>: param x: input q-value (float or [float, float] as [qx, qy])
285: return: DAB value</p>
286</dd></dl>
287
288<dl class="method">
289<dt id="sans.models.FractalCoreShellModel.FractalCoreShellModel.setParam">
290<tt class="descname">setParam</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.FractalCoreShellModel.FractalCoreShellModel.setParam" title="Permalink to this definition">¶</a></dt>
291<dd><p>Set the value of a model parameter</p>
292<p>: param name: name of the parameter
293: param value: value of the parameter</p>
294</dd></dl>
295
296<dl class="method">
297<dt id="sans.models.FractalCoreShellModel.FractalCoreShellModel.setParamWithToken">
298<tt class="descname">setParamWithToken</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.FractalCoreShellModel.FractalCoreShellModel.setParamWithToken" title="Permalink to this definition">¶</a></dt>
299<dd></dd></dl>
300
301<dl class="method">
302<dt id="sans.models.FractalCoreShellModel.FractalCoreShellModel.set_dispersion">
303<tt class="descname">set_dispersion</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.FractalCoreShellModel.FractalCoreShellModel.set_dispersion" title="Permalink to this definition">¶</a></dt>
304<dd><p>Set the dispersion object for a model parameter</p>
305<p>: param parameter: name of the parameter [string]
306:dispersion: dispersion object of type DispersionModel</p>
307</dd></dl>
308
309</dd></dl>
310
311</div>
312</div>
313
314
315          </div>
316        </div>
317      </div>
318      <div class="sphinxsidebar">
319        <div class="sphinxsidebarwrapper">
320  <h3><a href="../index.html">Table Of Contents</a></h3>
321  <ul>
322<li><a class="reference internal" href="#">FractalCoreShellModel</a><ul>
323<li><a class="reference internal" href="#sans-models-fractalcoreshellmodel"><tt class="docutils literal"><span class="pre">sans.models.FractalCoreShellModel</span></tt></a></li>
324</ul>
325</li>
326</ul>
327
328  <h4>Previous topic</h4>
329  <p class="topless"><a href="FractalAbsModel.html"
330                        title="previous chapter">FractalAbsModel</a></p>
331  <h4>Next topic</h4>
332  <p class="topless"><a href="FractalModel.html"
333                        title="next chapter">FractalModel</a></p>
334  <h3>This Page</h3>
335  <ul class="this-page-menu">
336    <li><a href="../_sources/api/FractalCoreShellModel.txt"
337           rel="nofollow">Show Source</a></li>
338  </ul>
339<div id="searchbox" style="display: none">
340  <h3>Quick search</h3>
341    <form class="search" action="../search.html" method="get">
342      <input type="text" name="q" />
343      <input type="submit" value="Go" />
344      <input type="hidden" name="check_keywords" value="yes" />
345      <input type="hidden" name="area" value="default" />
346    </form>
347    <p class="searchtip" style="font-size: 90%">
348    Enter search terms or a module, class or function name.
349    </p>
350</div>
351<script type="text/javascript">$('#searchbox').show(0);</script>
352        </div>
353      </div>
354      <div class="clearer"></div>
355    </div>
356    <div class="related">
357      <h3>Navigation</h3>
358      <ul>
359        <li class="right" style="margin-right: 10px">
360          <a href="../genindex.html" title="General Index"
361             >index</a></li>
362        <li class="right" >
363          <a href="../py-modindex.html" title="Python Module Index"
364             >modules</a> |</li>
365        <li class="right" >
366          <a href="FractalModel.html" title="FractalModel"
367             >next</a> |</li>
368        <li class="right" >
369          <a href="FractalAbsModel.html" title="FractalAbsModel"
370             >previous</a> |</li>
371        <li><a href="../index.html">sansmodels 0.1.0 documentation</a> &raquo;</li>
372          <li><a href="index.html" >Reference</a> &raquo;</li> 
373      </ul>
374    </div>
375    <div class="footer">
376        &copy; Copyright 2010, sans group.
377      Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.
378    </div>
379  </body>
380</html>
Note: See TracBrowser for help on using the repository browser.