MathGroup Archive 2002

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

Search the Archive

Re: arguments of the function

  • To: mathgroup at
  • Subject: [mg35424] Re: [mg35402] arguments of the function
  • From: BobHanlon at
  • Date: Fri, 12 Jul 2002 04:28:37 -0400 (EDT)
  • Sender: owner-wri-mathgroup at

In a message dated 7/11/02 6:24:43 AM, eleri111 at writes:

>I am using Mathematica 4.0
>I can't find a function that would find arguments of the function.
>For example I have an equation: 
>y[t+3]=a1* Cos[Sin[u[t+2]]]/Tan[u[t+1]]-Cot[u[t+3]]+a2
>and I would like to get those argumets u[t+3], u[t+2], u[t+1]
>and give them new values
>for example:
>and then print that equation with new values:
>y[t+3]=a1* Cos[Sin[x2]]/Tan[x3]-Cot[x1]+a2
>Can you tell me how to do that?


% /. u[t+n_] :> ToExpression["x"<>ToString[4-n]]

y[3+t]==a2-Cot[x1]+a1 Cos[Sin[x2]] Cot[x3]


StringReplace[%, Evaluate[Table[
      ("u[t+"<>ToString[n]<>"]") -> ("x"<>ToString[4-n]),


Bob Hanlon
Chantilly, VA  USA

  • Prev by Date: Problem with image import
  • Next by Date: Re: Graphics Question
  • Previous by thread: Re: arguments of the function
  • Next by thread: Re: arguments of the function