J
John Cordes
I'm trying to help a friend with this one. He has about 5,000
equations, which for the sake of discussion can be taken of the form
2*x^2 - 5*x + 1.
The multiplicity of equations comes about because each eqn. has a
different coefficient of the linear term in x. So the picture is
something like this: there is a column of (say) 5000 values of the
linear coefficient - in column A, say. Column B holds the quadratic,
using the linear coefficient from Col. A.
What he wants to do is to repeatedly apply Solver to all these
equations in turn. I am (very) weak in VBA, but this simple
macro/program (basically obtained by recording) does work ok,
interactively, for one equation:
Sub Solve()
SolverOk SetCell:="$E$2", MaxMinVal:=3, ValueOf:="0", ByChange:="$B$2"
SolverSolve
End Sub
Would anyone have any ideas which would help to streamline the process
of obtaining the solution of 5000 such equations?
Thanks very much for any advice,
John Cordes
equations, which for the sake of discussion can be taken of the form
2*x^2 - 5*x + 1.
The multiplicity of equations comes about because each eqn. has a
different coefficient of the linear term in x. So the picture is
something like this: there is a column of (say) 5000 values of the
linear coefficient - in column A, say. Column B holds the quadratic,
using the linear coefficient from Col. A.
What he wants to do is to repeatedly apply Solver to all these
equations in turn. I am (very) weak in VBA, but this simple
macro/program (basically obtained by recording) does work ok,
interactively, for one equation:
Sub Solve()
SolverOk SetCell:="$E$2", MaxMinVal:=3, ValueOf:="0", ByChange:="$B$2"
SolverSolve
End Sub
Would anyone have any ideas which would help to streamline the process
of obtaining the solution of 5000 such equations?
Thanks very much for any advice,
John Cordes