| Author |
Comment/Response |
Dee
|
06/03/08 06:59am
Dear all,
I have just upgraded to Mathematica version 6.0.2.1 and have tried to use FindFit with constraints.
It does not seem to work as it should according to the documentation:
In:=
fp = Table[Prime[x], {x, 20}];
In:= FindFit[fp, {a X Log[b + c X], {0 <= a}}, {a, b, c}, X]
Out:= FindFit[{2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53,
59, 61, 67, 71}, {a X Log[b + c X], {0 <= a}}, {a, b, c}, X]
whereas
In:=
FindFit[fp, a X Log[b + c X], {a, b, c}, X]
Out:= {a -> 1.42076, b -> 1.65558, c -> 0.534645}
using it without constraints works fine.
Any suggestions?
Many thanks
URL: , |
|