[c6ca41e] | 1 | r""" |
---|
| 2 | Definition |
---|
| 3 | ---------- |
---|
| 4 | |
---|
| 5 | This model is a trivial extension of the core_shell_sphere function to include |
---|
| 6 | *N* shells where the core is filled with solvent and the shells are interleaved |
---|
| 7 | with layers of solvent. For *N = 1*, this returns the same as the vesicle model. |
---|
| 8 | The shell thicknessess and SLD are constant across all shells as expected for |
---|
| 9 | a multilayer vesicle. |
---|
| 10 | |
---|
| 11 | .. figure:: img/multi_shell_geometry.jpg |
---|
| 12 | |
---|
| 13 | Geometry of the multilayer_vesicle model. |
---|
| 14 | |
---|
[9f60c06] | 15 | See the :ref:`core-shell-sphere` model for more documentation. |
---|
[c6ca41e] | 16 | |
---|
| 17 | The 2D scattering intensity is the same as 1D, regardless of the orientation |
---|
| 18 | of the q vector which is defined as: |
---|
| 19 | |
---|
| 20 | .. math:: |
---|
| 21 | |
---|
| 22 | q = \sqrt{q_x^2 + q_y^2} |
---|
| 23 | |
---|
| 24 | .. note: |
---|
| 25 | The outer most radius |
---|
| 26 | $radius + n_pairs * thicn_shell + (n_pairs - 1) * thick_solvent$ |
---|
| 27 | is used as the effective radius for *S(Q)* when $P(Q) * S(Q)$ is applied. |
---|
| 28 | |
---|
[40a87fa] | 29 | For information about polarised and magnetic scattering, see |
---|
[9a4811a] | 30 | the :ref:`magnetism` documentation. |
---|
[c6ca41e] | 31 | |
---|
| 32 | This code is based on the form factor calculations implemented in the NIST |
---|
| 33 | Center for Neutron Research provided c-library (Kline, 2006). |
---|
| 34 | |
---|
| 35 | References |
---|
| 36 | ---------- |
---|
| 37 | |
---|
| 38 | B Cabane, *Small Angle Scattering Methods*, |
---|
| 39 | in *Surfactant Solutions: New Methods of Investigation*, |
---|
| 40 | Ch.2, Surfactant Science Series Vol. 22, Ed. R Zana and M Dekker, |
---|
| 41 | New York, (1987). |
---|
| 42 | |
---|
| 43 | **Author:** NIST IGOR/DANSE **on:** pre 2010 |
---|
| 44 | |
---|
| 45 | **Last Modified by:** Piotr Rozyczko**on:** Feb 24, 2016 |
---|
| 46 | |
---|
| 47 | **Last Reviewed by:** Paul Butler **on:** March 20, 2016 |
---|
| 48 | |
---|
| 49 | """ |
---|
| 50 | |
---|
| 51 | from numpy import inf |
---|
| 52 | |
---|
| 53 | name = "multilayer_vesicle" |
---|
| 54 | title = "P(Q) for a Multi-lamellar vesicle" |
---|
| 55 | description = """ |
---|
| 56 | multilayer_vesicle model parameters; |
---|
| 57 | scale : scale factor for abs intensity if needed else 1.0 |
---|
| 58 | volfraction: volume fraction |
---|
| 59 | radius : Core radius of the multishell |
---|
| 60 | thick_shell: shell thickness |
---|
| 61 | thick_solvent: water thickness |
---|
| 62 | sld_solvent: solvent scattering length density |
---|
| 63 | sld: shell scattering length density |
---|
| 64 | n_pairs:number of pairs of water/shell |
---|
| 65 | background: incoherent background |
---|
| 66 | """ |
---|
| 67 | category = "shape:sphere" |
---|
| 68 | |
---|
| 69 | # pylint: disable=bad-whitespace, line-too-long |
---|
| 70 | # ["name", "units", default, [lower, upper], "type","description"], |
---|
| 71 | parameters = [ |
---|
| 72 | ["volfraction", "", 0.05, [0.0, 1], "", "volume fraction of vesicles"], |
---|
| 73 | ["radius", "Ang", 60.0, [0.0, inf], "", "Core radius of the multishell"], |
---|
[f67f26c] | 74 | ["thick_shell", "Ang", 10.0, [0.0, inf], "", "Shell thickness"], |
---|
[c6ca41e] | 75 | ["thick_solvent", "Ang", 10.0, [0.0, inf], "", "Water thickness"], |
---|
[42356c8] | 76 | ["sld_solvent", "1e-6/Ang^2", 6.4, [-inf, inf], "sld", "Core scattering length density"], |
---|
| 77 | ["sld", "1e-6/Ang^2", 0.4, [-inf, inf], "sld", "Shell scattering length density"], |
---|
[c6ca41e] | 78 | ["n_pairs", "", 2.0, [1.0, inf], "", "Number of pairs of water and shell"], |
---|
| 79 | ] |
---|
| 80 | # pylint: enable=bad-whitespace, line-too-long |
---|
| 81 | |
---|
| 82 | source = ["lib/sph_j1c.c", "multilayer_vesicle.c"] |
---|
| 83 | |
---|
| 84 | polydispersity = ["radius", "n_pairs"] |
---|
| 85 | |
---|
| 86 | demo = dict(scale=1, background=0, |
---|
| 87 | volfraction=0.05, |
---|
| 88 | radius=60.0, |
---|
| 89 | thick_shell=10.0, |
---|
| 90 | thick_solvent=10.0, |
---|
| 91 | sld_solvent=6.4, |
---|
| 92 | sld=0.4, |
---|
| 93 | n_pairs=2.0) |
---|
| 94 | |
---|
| 95 | tests = [ |
---|
| 96 | # Accuracy tests based on content in test/utest_other_models.py |
---|
| 97 | [{'radius': 60.0, |
---|
| 98 | 'thick_shell': 10.0, |
---|
| 99 | 'thick_solvent': 10.0, |
---|
| 100 | 'sld_solvent': 6.4, |
---|
| 101 | 'sld': 0.4, |
---|
| 102 | 'n_pairs': 2.0, |
---|
| 103 | 'scale': 1.0, |
---|
| 104 | 'background': 0.001, |
---|
| 105 | }, 0.001, 122.1405], |
---|
| 106 | |
---|
| 107 | [{'volfraction': 1.0, |
---|
| 108 | 'radius': 60.0, |
---|
| 109 | 'thick_shell': 10.0, |
---|
| 110 | 'thick_solvent': 10.0, |
---|
| 111 | 'sld_solvent': 6.4, |
---|
| 112 | 'sld': 0.4, |
---|
| 113 | 'n_pairs': 2.0, |
---|
| 114 | 'scale': 1.0, |
---|
| 115 | 'background': 0.001, |
---|
| 116 | }, (0.001, 0.30903), 1.61873], |
---|
| 117 | ] |
---|