Re: Replacement Rule
- To: mathgroup at smc.vnet.net
- Subject: [mg60633] Re: [mg60605] Replacement Rule
- From: <bsyehuda at gmail.com>
- Date: Thu, 22 Sep 2005 05:42:20 -0400 (EDT)
- References: <200509220608.CAA01799@smc.vnet.net>
- Reply-to: bsyehuda at gmail.com
- Sender: owner-wri-mathgroup at wolfram.com
After your rule is applied ONCE, there is no "logo" head in the expression so replcement cannot take place again Replace it to logo[a b c d] //. {logo[x_ y_] :> Log[x] + logo[y], logo[x_] :> Log[x]} or (logo[a b c d] //. logo[x_ y_] :> Log[x] + logo[y]) /. logo[x_] :> Log[x] to get the result you need yehuda On 9/22/05, Amir <z64043 at netscape.net> wrote: > > In: logo[a b c d] //. logo[x_ y_] :> Log[x]+Log[y] > Out: Log[a]+Log[b c d] > > Shouldn't the correct answer be( Log[a]+Log[b]+Log[c]+Log[d]) ???? > > Amir > > >
- References:
- Replacement Rule
- From: "Amir" <z64043@netscape.net>
- Replacement Rule