Changeset 404ebbd in sasmodels for sasmodels/models/poly_gauss_coil.py
- Timestamp:
- Jul 30, 2017 12:56:22 AM (7 years ago)
- Branches:
- master, core_shell_microgels, costrafo411, magnetic_model, ticket-1257-vesicle-product, ticket_1156, ticket_1265_superball, ticket_822_more_unit_tests
- Children:
- 48462b0
- Parents:
- a151caa
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sasmodels/models/poly_gauss_coil.py
r3330bb4 r404ebbd 66 66 67 67 description = """ 68 Evaluates the scattering from 68 Evaluates the scattering from 69 69 polydisperse polymer chains. 70 70 """ … … 96 96 p = [ 97 97 #(-1 - 20*u - 155*u**2 - 580*u**3 - 1044*u**4 - 720*u**5) / 2520., 98 #( 98 #(+1 + 14*u + 71*u**2 + 154*u**3 + 120*u**4) / 360., 99 99 #(-1 - 9*u - 26*u**2 - 24*u**3) / 60., 100 ( 100 (+1 + 5*u + 6*u**2) / 12., 101 101 (-1 - 2*u) / 3., 102 ( 1),102 (+1), 103 103 ] 104 104 result = 2.0 * (power(1.0 + u*z, -1.0/u) + z - 1.0) / (1.0 + u) … … 108 108 return i_zero * result 109 109 Iq.vectorized = True # Iq accepts an array of q values 110 111 def random(): 112 import numpy as np 113 rg = 10**np.random.uniform(0, 4) 114 #rg = 1e3 115 polydispersity = 10**np.random.uniform(0, 3) 116 pars = dict( 117 #scale=1, background=0, 118 i_zero=1e7, # i_zero is a simple scale 119 rg=rg, 120 polydispersity=polydispersity, 121 ) 122 return pars 110 123 111 124 demo = dict(scale=1.0,
Note: See TracChangeset
for help on using the changeset viewer.