MathGroup Archive 2012

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

Search the Archive

Re: Bug in "Find Previous"

  • To: mathgroup at
  • Subject: [mg127496] Re: Bug in "Find Previous"
  • From: Helen Read <readhpr at>
  • Date: Mon, 30 Jul 2012 03:45:24 -0400 (EDT)
  • Delivered-to:
  • Delivered-to:
  • Delivered-to:
  • Delivered-to:
  • References: <jv2nc9$meg$>

For me (8.0.4, Windows) it finds all the unquoted single n searching for 
Whole Words with Find Next. It doesn't get either 'n' or "n" which one 
could argue either way. Using Find Previous, the Whole Words match seems 
quite flaky. It does find the single n with or without quotes, but it 
also picks out the n in some but not all words containing n. For 
example, it skips "found" and "definition" but hits the n in the "in" 
"And" and "any". It skips the n in the unquoted "not" but hits the n in 
the quoted "not".

I also tried appending the following to your text:

Now search Whole Words for instances of not. Did you notice it misses 
some cases of 'not' with Find Previous?

Then I searched for Whole Word matches 'not' with Find Next and Find 
Previous. Find Next gets all of the unquoted instances of 'not' and 
correctly skips over 'notice'. Find Previous also skips over 'notice' as 
it should, and hits all the quoted and unquoted instances of not until 
it gets to the one with double quotes, and then it stops and does not 
hit the two preceding cases.

Turning off the Whole Words match gets all instances of 'not' whether 
quoted or unquoted (including the substring of 'notice') searching in 
either direction.

It seems that the Whole Words mode is a bit unreliable.

Helen Read

On 7/29/2012 3:05 AM, James Stein wrote:
> Copy these seven lines into a cell as "Plain Text",
> (NOT as the default "Mathematica Input").
> Test searching for n as a single word (not in "not", e.g.).
> You should find this n but not any 'n' in not any !
> Do you see the difference searching forward or backward?
> And what is the definition of 'word' in 'Full Word'?
> Why is this 'n' not found?  What about "n"?
> This bug may be platform specific.
> I'm running Mathematica 8.0.4 on Mac OS X 10.6.8.

  • Prev by Date: Re: mac new OS "mountain lion", compile function, C compiler (vrs. 8.0.4)
  • Next by Date: Re: Mathematica as a New Approach to Teaching Maths
  • Previous by thread: Bug in "Find Previous"
  • Next by thread: Manipulate a Plot of Evaluate DSolve