source: sasview/sansmodels/docs/sphinx/html/api/BEPolyelectrolyte.html @ 01de557

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 01de557 was c0d873f, checked in by Gervaise Alina <gervyh@…>, 13 years ago

edit docs for models

  • Property mode set to 100644
File size: 16.9 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>BEPolyelectrolyte &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="BinaryHSModel" href="BinaryHSModel.html" />
31    <link rel="prev" title="BCCrystalModel" href="BCCrystalModel.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="BinaryHSModel.html" title="BinaryHSModel"
45             accesskey="N">next</a> |</li>
46        <li class="right" >
47          <a href="BCCrystalModel.html" title="BCCrystalModel"
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="bepolyelectrolyte">
60<h1>BEPolyelectrolyte<a class="headerlink" href="#bepolyelectrolyte" title="Permalink to this headline">¶</a></h1>
61<div class="section" id="sans-models-bepolyelectrolyte">
62<h2><a class="reference internal" href="#module-sans.models.BEPolyelectrolyte" title="sans.models.BEPolyelectrolyte"><tt class="xref py py-mod docutils literal"><span class="pre">sans.models.BEPolyelectrolyte</span></tt></a><a class="headerlink" href="#sans-models-bepolyelectrolyte" title="Permalink to this headline">¶</a></h2>
63<span class="target" id="module-sans.models.BEPolyelectrolyte"></span><p>Provide F(x) = K*1/(4*pi*Lb*(alpha)^(2))*(q^(2)+k2)/(1+(r02)^(2))*(q^(2)+k2)                       <a href="#id1"><span class="problematic" id="id2">*</span></a>(q^(2)-(12*h*C/b^(2)))
64BEPolyelectrolyte as a BaseComponent model</p>
65<dl class="class">
66<dt id="sans.models.BEPolyelectrolyte.BEPolyelectrolyte">
67<em class="property">class </em><tt class="descclassname">sans.models.BEPolyelectrolyte.</tt><tt class="descname">BEPolyelectrolyte</tt><a class="headerlink" href="#sans.models.BEPolyelectrolyte.BEPolyelectrolyte" title="Permalink to this definition">¶</a></dt>
68<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>
69<p>Class that evaluates a BEPolyelectrolyte.</p>
70<p>F(x) = K*1/(4*pi*Lb*(alpha)^(2))*(q^(2)+k2)/(1+(r02)^(2))*(q^(2)+k2)                       <a href="#id3"><span class="problematic" id="id4">*</span></a>(q^(2)-(12*h*C/b^(2)))</p>
71<dl class="docutils">
72<dt>The model has Eight parameters: </dt>
73<dd>K        =  Constrast factor of the polymer
74Lb       =  Bjerrum length
75H        =  virial parameter
76B        =  monomer length
77Cs       =  Concentration of monovalent salt
78alpha    =  ionazation degree
79C        = polymer molar concentration
80bkd      = background</dd>
81</dl>
82<dl class="method">
83<dt id="sans.models.BEPolyelectrolyte.BEPolyelectrolyte._BEPoly">
84<tt class="descname">_BEPoly</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.BEPolyelectrolyte.BEPolyelectrolyte._BEPoly" title="Permalink to this definition">¶</a></dt>
85<dd><p>Evaluate 
86F(x) = K*1/(4*pi*Lb*(alpha)^(2))*(q^(2)+k2)/(1+(r02)^(2))</p>
87<blockquote>
88<div><a href="#id5"><span class="problematic" id="id6">*</span></a>(q^(2)+k2)*(q^(2)-(12*h*C/b^(2)))</div></blockquote>
89<dl class="docutils">
90<dt>has 3 internal parameters :</dt>
91<dd>The inverse Debye Length: K2 = 4*pi*Lb*(2*Cs+alpha*C)
92r02 =1/alpha/Ca^(0.5)*(B/(48*pi*Lb)^(0.5))
93Ca = C*6.022136e-4</dd>
94</dl>
95</dd></dl>
96
97<dl class="method">
98<dt id="sans.models.BEPolyelectrolyte.BEPolyelectrolyte.__add__">
99<tt class="descname">__add__</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.BEPolyelectrolyte.BEPolyelectrolyte.__add__" title="Permalink to this definition">¶</a></dt>
100<dd></dd></dl>
101
102<dl class="method">
103<dt id="sans.models.BEPolyelectrolyte.BEPolyelectrolyte.__div__">
104<tt class="descname">__div__</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.BEPolyelectrolyte.BEPolyelectrolyte.__div__" title="Permalink to this definition">¶</a></dt>
105<dd></dd></dl>
106
107<dl class="method">
108<dt id="sans.models.BEPolyelectrolyte.BEPolyelectrolyte.__init__">
109<tt class="descname">__init__</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.BEPolyelectrolyte.BEPolyelectrolyte.__init__" title="Permalink to this definition">¶</a></dt>
110<dd><p>Initialization</p>
111</dd></dl>
112
113<dl class="attribute">
114<dt id="sans.models.BEPolyelectrolyte.BEPolyelectrolyte.__module__">
115<tt class="descname">__module__</tt><em class="property"> = 'sans.models.BEPolyelectrolyte'</em><a class="headerlink" href="#sans.models.BEPolyelectrolyte.BEPolyelectrolyte.__module__" title="Permalink to this definition">¶</a></dt>
116<dd></dd></dl>
117
118<dl class="method">
119<dt id="sans.models.BEPolyelectrolyte.BEPolyelectrolyte.__mul__">
120<tt class="descname">__mul__</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.BEPolyelectrolyte.BEPolyelectrolyte.__mul__" title="Permalink to this definition">¶</a></dt>
121<dd></dd></dl>
122
123<dl class="method">
124<dt id="sans.models.BEPolyelectrolyte.BEPolyelectrolyte.__str__">
125<tt class="descname">__str__</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.BEPolyelectrolyte.BEPolyelectrolyte.__str__" title="Permalink to this definition">¶</a></dt>
126<dd><table class="docutils field-list" frame="void" rules="none">
127<col class="field-name" />
128<col class="field-body" />
129<tbody valign="top">
130<tr class="field-odd field"><th class="field-name">Returns:</th><td class="field-body">string representatio</td>
131</tr>
132</tbody>
133</table>
134</dd></dl>
135
136<dl class="method">
137<dt id="sans.models.BEPolyelectrolyte.BEPolyelectrolyte.__sub__">
138<tt class="descname">__sub__</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.BEPolyelectrolyte.BEPolyelectrolyte.__sub__" title="Permalink to this definition">¶</a></dt>
139<dd></dd></dl>
140
141<dl class="method">
142<dt id="sans.models.BEPolyelectrolyte.BEPolyelectrolyte._clone">
143<tt class="descname">_clone</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.BEPolyelectrolyte.BEPolyelectrolyte._clone" title="Permalink to this definition">¶</a></dt>
144<dd><p>Internal utility function to copy the internal
145data members to a fresh copy.</p>
146</dd></dl>
147
148<dl class="method">
149<dt id="sans.models.BEPolyelectrolyte.BEPolyelectrolyte.calculate_ER">
150<tt class="descname">calculate_ER</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.BEPolyelectrolyte.BEPolyelectrolyte.calculate_ER" title="Permalink to this definition">¶</a></dt>
151<dd></dd></dl>
152
153<dl class="method">
154<dt id="sans.models.BEPolyelectrolyte.BEPolyelectrolyte.clone">
155<tt class="descname">clone</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.BEPolyelectrolyte.BEPolyelectrolyte.clone" title="Permalink to this definition">¶</a></dt>
156<dd><p>Returns a new object identical to the current object</p>
157</dd></dl>
158
159<dl class="method">
160<dt id="sans.models.BEPolyelectrolyte.BEPolyelectrolyte.evalDistribution">
161<tt class="descname">evalDistribution</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.BEPolyelectrolyte.BEPolyelectrolyte.evalDistribution" title="Permalink to this definition">¶</a></dt>
162<dd><p>Evaluate a distribution of q-values.</p>
163<ul>
164<li><p class="first">For 1D, a numpy array is expected as input:</p>
165<blockquote>
166<div><p>evalDistribution(q)</p>
167</div></blockquote>
168</li>
169</ul>
170<p>where q is a numpy array.</p>
171<ul class="simple">
172<li>For 2D, a list of numpy arrays are expected: [qx_prime,qy_prime],
173where 1D arrays,</li>
174</ul>
175<p>qx_prime = [ qx[0], qx[1], qx[2], ....]
176and
177qy_prime = [ qy[0], qy[1], qy[2], ....]</p>
178<p>Then get
179q = numpy.sqrt(qx_prime^2+qy_prime^2)</p>
180<p>that is a qr in 1D array;
181q = [q[0], q[1], q[2], ....]</p>
182<table class="docutils field-list" frame="void" rules="none">
183<col class="field-name" />
184<col class="field-body" />
185<tbody valign="top">
186<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
187is supported for python models, thus C-models should have</p>
188<blockquote class="last">
189<div><p>their own evalDistribution methods.</p>
190</div></blockquote>
191</td>
192</tr>
193</tbody>
194</table>
195<p>The method is then called the following way:</p>
196<p>evalDistribution(q)
197where q is a numpy array.</p>
198<table class="docutils field-list" frame="void" rules="none">
199<col class="field-name" />
200<col class="field-body" />
201<tbody valign="top">
202<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]
203where qx,qy are 1D ndarrays</td>
204</tr>
205</tbody>
206</table>
207</dd></dl>
208
209<dl class="method">
210<dt id="sans.models.BEPolyelectrolyte.BEPolyelectrolyte.getDispParamList">
211<tt class="descname">getDispParamList</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.BEPolyelectrolyte.BEPolyelectrolyte.getDispParamList" title="Permalink to this definition">¶</a></dt>
212<dd><p>Return a list of all available parameters for the model</p>
213</dd></dl>
214
215<dl class="method">
216<dt id="sans.models.BEPolyelectrolyte.BEPolyelectrolyte.getParam">
217<tt class="descname">getParam</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.BEPolyelectrolyte.BEPolyelectrolyte.getParam" title="Permalink to this definition">¶</a></dt>
218<dd><p>Set the value of a model parameter</p>
219<table class="docutils field-list" frame="void" rules="none">
220<col class="field-name" />
221<col class="field-body" />
222<tbody valign="top">
223<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>name</strong> &#8211; name of the parameter</td>
224</tr>
225</tbody>
226</table>
227</dd></dl>
228
229<dl class="method">
230<dt id="sans.models.BEPolyelectrolyte.BEPolyelectrolyte.getParamList">
231<tt class="descname">getParamList</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.BEPolyelectrolyte.BEPolyelectrolyte.getParamList" title="Permalink to this definition">¶</a></dt>
232<dd><p>Return a list of all available parameters for the model</p>
233</dd></dl>
234
235<dl class="method">
236<dt id="sans.models.BEPolyelectrolyte.BEPolyelectrolyte.getParamListWithToken">
237<tt class="descname">getParamListWithToken</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.BEPolyelectrolyte.BEPolyelectrolyte.getParamListWithToken" title="Permalink to this definition">¶</a></dt>
238<dd></dd></dl>
239
240<dl class="method">
241<dt id="sans.models.BEPolyelectrolyte.BEPolyelectrolyte.getParamWithToken">
242<tt class="descname">getParamWithToken</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.BEPolyelectrolyte.BEPolyelectrolyte.getParamWithToken" title="Permalink to this definition">¶</a></dt>
243<dd></dd></dl>
244
245<dl class="method">
246<dt id="sans.models.BEPolyelectrolyte.BEPolyelectrolyte.is_fittable">
247<tt class="descname">is_fittable</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.BEPolyelectrolyte.BEPolyelectrolyte.is_fittable" title="Permalink to this definition">¶</a></dt>
248<dd><p>Check if a given parameter is fittable or not</p>
249<table class="docutils field-list" frame="void" rules="none">
250<col class="field-name" />
251<col class="field-body" />
252<tbody valign="top">
253<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>
254</tr>
255</tbody>
256</table>
257</dd></dl>
258
259<dl class="method">
260<dt id="sans.models.BEPolyelectrolyte.BEPolyelectrolyte.run">
261<tt class="descname">run</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.BEPolyelectrolyte.BEPolyelectrolyte.run" title="Permalink to this definition">¶</a></dt>
262<dd><p>Evaluate the model
263&#64;param x: input q-value (float or [float, float] as [r, theta])
264&#64;return: (debye value)</p>
265</dd></dl>
266
267<dl class="method">
268<dt id="sans.models.BEPolyelectrolyte.BEPolyelectrolyte.runXY">
269<tt class="descname">runXY</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.BEPolyelectrolyte.BEPolyelectrolyte.runXY" title="Permalink to this definition">¶</a></dt>
270<dd><p>Evaluate the model
271&#64;param x: input q-value (float or [float, float] as [qx, qy])
272&#64;return: debye value</p>
273</dd></dl>
274
275<dl class="method">
276<dt id="sans.models.BEPolyelectrolyte.BEPolyelectrolyte.setParam">
277<tt class="descname">setParam</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.BEPolyelectrolyte.BEPolyelectrolyte.setParam" title="Permalink to this definition">¶</a></dt>
278<dd><p>Set the value of a model parameter</p>
279<table class="docutils field-list" frame="void" rules="none">
280<col class="field-name" />
281<col class="field-body" />
282<tbody valign="top">
283<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
284<li><strong>name</strong> &#8211; name of the parameter</li>
285<li><strong>value</strong> &#8211; value of the parameter</li>
286</ul>
287</td>
288</tr>
289</tbody>
290</table>
291</dd></dl>
292
293<dl class="method">
294<dt id="sans.models.BEPolyelectrolyte.BEPolyelectrolyte.setParamWithToken">
295<tt class="descname">setParamWithToken</tt><big>(</big><big>)</big><a class="headerlink" href="#sans.models.BEPolyelectrolyte.BEPolyelectrolyte.setParamWithToken" title="Permalink to this definition">¶</a></dt>
296<dd></dd></dl>
297
298</dd></dl>
299
300</div>
301</div>
302
303
304          </div>
305        </div>
306      </div>
307      <div class="sphinxsidebar">
308        <div class="sphinxsidebarwrapper">
309  <h3><a href="../index.html">Table Of Contents</a></h3>
310  <ul>
311<li><a class="reference internal" href="#">BEPolyelectrolyte</a><ul>
312<li><a class="reference internal" href="#sans-models-bepolyelectrolyte"><tt class="docutils literal"><span class="pre">sans.models.BEPolyelectrolyte</span></tt></a></li>
313</ul>
314</li>
315</ul>
316
317  <h4>Previous topic</h4>
318  <p class="topless"><a href="BCCrystalModel.html"
319                        title="previous chapter">BCCrystalModel</a></p>
320  <h4>Next topic</h4>
321  <p class="topless"><a href="BinaryHSModel.html"
322                        title="next chapter">BinaryHSModel</a></p>
323  <h3>This Page</h3>
324  <ul class="this-page-menu">
325    <li><a href="../_sources/api/BEPolyelectrolyte.txt"
326           rel="nofollow">Show Source</a></li>
327  </ul>
328<div id="searchbox" style="display: none">
329  <h3>Quick search</h3>
330    <form class="search" action="../search.html" method="get">
331      <input type="text" name="q" />
332      <input type="submit" value="Go" />
333      <input type="hidden" name="check_keywords" value="yes" />
334      <input type="hidden" name="area" value="default" />
335    </form>
336    <p class="searchtip" style="font-size: 90%">
337    Enter search terms or a module, class or function name.
338    </p>
339</div>
340<script type="text/javascript">$('#searchbox').show(0);</script>
341        </div>
342      </div>
343      <div class="clearer"></div>
344    </div>
345    <div class="related">
346      <h3>Navigation</h3>
347      <ul>
348        <li class="right" style="margin-right: 10px">
349          <a href="../genindex.html" title="General Index"
350             >index</a></li>
351        <li class="right" >
352          <a href="../py-modindex.html" title="Python Module Index"
353             >modules</a> |</li>
354        <li class="right" >
355          <a href="BinaryHSModel.html" title="BinaryHSModel"
356             >next</a> |</li>
357        <li class="right" >
358          <a href="BCCrystalModel.html" title="BCCrystalModel"
359             >previous</a> |</li>
360        <li><a href="../index.html">sansmodels 0.1.0 documentation</a> &raquo;</li>
361          <li><a href="index.html" >Reference</a> &raquo;</li> 
362      </ul>
363    </div>
364    <div class="footer">
365        &copy; Copyright 2010, sans group.
366      Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.
367    </div>
368  </body>
369</html>
Note: See TracBrowser for help on using the repository browser.