Changeset 4962519 in sasmodels for sasmodels/models/fractal_core_shell.py


Ignore:
Timestamp:
Oct 14, 2016 6:49:58 PM (8 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:
14838a3
Parents:
a5b6997
Message:

use square and cube instead of pow()

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sasmodels/models/fractal_core_shell.py

    ra807206 r4962519  
    100100        @param thickness: shell thickness 
    101101    """ 
    102     whole = 4.0 * pi / 3.0 * pow((radius + thickness), 3) 
    103     core = 4.0 * pi / 3.0 * radius * radius * radius 
     102    whole = 4.0/3.0 * pi * (radius + thickness)**3 
     103    core = 4.0/3.0 * pi * radius**3 
    104104    return whole, whole-core 
    105105 
Note: See TracChangeset for help on using the changeset viewer.