Mathematica 9 is now available
Student Support Forum
-----
Student Support Forum: 'automatically making a large set of substitutions' topicStudent Support Forum > General > "automatically making a large set of substitutions"

Next Comment >Help
Author Comment/Response
Lily
03/17/07 9:02pm

I have a formula involving a large number of variables. They have the form u1x, u1y, u1z, u2x, u2y, u2z, etc Currently the number in the middle runs up to 5, but it could run up to much higher values, like 40.

I would like to examine the formula's dependence on one variable at a time by setting all the others to a constant.

I want to get mathematica to cycle through the list of variables, leaving one alone at a time and setting all others to 1.

I can get it to generate a list of the variables by
ToExpression["u"<>ToString[i]<>"m"] and index over the i. But I can't use the resulting expression in the Replace function.

URL: ,

Thread 'automatically making a large set of substitutions' is now CLOSED
Author Date Posted
automatically making a large set of substitutions Lily 03/17/07 9:02pm
Re: automatically making a large set of substit... Peter Pein 03/18/07 3:09pm
Re: automatically making a large set of substit... yehuda ben-s... 03/18/07 5:06pm
Next Comment >Help