Re: How to extract functions from a list and call them with any argument?
- To: mathgroup at smc.vnet.net
- Subject: [mg65942] Re: How to extract functions from a list and call them with any argument?
- From: "Norbert Marxer" <marxer at mec.li>
- Date: Mon, 24 Apr 2006 06:01:53 -0400 (EDT)
- References: <e2fkto$bp7$1@smc.vnet.net>
- Sender: owner-wri-mathgroup at wolfram.com
Hallo
With your definition of functionlist
funclist = {Sin[x], x^3, Cos[x]^2};
funclist[[3]] /. x -> t
will give what you want.
Or you could use Pure function definitions. Then
funclist = {Sin, #^3 &, Cos[#]^2 &};
funclist[[3]][t]
will give what you want.
Best regards
Norbert Marxer
www.mec.li