Changes in / [502c7b8:01c8d9e] in sasmodels


Ignore:
Files:
5 deleted
3 edited

Legend:

Unmodified
Added
Removed
  • doc/guide/pd/polydispersity.rst

    rd712a0f r29afc50  
    2020  P(q) = \text{scale} \langle F^* F \rangle / V + \text{background} 
    2121 
    22 where $F$ is the scattering amplitude and $\langle\cdot\rangle$ denotes an  
    23 average over the size distribution $f(x; \bar x, \sigma)$, giving 
    24  
    25 .. math:: 
    26  
    27   P(q) = \frac{\text{scale}}{V} \int_\mathbb{R}  
    28   f(x; \bar x, \sigma) F^2(q, x)\, dx + \text{background} 
     22where $F$ is the scattering amplitude and $\langle\cdot\rangle$ denotes an 
     23average over the size distribution. 
    2924 
    3025Each distribution is characterized by a center value $\bar x$ or 
     
    4641with larger values of $N_\sigma$ required for heavier tailed distributions. 
    4742The scattering in general falls rapidly with $qr$ so the usual assumption 
    48 that $f(r - 3\sigma_r)$ is tiny and therefore $f(r - 3\sigma_r)f(r - 3\sigma_r)$ 
     43that $G(r - 3\sigma_r)$ is tiny and therefore $f(r - 3\sigma_r)G(r - 3\sigma_r)$ 
    4944will not contribute much to the average may not hold when particles are large. 
    5045This, too, will require increasing $N_\sigma$. 
     
    6863 
    6964Additional distributions are under consideration. 
    70  
    71 .. note:: In 2009 IUPAC decided to introduce the new term 'dispersity' to replace  
    72            the term 'polydispersity' (see `Pure Appl. Chem., (2009), 81(2),  
    73            351-353 <http://media.iupac.org/publications/pac/2009/pdf/8102x0351.pdf>`_  
    74            in order to make the terminology describing distributions of properties  
    75            unambiguous. Throughout the SasView documentation we continue to use the  
    76            term polydispersity because one of the consequences of the IUPAC change is  
    77            that orientational polydispersity would not meet their new criteria (which  
    78            requires dispersity to be dimensionless). 
    7965 
    8066Suggested Applications 
  • explore/beta/sasfit_compare.py

    r01c8d9e r01c8d9e  
    11from __future__ import division, print_function 
    22# Make sasmodels available on the path 
    3 import sys, os 
     3import sys,os 
    44BETA_DIR = os.path.dirname(os.path.realpath(__file__)) 
    55#SASMODELS_DIR = os.path.dirname(os.path.dirname(BETA_DIR)) 
    66SASMODELS_DIR = r"C:\Source\sasmodels" 
    77sys.path.insert(0, SASMODELS_DIR) 
    8  
     8import os 
    99from collections import namedtuple 
    1010 
     
    223223    if radius_effective is None: 
    224224        radius_effective = radius_eff/total_weight 
     225    print("this is the effective radius for pure python",radius_effective) 
    225226    if norm == 'sasfit': 
    226227        IQD = F2 
     
    231232        #     = F2/total_weight / total_volume/total_weight 
    232233        #     = F2/total_volume 
     234         
    233235        IQD = F2/average_volume*1e-4*volfraction 
    234236        F1 *= 1e-2  # Yun is using sld in 1/A^2, not 1e-6/A^2 
     
    243245    IQSD = IQD*SQ 
    244246    IQBD = IQD*SQ_EFF 
     247    print("\n\n\n\n\n this is F1" + str(F1)) 
     248 
     249    print("\n\n\n\n\n this is F2" + str(F2)) 
     250    print("\n\n\n\n\n this is SQ" + str(SQ))    
    245251    return Theory(Q=q, F1=F1, F2=F2, P=IQD, S=SQ, I=IQSD, Seff=SQ_EFF, Ibeta=IQBD) 
    246252 
     
    334340            Ipars.setdefault(k.replace("_pd_type", "_pd_nsigma"), nsigmas) 
    335341 
     342     
    336343    #Ppars['scale'] = Spars.get('volfraction', 1) 
    337344    P = build_model(Pname, q) 
     
    410417    target = sasmodels_theory(q, model, beta_mode=1, **pars) 
    411418    actual = ellipsoid_pe(q, norm='sasview', **pars) 
     419    print(actual) 
    412420    title = " ".join(("sasmodels", model, pd_type)) 
    413421    compare(title, target, actual) 
     
    452460    Q = data[0] 
    453461    F1 = data[1] 
    454     F2 = data[2] 
    455462    P = data[3] 
    456463    S = data[5] 
     
    464471    Q = data[0] 
    465472    F1 = data[1] 
    466     F2 = data[2] 
    467473    P = data[3] 
    468474    S = data[5] 
  • sasmodels/models/core_shell_sphere.py

    rdc76240 r2d81cfe  
    2121.. math:: 
    2222 
    23     F(q) = \frac{3}{V_s}\left[ 
     23    F^2(q) = \frac{3}{V_s}\left[ 
    2424       V_c(\rho_c-\rho_s)\frac{\sin(qr_c)-qr_c\cos(qr_c)}{(qr_c)^3} + 
    2525       V_s(\rho_s-\rho_\text{solv})\frac{\sin(qr_s)-qr_s\cos(qr_s)}{(qr_s)^3} 
Note: See TracChangeset for help on using the changeset viewer.