1 | r""" |
---|
2 | |
---|
3 | This model provides the form factor, $P(q)$, for a micelle with a spherical |
---|
4 | core and Gaussian polymer chains attached to the surface, thus may be applied |
---|
5 | to block copolymer micelles. To work well the Gaussian chains must be much |
---|
6 | smaller than the core, which is often not the case. Please study the |
---|
7 | reference carefully. |
---|
8 | |
---|
9 | Definition |
---|
10 | ---------- |
---|
11 | |
---|
12 | The 1D scattering intensity for this model is calculated according to |
---|
13 | the equations given by Pedersen (Pedersen, 2000), summarised briefly here. |
---|
14 | |
---|
15 | The micelle core is imagined as $N$ = *n_aggreg* polymer heads, each of volume |
---|
16 | $V_\text{core}$, which then defines a micelle core of radius $r$ = *r_core*, |
---|
17 | which is a separate parameter even though it could be directly determined. |
---|
18 | The Gaussian random coil tails, of gyration radius $R_g$, are imagined |
---|
19 | uniformly distributed around the spherical core, centred at a distance |
---|
20 | $r + d \cdot R_g$ from the micelle centre, where $d$ = *d_penetration* is |
---|
21 | of order unity. A volume $V_\text{corona}$ is defined for each coil. The |
---|
22 | model in detail seems to separately parametrise the terms for the shape |
---|
23 | of $I(Q)$ and the relative intensity of each term, so use with caution |
---|
24 | and check parameters for consistency. The spherical core is monodisperse, |
---|
25 | so it's intensity and the cross terms may have sharp oscillations (use $q$ |
---|
26 | resolution smearing if needs be to help remove them). |
---|
27 | |
---|
28 | .. math:: |
---|
29 | P(q) &= N^2\beta^2_s\Phi(qr)^2 + N\beta^2_cP_c(q) |
---|
30 | + 2N^2\beta_s\beta_cS_{sc}(q) + N(N-1)\beta_c^2S_{cc}(q) \\ |
---|
31 | \beta_s &= V_\text{core}(\rho_\text{core} - \rho_\text{solvent}) \\ |
---|
32 | \beta_c &= V_\text{corona}(\rho_\text{corona} - \rho_\text{solvent}) |
---|
33 | |
---|
34 | where $\rho_\text{core}$, $\rho_\text{corona}$ and $\rho_\text{solvent}$ are |
---|
35 | the scattering length densities *sld_core*, *sld_corona* and *sld_solvent*. |
---|
36 | For the spherical core of radius $r$ |
---|
37 | |
---|
38 | .. math:: |
---|
39 | \Phi(qr)= \frac{\sin(qr) - qr\cos(qr)}{(qr)^3} |
---|
40 | |
---|
41 | whilst for the Gaussian coils |
---|
42 | |
---|
43 | .. math:: |
---|
44 | |
---|
45 | P_c(q) &= 2 [\exp(-Z) + Z - 1] / Z^2 \\ |
---|
46 | Z &= (q R_g)^2 |
---|
47 | |
---|
48 | The sphere to coil (core to corona) and coil to coil (corona to corona) cross |
---|
49 | terms are approximated by: |
---|
50 | |
---|
51 | .. math:: |
---|
52 | |
---|
53 | S_{sc}(q) &= \Phi(qr)\psi(Z) |
---|
54 | \frac{\sin(q(r+d \cdot R_g))}{q(r+d \cdot R_g)} \\ |
---|
55 | S_{cc}(q) &= \psi(Z)^2 |
---|
56 | \left[\frac{\sin(q(r+d \cdot R_g))}{q(r+d \cdot R_g)} \right]^2 \\ |
---|
57 | \psi(Z) &= \frac{[1-\exp^{-Z}]}{Z} |
---|
58 | |
---|
59 | Validation |
---|
60 | ---------- |
---|
61 | |
---|
62 | $P(q)$ above is multiplied by *ndensity*, and a units conversion of $10^{-13}$, |
---|
63 | so *scale* is likely 1.0 if the scattering data is in absolute units. This |
---|
64 | model has not yet been independently validated. |
---|
65 | |
---|
66 | |
---|
67 | References |
---|
68 | ---------- |
---|
69 | |
---|
70 | J Pedersen, *J. Appl. Cryst.*, 33 (2000) 637-640 |
---|
71 | """ |
---|
72 | |
---|
73 | import numpy as np |
---|
74 | from numpy import inf, pi |
---|
75 | |
---|
76 | name = "polymer_micelle" |
---|
77 | title = "Polymer micelle model" |
---|
78 | description = """ |
---|
79 | This model provides the form factor, $P(q)$, for a micelle with a spherical |
---|
80 | core and Gaussian polymer chains attached to the surface, thus may be applied |
---|
81 | to block copolymer micelles. To work well the Gaussian chains must be much |
---|
82 | smaller than the core, which is often not the case. Please study the |
---|
83 | reference to Pedersen and full documentation carefully. |
---|
84 | """ |
---|
85 | |
---|
86 | |
---|
87 | category = "shape:sphere" |
---|
88 | |
---|
89 | # pylint: disable=bad-whitespace, line-too-long |
---|
90 | # ["name", "units", default, [lower, upper], "type","description"], |
---|
91 | parameters = [ |
---|
92 | ["ndensity", "1e15/cm^3", 8.94, [0.0, inf], "", "Number density of micelles"], |
---|
93 | ["v_core", "Ang^3", 62624.0, [0.0, inf], "", "Core volume "], |
---|
94 | ["v_corona", "Ang^3", 61940.0, [0.0, inf], "", "Corona volume"], |
---|
95 | ["sld_solvent", "1e-6/Ang^2", 6.4, [0.0, inf], "sld", "Solvent scattering length density"], |
---|
96 | ["sld_core", "1e-6/Ang^2", 0.34, [0.0, inf], "sld", "Core scattering length density"], |
---|
97 | ["sld_corona", "1e-6/Ang^2", 0.8, [0.0, inf], "sld", "Corona scattering length density"], |
---|
98 | ["radius_core", "Ang", 45.0, [0.0, inf], "", "Radius of core ( must be >> rg )"], |
---|
99 | ["rg", "Ang", 20.0, [0.0, inf], "", "Radius of gyration of chains in corona"], |
---|
100 | ["d_penetration", "", 1.0, [-inf, inf], "", "Factor to mimic non-penetration of Gaussian chains"], |
---|
101 | ["n_aggreg", "", 6.0, [-inf, inf], "", "Aggregation number of the micelle"], |
---|
102 | ] |
---|
103 | # pylint: enable=bad-whitespace, line-too-long |
---|
104 | |
---|
105 | single = False |
---|
106 | |
---|
107 | source = ["lib/sas_3j1x_x.c", "polymer_micelle.c"] |
---|
108 | |
---|
109 | def random(): |
---|
110 | radius_core = 10**np.random.uniform(1, 3) |
---|
111 | rg = radius_core * 10**np.random.uniform(-2, -0.3) |
---|
112 | d_penetration = np.random.randn()*0.05 + 1 |
---|
113 | n_aggreg = np.random.randint(3, 30) |
---|
114 | # volume of head groups is the core volume over the number of groups, |
---|
115 | # with a correction for packing fraction of the head groups. |
---|
116 | v_core = 4*pi/3*radius_core**3/n_aggreg * 0.68 |
---|
117 | # Rg^2 for gaussian coil is a^2n/6 => a^2 = 6 Rg^2/n |
---|
118 | # a=2r => r = Rg sqrt(3/2n) |
---|
119 | # v = 4/3 pi r^3 n => v = 4/3 pi Rg^3 (3/2n)^(3/2) n = pi Rg^3 sqrt(6/n) |
---|
120 | tail_segments = np.random.randint(6, 30) |
---|
121 | v_corona = pi * rg**3 * np.sqrt(6/tail_segments) |
---|
122 | V = 4*pi/3*(radius_core + rg)**3 |
---|
123 | pars = dict( |
---|
124 | background=0, |
---|
125 | scale=1e7/V, |
---|
126 | ndensity=8.94, |
---|
127 | v_core=v_core, |
---|
128 | v_corona=v_corona, |
---|
129 | radius_core=radius_core, |
---|
130 | rg=rg, |
---|
131 | d_penetration=d_penetration, |
---|
132 | n_aggreg=n_aggreg, |
---|
133 | ) |
---|
134 | return pars |
---|
135 | |
---|
136 | tests = [ |
---|
137 | [{}, 0.01, 15.3532], |
---|
138 | ] |
---|
139 | # RKH 20Mar2016 - need to check whether the core & corona volumes are per |
---|
140 | # monomer ??? and how aggregation number works! |
---|
141 | # renamed from micelle_spherical_core to polymer_micelle, |
---|
142 | # moved from shape-independent to spheres section. |
---|
143 | # Ought to be able to add polydisp to core? And add ability to x by S(Q) ? |
---|