Changeset 1bf66d9 in sasmodels


Ignore:
Timestamp:
Apr 18, 2016 8:26:43 AM (9 years ago)
Author:
wojciech
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:
3a45c2c, 1448db7a
Parents:
a7c2cfe
Message:

Spherical SLD model doesn't crash but still some work needs to be done

Location:
sasmodels/models
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • sasmodels/models/spherical_sld.c

    r4605bf10 r1bf66d9  
    55    double thick_inter[]) 
    66{ 
    7     double radius = 0.0; 
    87    int i; 
    98    double r = radius_core; 
     
    196195    dp[5] = sld_solvent; 
    197196    dp[6] = 0.0; 
    198  
    199     for (int i=1; i<n_shells; i++){ 
     197    dp[7] = sld_flat[0]; 
     198    //TODO: Something is messed up with this data strcucture! 
     199    dp[17] = thick_inter[0]; 
     200    dp[27] = thick_flat[0]; 
     201    dp[37] = func_inter[0]; 
     202    dp[47] = nu_inter[0]; 
     203 
     204    for (int i=1; i<=n_shells; i++){ 
    200205        dp[i+7] = sld_flat[i]; 
    201206        dp[i+17] = thick_inter[i]; 
  • sasmodels/models/spherical_sld.py

    r4605bf10 r1bf66d9  
    260260 
    261261 
    262 demo = dict( 
    263     n=4, 
    264     scale=1.0, 
    265     sld_solvent=1.0, 
    266     background=0.0, 
    267     npts_inter=35.0, 
    268     ) 
     262demo = { 
     263    "n_shells":4, 
     264    "npts_inter":35.0, 
     265    "radius_core":50.0, 
     266    "sld_core":2.07, 
     267    "sld_solvent": 1.0, 
     268    "sld_flat":[4.0,3.5,4.0,3.5,4.0], 
     269    "thick_flat":[100.0,100.0,100.0,100.0,100.0], 
     270    "func_inter":[0,0,0,0,0], 
     271    "thick_inter":[50.0,50.0,50.0,50.0,50.0], 
     272    "nu_inter":[2.5,2.5,2.5,2.5,2.5] 
     273    } 
    269274 
    270275#TODO: Not working yet 
Note: See TracChangeset for help on using the changeset viewer.