Changeset a807206 in sasmodels for sasmodels/models/mono_gauss_coil.py
- Timestamp:
- Oct 1, 2016 12:42:06 AM (8 years ago)
- Branches:
- master, core_shell_microgels, costrafo411, magnetic_model, release_v0.94, release_v0.95, ticket-1257-vesicle-product, ticket_1156, ticket_1265_superball, ticket_822_more_unit_tests
- Children:
- caddb14, 5031ca3
- Parents:
- 2222134
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sasmodels/models/mono_gauss_coil.py
r40a87fa ra807206 71 71 parameters = [ 72 72 ["i_zero", "1/cm", 70.0, [0.0, inf], "", "Intensity at q=0"], 73 ["r adius_gyration", "Ang", 75.0, [0.0, inf], "", "Radius of gyration"],73 ["rg", "Ang", 75.0, [0.0, inf], "", "Radius of gyration"], 74 74 ] 75 75 # pylint: enable=bad-whitespace, line-too-long 76 76 77 77 # NB: Scale and Background are implicit parameters on every model 78 def Iq(q, i_zero, r adius_gyration):78 def Iq(q, i_zero, rg): 79 79 # pylint: disable = missing-docstring 80 z = (q * r adius_gyration)**280 z = (q * rg)**2 81 81 82 82 with errstate(invalid='ignore'): … … 86 86 Iq.vectorized = True # Iq accepts an array of q values 87 87 88 demo = dict(scale=1.0, i_zero=70.0, r adius_gyration=75.0, background=0.0)88 demo = dict(scale=1.0, i_zero=70.0, rg=75.0, background=0.0) 89 89 90 90 # these unit test values taken from SasView 3.1.2 91 91 tests = [ 92 [{'scale': 1.0, 'i_zero': 70.0, 'r adius_gyration': 75.0, 'background': 0.0},92 [{'scale': 1.0, 'i_zero': 70.0, 'rg': 75.0, 'background': 0.0}, 93 93 [0.0106939, 0.469418], [57.1241, 0.112859]], 94 94 ]
Note: See TracChangeset
for help on using the changeset viewer.