MathGroup Archive 2005

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Options in user-defined functions...

  • To: mathgroup at
  • Subject: [mg60343] Re: [mg60332] Options in user-defined functions...
  • From: Manuel Schmidt <Manuel.Schmidt at>
  • Date: Wed, 14 Sep 2005 03:27:11 -0400 (EDT)
  • References: <>
  • Sender: owner-wri-mathgroup at


try this code:



On Tue, 2005-09-13 at 06:07 -0400, Daniele Lupo wrote:
> Hi to all.
> I've a little problem with a function. I've defined it in this way:
> fun[x_,op1_:1,op2_:2,op3_:3]:=
> Module[{....},f1[x,op1],f2[x,op2],f3[x,op3]]
> So, when I use it, ops have their default values.
> It works, but I'd like to use option; this why, if I want to change only
> op3, I must to write every argument when I call the function, while I'd
> like to write something like this:
> fun[x,op3->4]
> how can I do it?
> Thanks for you answers
> Daniele

  • Prev by Date: Re: plots with variation of arbitrary constant
  • Next by Date: Re: Set of strings reducing problem (Again!)
  • Previous by thread: Options in user-defined functions...
  • Next by thread: Re: Options in user-defined functions...