MathGroup Archive 2010

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

Search the Archive

Re: Re: More /.{I->-1} craziness

  • To: mathgroup at smc.vnet.net
  • Subject: [mg106101] Re: [mg106036] Re: More /.{I->-1} craziness
  • From: DrMajorBob <btreat1 at austin.rr.com>
  • Date: Fri, 1 Jan 2010 05:36:56 -0500 (EST)
  • References: <hhf5s3$h4o$1@smc.vnet.net> <200912310813.DAA24663@smc.vnet.net>
  • Reply-to: drmajorbob at yahoo.com

Of those examples, the one I find most amazing is

a .3.4/.3->c
FullForm@%

a 0.3.4
Times[a,Dot[0.3`,4]]

The result is bizarre, and it can't be entered at the keyboard.

Try entering 0.3.4 in an Input cell, and see what happens!

Bobby

On Thu, 31 Dec 2009 02:13:51 -0600, Richard Fateman  
<fateman at cs.berkeley.edu> wrote:

> AES wrote:
>> The more I play with these I->-I substitution rules, the more seemingly
>> wildly inconsistent results emerge.  For example:
>>
>>    In[1]:= -I/.I->-I
>>
>>    Out[1]= -I
>>
> ..snip..
>>
> These examples you give are perfectly consistent with a certain world
> view which is that I is not a symbol, but a functional form,
> Complex[0,1], and -I is a different form, Complex[0,-1].
>
> The fact that this is not what you expect as a mathematician is simply
> your fault.:)
>
> You might find these examples. some old, some new,  confusing as well.
> (in Mathematica 6.0)
>
> Here are some puzzles for you.  Guess what they return. (Answers below)
> 3 /. 3->4
> 3  /.3->4
> 3 /0.3->4     (which helps explain previous line)
>
> 3 / . 3 ->4
>
> 3 /. 3.0->4
>
> 3/.3.0->4
> 3.0/. 3.0->4
>
> a. 3/. a->b
> a.3 /. a->b
>
> a .3 . 4  /. 3 -> c
> a. 3 . 4  /. 3 -> c
>
> .......answers.........
>
> 3 /. 3->4    returns 4
> 3  /.3->4    returns 10.->4
> 3 /0.3->4    returns 10.->4   (which helps explain previous line)
>
> 3 / . 3 ->4   syntax error
>
> 3 /. 3.0->4  returns 3
>
> 3/.3.0->4    returns 0.->4
> 3.0/. 3.0->4 returns 4
>
> a. 3/. a->b  returns b.3
> a.3 /. a->b  returns 0.3*b
>
> a .3 . 4  /. 3 -> c returns a 0.3.4
> a. 3 . 4  /. 3 -> c returns a.c.4
>
>
>
>
> and yes, I know the explanation for all of these.
>


-- 
DrMajorBob at yahoo.com


  • Prev by Date: Re: Re: Re: algebraic numbers
  • Next by Date: Re: Financial Data - Currencies
  • Previous by thread: Re: Re: More /.{I->-1} craziness
  • Next by thread: Re: More /.{I->-1} craziness