Changeset 59ee4db in sasmodels for sasmodels/models/_cylpy.py
- Timestamp:
- Dec 4, 2017 1:20:22 PM (6 years ago)
- Children:
- 7f79cba
- Parents:
- 7a40b08
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sasmodels/models/_cylpy.py
r13cf47a r59ee4db 102 102 import numpy as np # type: ignore 103 103 from sasmodels.special import sas_2J1x_x, sas_sinx_x, pi, inf, sincos, square, gauss76 as gauss 104 from sasmodels.special import sin, cos 104 105 105 106 name = "cylinder" … … 154 155 for i in range(gauss.n): 155 156 theta = gauss.z[i]*zm + zb 156 sin_theta, cos_theta = sincos(theta) 157 # TODO: should be using u-substitution of cos(theta) over [0, 1] 158 #sin_theta, cos_theta = sincos(theta) 159 sin_theta = sin(theta) 160 cos_theta = cos(theta) 157 161 form = fq(q*sin_theta, q*cos_theta, radius, length) 158 162 total += gauss.w[i] * form * form * sin_theta
Note: See TracChangeset
for help on using the changeset viewer.