MathGroup Archive 1996

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

Search the Archive

Re: Rule to Function, Frontend funnies

  • To: mathgroup at smc.vnet.net
  • Subject: [mg5316] Re: [mg5307] Rule to Function, Frontend funnies
  • From: Allan Hayes <hay at haystack>
  • Date: Wed, 27 Nov 1996 01:47:34 -0500
  • Sender: owner-wri-mathgroup at wolfram.com

Wouter Meeussen <meeussen.vdmcc at vandemoortele.be>
>Subject: [mg5307] Rule to Function, Frontend funnies

> how can I convert a rule to a function?
> if I get a result from
> rulesoln = DSolve[{y'[x]==y[x]/(c+1/x),y[0]==1},y[x],x]
> in the form :
>                                2
>            x/c - Log[1 + c x]/c
> {{y[x] -> E                     }}
>
> how do I get the definition :
> y[x_]:= E^(x/c - Log[1 + c x]/c^2)

Wouter:
Two suggestions:

Unevaluated[y[x_] := y[x]]/.rulesoln[[1]]

y[x_]:= Evaluate[y[x]/.rulesoln[[1]]]

Allan Hayes
hay at haystack.demon.co.uk
http://www.haystack.demon.co.uk



  • Prev by Date: mathematica 3.0 notebook problems?
  • Next by Date: Re: Formatting Output
  • Previous by thread: Rule to Function, Frontend funnies
  • Next by thread: Re: Rule to Function, Frontend funnies