I have an equation system that seems to be overdetermined:
eq1:q = 34000*(T[CuH2O]-30);
eq2:q = 380*(T[NiCu]-T[CuH2O])/(0.20e-1);
eq3:q = 70*(T[WNi]-T[NiCu])/(0.5e-2);
eq4:q = 10*(T[SlW]-T[WNi])/(0.4e-3);
eq5:q = 1.5*(T[StSl]-T[SlW])/(0.1e-2);
eq6:q = 30*(1520-T[StSl])/(0.2e-2);
solve([eq1,eq2,eq3,eq4,eq5,eq6]);
I used the q value for convenience and Maple solves this without problems. Maxima tells me: solve: more equations than unknowns.
Is there any way to solve this?
Looks like solve
can't figure out the list of variables in this case; I suppose that's a bug. At any rate, you can specify the list of variables and then solve
can handle it. Here's what I got when I tried that:
(%i17) solve([eq1,eq2,eq3,eq4,eq5,eq6], [q,T[CuH2O],T[NiCu],T[WNi],T[SlW],T[StSl]]);
rat: replaced -19000.0 by -19000/1 = -19000.0
rat: replaced -14000.0 by -14000/1 = -14000.0
rat: replaced -25000.0 by -25000/1 = -25000.0
rat: replaced -1500.0 by -1500/1 = -1500.0
rat: replaced -15000.0 by -15000/1 = -15000.0
252666750000 12146265 25444515
(%o17) [[q = ------------, T = --------, T = --------,
157163 CuH2O 157163 NiCu 157163
43492140 53598810 222043310
T = --------, T = --------, T = ---------]]
WNi 157163 SlW 157163 StSl 157163
solve
prefers exact numbers (integers and rationals) so it converts floats -- that's what the rat
messages are about. In general, Maxima is more comfortable with exact numbers.