Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.soft-sys.math.mathematica > #3277

Re: pattern example

From Francisco Gutierrez <fgutiers2002@yahoo.com>
Newsgroups comp.soft-sys.math.mathematica
Subject Re: pattern example
Date 2011-06-24 11:50 +0000
Organization Steven M. Christensen and Associates, Inc and MathTensor, Inc.
Message-ID <iu1tl9$9k7$1@smc.vnet.net> (permalink)

Show all headers | View raw


Thanks Leonid, Bob and others. After restarting the kernel everything worked well.I imagine something I did during the session prevented the evaluation of the code.Sorry for the noiseFg

--- On Thu, 6/23/11, Leonid Shifrin <lshifr@gmail.com> wrote:

From: Leonid Shifrin <lshifr@gmail.com>
Subject: Re: pattern example
To: "Francisco Gutierrez" <fgutiers2002@yahoo.com>, mathgroup@smc.vnet.net
Date: Thursday, June 23, 2011, 8:48 AM

Hi Francisco,

I can't check on 8.0.1 right now, but both v8.0 and v7.0 give the result as in the book.
I hope someone else will comment on 8.0.1.

Cheers,
Leonid




On Thu, Jun 23, 2011 at 3:25 PM, Francisco Gutierrez <fgutiers2002@yahoo.com> wrote:

I find in Leonid's (Shiffrin) excellent book the following example (p. 122):

f[3/5,4,5,2/3]/.f[x:(_Integer|_Rational)..]:>{x}



According to the book, this returns {3/5,4,5,2/3}



However, I get (Mathematica 8.0.1, Windows 7) f[3/5,4,5,2/3]



What's wrong?

Francisco

Back to comp.soft-sys.math.mathematica | Previous | Next | Find similar | Unroll thread


Thread

Re: pattern example Francisco Gutierrez <fgutiers2002@yahoo.com> - 2011-06-24 11:50 +0000

csiph-web