Changeset ee60aa7 in sasmodels for sasmodels/models/ellipsoid.c


Ignore:
Timestamp:
Sep 10, 2018 4:16:46 PM (6 years ago)
Author:
Paul Kienzle <pkienzle@…>
Branches:
master, core_shell_microgels, magnetic_model, ticket-1257-vesicle-product, ticket_1156, ticket_1265_superball, ticket_822_more_unit_tests
Children:
d299327
Parents:
3f818b2
Message:

clean up effective radius functions; improve mono_gauss_coil accuracy; start moving VR into C

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sasmodels/models/ellipsoid.c

    rd277229 ree60aa7  
    3434effective_radius(int mode, double radius_polar, double radius_equatorial) 
    3535{ 
    36     if (mode == 1) { 
     36    switch (mode) { 
     37    case 1: // equivalent sphere 
    3738        return radius_from_volume(radius_polar, radius_equatorial); 
    38     } else if (mode == 2) { 
     39    case 2: // average curvature 
    3940        return radius_from_curvature(radius_polar, radius_equatorial); 
    40     } else if (mode == 3) { 
     41    case 3: // min radius 
    4142        return (radius_polar < radius_equatorial ? radius_polar : radius_equatorial); 
    42     } else { 
     43    case 4: // max radius 
    4344        return (radius_polar > radius_equatorial ? radius_polar : radius_equatorial); 
    4445    } 
Note: See TracChangeset for help on using the changeset viewer.