Changeset 31df0c9 in sasmodels for sasmodels/models/triaxial_ellipsoid.py


Ignore:
Timestamp:
Aug 1, 2017 4:38:47 PM (7 years ago)
Author:
Paul Kienzle <pkienzle@…>
Branches:
master, core_shell_microgels, costrafo411, magnetic_model, ticket-1257-vesicle-product, ticket_1156, ticket_1265_superball, ticket_822_more_unit_tests
Children:
1511c37c
Parents:
d49ca5c
Message:

tuned random model generation for more models

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sasmodels/models/triaxial_ellipsoid.py

    r34a9e4e r31df0c9  
    7171small angle diffraction situations there may be a number of closely similar "best fits", 
    7272so some trial and error, or fixing of some radii at expected values, may help. 
    73      
     73 
    7474To provide easy access to the orientation of the triaxial ellipsoid, 
    7575we define the axis of the cylinder using the angles $\theta$, $\phi$ 
     
    7979.. figure:: img/elliptical_cylinder_angle_definition.png 
    8080 
    81     Definition of angles for oriented triaxial ellipsoid, where radii are for illustration here  
     81    Definition of angles for oriented triaxial ellipsoid, where radii are for illustration here 
    8282    $a < b << c$ and angle $\Psi$ is a rotation around the axis of the particle. 
    8383 
    84 For oriented ellipsoids the *theta*, *phi* and *psi* orientation parameters will appear when fitting 2D data,  
     84For oriented ellipsoids the *theta*, *phi* and *psi* orientation parameters will appear when fitting 2D data, 
    8585see the :ref:`elliptical-cylinder` model for further information. 
    8686 
     
    173173    return ellipsoid_ER(polar, equatorial) 
    174174 
     175def random(): 
     176    import numpy as np 
     177    a, b, c = 10**np.random.uniform(1, 4.7, size=3) 
     178    pars = dict( 
     179        radius_equat_minor=a, 
     180        radius_equat_major=b, 
     181        radius_polar=c, 
     182    ) 
     183    return pars 
     184 
     185 
    175186demo = dict(scale=1, background=0, 
    176187            sld=6, sld_solvent=1, 
Note: See TracChangeset for help on using the changeset viewer.