- Timestamp:
- Aug 25, 2013, 12:08:56 PM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/eam_branches/ipp-20130711/psModules/src/objects/models/pmModel_EXP.c
r35966 r36021 79 79 static float *paramsMinUse = paramsMinLax; 80 80 static float *paramsMaxUse = paramsMaxLax; 81 static float betaUse[] = { 1000, 3e6, 5, 5, 1.0, 1.0, 0.5};81 static float betaUse[] = { 2, 3e6, 5, 5, 10.0, 10.0, 0.5}; 82 82 83 83 static bool limitsApply = true; // Apply limits? … … 115 115 psF32 f0 = exp(-q); 116 116 117 psF32 f1 = PAR[PM_PAR_I0]*f0;118 psF32 f = PAR[PM_PAR_SKY] + f1;119 120 117 assert (isfinite(q)); 121 assert (isfinite(f0));122 assert (isfinite(f1));123 assert (isfinite(f));124 118 125 119 // only worry about the central 4 pixels at most … … 127 121 if (radius <= 1.5) { 128 122 f0 = pmModelCP_SersicSubpix (X, Y, PAR[PM_PAR_SXX], PAR[PM_PAR_SXY], PAR[PM_PAR_SYY], 1.0, 51); 129 f1 = PAR[PM_PAR_I0]*f0; 130 f = PAR[PM_PAR_SKY] + f1; 131 } 123 } 124 assert (isfinite(f0)); 125 126 psF32 f1 = PAR[PM_PAR_I0]*f0; 127 psF32 f = PAR[PM_PAR_SKY] + f1; 128 129 assert (isfinite(f1)); 130 assert (isfinite(f)); 132 131 133 132 if (deriv != NULL) { … … 298 297 // f = Io exp(-kappa*sqrt(z)) -> sqrt(z) = ln(Io/f) / kappa 299 298 psF64 zn = log(PAR[PM_PAR_I0] / flux) / kappa; 300 psF64 radius = axes.major * sqrt (2.0) *zn;299 psF64 radius = axes.major * zn; 301 300 302 301 psAssert (isfinite(radius), "fix this code: radius should not be nan for Io = %f, flux = %f, major = %f (%f, %f, %f)",
Note:
See TracChangeset
for help on using the changeset viewer.
