Mathematica 9 is now available
Student Support Forum
Student Support Forum: 'automation?' topicStudent Support Forum > General > "automation?"

< Previous CommentHelp | Reply To Comment | Reply To Topic
Author Comment/Response
09/28/10 11:29am


You can do a lot of automation.

Simply define a variable to be the solution to one step, i.e.
i=Det[{...}] then j=function[i] etc. until you're done.

Put it all in one cell, and shift-enter will evaluate it all and give you the final result from the given input.

Note that some solutions will be presented in different forms such as


rather than

k=the_value_you_actually_want .

So you need to "unwrap" the solutions given to you to get to the good stuff, remembering that Mathematica uses list structures.

i.e. if you've solved an equation for the variable ChaseAndEat and gotten the solution

SoManyOptions->{{"cat","mouse"},{"T Rex","human"}}

then ChaseAndEat has a structure just like a list, but with Head set to Rule, instead. Have a look at FullForm[your_intermediate_solution] to see this in your case.

So if the first solution will always be valid, and you're always happy to plug it into the next step then ChaseAndEat[[2,1]] ({"cat","mouse"})will be the appropriate argument for the next function in this example. If you just want the "mouse" then ChaseAndEat[[2,1,2]] would have selected it, for example.


URL: ,

Subject (listing for 'automation?')
Author Date Posted
automation? Anthony 09/26/10 09:03am
Re: automation? toen 09/28/10 11:29am
< Previous CommentHelp | Reply To Comment | Reply To Topic