I am working on maximum entropy. And I have a problem solving some equations.
Look at these 2 equations:
$\frac{(2*e^{-a*2-b*2^2}) +(6*e^{-a*6-b*6^2}) +(10*e^{-a*10-b*10^2}) +(14*e^{-a*14-b*14^2})}{(e^{-a*2-b*2^2})+(e^{-a*6-b*6^2})+(e^{-a*10-b*10^2})+(e^{-a*14-b*14^2})} = 5.77 $
$\frac{(4*e^{-a*2-b*2^2}) +(36*e^{-a*6-b*6^2}) +(100*e^{-a*10-b*10^2}) +(196*e^{-a*14-b*14^2})}{ (e^{-a*2-b*2^2})+(e^{-a*6-b*6^2})+(e^{-a*10-b*10^2})+(e^{-a*14-b*14^2})} = 45.48 $
I need advice for solving for a and b. There are 2 equation and 2 unknown variables $\{a,b\}$
These equations can be 3 or 4 in number, and unknown variables also be 3 or 4 in number.
And that coefficient $(2,6,10,14)$ can increase to $2,6,10,14,...,n$ or $1,3,5,7,...,n$
My real problem is solving equations and I am in need of ideas to solve them. I tried Matlab and solved them but I need to create that algorithm or using some open source solutions.
You can look here ; http://mathbin.net/175372
This can be solved because there is 2 unknown var and 2 equations. It is exponantial but it can be solved.
I tried to use octave (http://www.gnu.org/software/octave/) octave -q filename.math
and filename.math seems like;
I am not sure about selecting root for solving. I am not sure fsolve has a good solver but i have one solution at least.