Re: mathematica question
- To: mathgroup at smc.vnet.net
- Subject: [mg9231] Re: [mg9199] mathematica question
- From: "C. Woll" <carlw at u.washington.edu>
- Date: Fri, 24 Oct 1997 01:00:46 -0400
- Sender: owner-wri-mathgroup at wolfram.com
Hi Tom, I don't understand why you don't use your index as the argument of your function. Thus, let q[i] be your functions. Then a function to do a particular list of q's is simply doq[a_List]:=q/@a If this doesn't work, could you give more details about your particular problem? Good luck, Carl Woll Dept of Physics U of Washington On Tue, 21 Oct 1997, Tom wrote: > Hello Mathematica users, > > I have a question that I hope someone has an answer for. I think it > should be simple but I cannot find a way to make it work. > > I have a set of functions that take no inputs, they are called q1[], > q2[], q3[] and so on. > > How can I get Mathematica to run the correct function given a list of > numbers as input. IE, if I supply the list {1,4,7,8} I would want > Mathematica to run the functions q1[], q4[], q7[] and q8[], assuming > they were defined. > > I would appreciate any assistance you might have with this!! > > Sincerely, > > Tom De Vries > >