Changeset 5f65636 in sasview for sansmodels/src/sans/models
- Timestamp:
- Feb 10, 2012 12:33:06 PM (13 years ago)
- Branches:
- master, ESS_GUI, ESS_GUI_Docs, ESS_GUI_batch_fitting, ESS_GUI_bumps_abstraction, ESS_GUI_iss1116, ESS_GUI_iss879, ESS_GUI_iss959, ESS_GUI_opencl, ESS_GUI_ordering, ESS_GUI_sync_sascalc, costrafo411, magnetic_scatt, release-4.1.1, release-4.1.2, release-4.2.2, release_4.0.1, ticket-1009, ticket-1094-headless, ticket-1242-2d-resolution, ticket-1243, ticket-1249, ticket885, unittest-saveload
- Children:
- ccb7363
- Parents:
- 664c5a7
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sansmodels/src/sans/models/qsmearing.py
r2b440504 r5f65636 500 500 # Length of the width 501 501 length = len(width) 502 width_low = math.fabs(width[0]) 502 width_low = math.fabs(width[0]) 503 503 width_high = math.fabs(width[length -1]) 504 504 nbins_low = 0.0 505 nbins_high = 0.0 505 506 # Compare width(dQ) to the data bin size and take smaller one as the bin 506 507 # size of the extrapolation; this will correct some weird behavior … … 522 523 # Number of q points required below the 1st data point in order to extend 523 524 # them 3 times of the width (std) 524 nbins_low = math.ceil(3.0 * width_low / bin_size_low) 525 if width_low > 0.0: 526 nbins_low = math.ceil(3.0 * width_low / bin_size_low) 525 527 # Number of q points required above the last data point 526 nbins_high = math.ceil(3.0 * width_high / (bin_size_high)) 528 if width_high > 0.0: 529 nbins_high = math.ceil(3.0 * width_high / bin_size_high) 527 530 # Make null q points 528 531 extra_low = numpy.zeros(nbins_low)
Note: See TracChangeset
for help on using the changeset viewer.