Changeset 8d97277 in sasview for sansmodels
- Timestamp:
- Mar 31, 2010 1:36:22 PM (15 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:
- 7dca26e
- Parents:
- f10063e
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sansmodels/src/sans/models/DABModel.py
r1ed3834 r8d97277 13 13 Class that evaluates a DAB model. 14 14 15 F(x) = scale /( 1 + (x*L)^2 )^(2) + background15 F(x) = scale*(L^3)/( 1 + (x*L)^2 )^(2) + background 16 16 17 17 The model has three parameters: … … 29 29 ## Name of the model 30 30 self.name = "DAB_Model" 31 self.description="""F(x) = scale /( 1 + (x*L)^2 )^(2) + background31 self.description="""F(x) = scale*(L^3)/( 1 + (x*L)^2 )^(2) + background 32 32 33 33 The model has three parameters: … … 50 50 def _DAB(self, x): 51 51 """ 52 Evaluate F(x) = scale/( 1 + (x*L)^2 )^(2) + background52 Evaluate F(x) = (scale*L^3)/( 1 + (x*L)^2 )^(2) + background 53 53 54 54 """ 55 return self.params['scale']/math.pow(( 1 + math.pow(x * self.params['length'],2)),2) \ 55 # According to SRK (Igor/NIST code: 6 JUL 2009 changed definition of 'scale' to be uncorrelated with 'length') 56 return self.params['scale']*math.pow(self.params['length'],3)/math.pow(( 1 + math.pow(x * self.params['length'],2)),2) \ 56 57 + self.params['background'] 57 58
Note: See TracChangeset
for help on using the changeset viewer.