Re: problem with numerical values in Solve/NSolve
- To: mathgroup at smc.vnet.net
- Subject: [mg63736] Re: problem with numerical values in Solve/NSolve
- From: Peter Pein <petsie at dordos.net>
- Date: Fri, 13 Jan 2006 04:48:13 -0500 (EST)
- References: <dq53td$abp$1@smc.vnet.net>
- Sender: owner-wri-mathgroup at wolfram.com
Hello Jacob, you might want to try NullSpace[m1] --> {{0.010011241314340086, 0.00003981968052280508, 0.9999485428023668, 0.0016386167927237756, 0.00001200703518667599}} Peter Jacob Grose schrieb: > Hello, > > I writing a physics simulation and I need to solve a system of 41 equations. However, I am having problems even with a more simple 5x5 matrix. The problem is as follows: If I symbolically solve the matrix m1: > > \!\(\* > TagBox[ > RowBox[{"(", "\[NoBreak]", GridBox[{ > {\(\(-a\) - b - c\), "0", "f", "h", "l"}, > {"0", \(\(-c\) - d - e\), "g", "k", "m"}, > {"a", "c", \(\(-f\) - g\), "0", "0"}, > {"b", "d", "0", \(\(-h\) - k\), "0"}, > {"c", "e", "0", "0", \(\(-l\) - m\)} > }], "\[NoBreak]", ")"}], > Function[ BoxForm`e$, > MatrixForm[ BoxForm`e$]]]\) > > Using the code: > > variables = Array[p, 5]; > evec = Simplify[Solve[m1.variables \[Equal] Table[0, {i, 1, 5}], Array[p, 4]]] > > I get a result. However, if I try to solve for a matrix (m) of the same form but with values substituted for the variables: > > \!\(\* > TagBox[ > RowBox[{"(", "\[NoBreak]", GridBox[{ > {\(-1.870413280501348`*^10\), > "0", "1.7479373054791087`*^8", " > 7.607967609656633`*^9", "2.5605854781972427`*^7"}, > {"0 > ", \(-1.2870235495030115`*^10\), "206293.3885126606`", \ > "8.754725514677356`*^7", "1.3554510956434595`*^10"}, > {"1.747937063721231`*^10", "2.062933885126606`*^7 > ", \(-1.7500002393642354`*^8\), "0", "0"}, > {"1.2247621677975328`*^9", "8.754722967399057`*^9", "0", \ > \(-7.695514864803407`*^9\), "0"}, > {"0.0036402209477187386`", "4.094883188779791`*^9", "0", "0", \ > \(-1.3580116811216568`*^10\)} > }], "\[NoBreak]", ")"}], > Function[ BoxForm`e$, > MatrixForm[ BoxForm`e$]]]\) > > Using the same code: > > variables = Array[p, 5]; > evec = Simplify[Solve[m.variables \[Equal] Table[0, {i, 1, 5}], Array[p, 4]]] > > mathematica returns: {}. > > I tried using Nsolve instead of solve, as well as setting $MaxExtraPrecision = 5000, but it didn't help. Any ideas? > > Thanks, > Jacob >