Mathematica 9 is now available
Student Support Forum
-----
Student Support Forum: 'using solver value in iteration' topicStudent Support Forum > General > "using solver value in iteration"

Next Comment >Help | Reply To Topic
Author Comment/Response
andrew shaw
12/09/04 05:39am

I have created an iteration loop using a block statement. I calculate an initial guess for my term 'mola' and work through the various calculations to derive a new value for mola called 'newmola'. These values are then compared and and if they are not equal the loop returns to a Label["top"].

My problem is this, I have a pair of equations which I use Solver to find the result of. If I leave out a Solve function, which calculates the solution to a simultaneous equations, and instead simplify the equations so that they solve individually the iteration works fine. However if I leave in the solve function and then try and take the values from it using the replacement rule the iteration does not work.

Further if the iteration is forced to loop with the Solve values (by setting 1 < 2 in the If statement at the bottom instead of "newmola (does not equal) mola") on the second iteration the program gives the error that the Solver is not a well formed equation. Can Anyone help?

the programm attached is the one with the solver. (the solver finds the values for molplus and molminus)

* There is a limit on the iterations (3 iterations) in the program as when the function is forced to iterate the calculations get very messy


Attachment: edwards calc with simul.nb, URL: ,

Subject (listing for 'using solver value in iteration')
Author Date Posted
using solver value in iteration andrew shaw 12/09/04 05:39am
Re: using solver value in iteration Andrew DuBui... 12/13/04 11:52am
Re: using solver value in iteration andrew shaw 12/14/04 04:25am
Next Comment >Help | Reply To Topic