Re: An Array of Equation Parameters
- To: mathgroup at smc.vnet.net
- Subject: [mg59924] Re: An Array of Equation Parameters
- From: Bill Rowe <readnewsciv at earthlink.net>
- Date: Thu, 25 Aug 2005 06:34:36 -0400 (EDT)
- Sender: owner-wri-mathgroup at wolfram.com
On 8/24/05 at 6:30 AM, acvwilson at gmail.com wrote: >This seems like a fairly easy problem in other languages but I >can't figure out how to do it in Mathematica. >I am trying to set up an array of equation parameters, where each >entry in the array is a list of parameters for a function. I also >don't know how to get values out of a list to plug into the >function. If anyone knows how to solve this problem please help me >out. It is a little easier to help when you give specific examples of what you are attempting. However, I think Sequence will do what you want. Suppose I have a function f defined as f[a_,b_,c_d_]:= expression then if list = {a,b,c,d} f[Sequence@@list] will do what you want. For example, g[x_, y_, z_] := (x + y)/z list = {x, y, z}; g[Sequence @@ list] (x + y)/z -- To reply via email subtract one hundred and four