aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorastrojhgu <astrojhgu@ed2142bd-67ad-457f-ba7c-d818d4011675>2012-08-31 05:45:10 +0000
committerastrojhgu <astrojhgu@ed2142bd-67ad-457f-ba7c-d818d4011675>2012-08-31 05:45:10 +0000
commit19f2b2cbd127a15034af6a1d1256b47c38c57543 (patch)
tree54bb85b365af9b2c9f627ce7bcbd534de02f679a
parentc3aedd0fa33bbb175403bece84d8919ee53eb3dc (diff)
downloadopt-utilities-19f2b2cbd127a15034af6a1d1256b47c38c57543.tar.bz2
git-svn-id: file:///home/svn/opt_utilities@241 ed2142bd-67ad-457f-ba7c-d818d4011675
-rw-r--r--models/beta1d.hpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/models/beta1d.hpp b/models/beta1d.hpp
index bd5d292..9885098 100644
--- a/models/beta1d.hpp
+++ b/models/beta1d.hpp
@@ -40,10 +40,10 @@ namespace opt_utilities
T do_eval(const T& x,const std::vector<T>& param)
{
- T S0=get_element(param,0);
+ T S0=std::abs(get_element(param,0));
T r_c=get_element(param,1);
- T beta=get_element(param,2);
- T bkg=get_element(param,3);
+ T beta=std::abs(get_element(param,2));
+ T bkg=std::abs(get_element(param,3));
return bkg+S0*pow(1+(x*x)/(r_c*r_c),-3*beta+static_cast<T>(.5));
}