Changeset 98ce141 in sasmodels for sasmodels/models/stacked_disks.c


Ignore:
Timestamp:
Nov 27, 2016 4:25:24 PM (7 years ago)
Author:
butler
Branches:
master, core_shell_microgels, costrafo411, magnetic_model, ticket-1257-vesicle-product, ticket_1156, ticket_1265_superball, ticket_822_more_unit_tests
Children:
07300ea
Parents:
797a8e3
Message:

correct normalization problem in stacked_disk fixes #789. Also heavy
cleanup and correction of equations to match code as well as
standardization of the model documentation addressing #646.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sasmodels/models/stacked_disks.c

    r3ac4e1b r98ce141  
    7171    // loop for the structure factor S(q) 
    7272    double qd_cos_alpha = q*d*cos_alpha; 
     73    //d*cos_alpha is the projection of d onto q (in other words the component 
     74    //of d that is parallel to q. 
    7375    double debye_arg = -0.5*square(qd_cos_alpha*sigma_dnn); 
    7476    double sq=0.0; 
     
    7981    sq = 1.0 + 2.0*sq/n_stacking; 
    8082 
    81     return pq * sq; 
     83    return pq * sq * n_stacking; 
     84    // volume normalization should be per disk not per stack but form_volume 
     85    // is per stack so correct here for now.  Could change form_volume but 
     86    // if one ever wants to use P*S we need the ER based on the total volume 
    8287} 
    8388 
Note: See TracChangeset for help on using the changeset viewer.