Re: HELP : Mathematica v4 producing erroneous results ! Mathematica3 worked fine...

• To: mathgroup at smc.vnet.net
• Subject: [mg18983] Re: HELP : Mathematica v4 producing erroneous results ! Mathematica3 worked fine...
• From: Jens-Peer Kuska <kuska at informatik.uni-leipzig.de>
• Date: Tue, 3 Aug 1999 13:44:31 -0400
• Organization: Universitaet Leipzig
• References: <7nrebg\$icj@smc.vnet.net>
• Sender: owner-wri-mathgroup at wolfram.com

```Hi Chris,

I can't fix the bug but using a For[] loop

For[i=1, i<3, i++,
For[j=1, j<3, j++,
output[[i,j]]=ideal[[i,j]]
]
];
output

work correct as well as

Do[output[[i, j]] = Re[#]+I*Im[#] & [ideal[[i,j]]], {i, 1, 2}, {j, 1,
2}];
output

Hope that helps. A work arround may be to redefine all Do[] versions
to For[] loops in a small package.

Hope that helps
Jens

> Can people reproduce it ?  What is going on ?  No comments please on style or
> content - remember this is a cut down version of a far larger notebook just to
> illustrate the point:
>
> In[1]:= \$Version
> Out[1]= "4.0 for Microsoft Windows (April 21, 1999)"
>
> In[2]:= SeedRandom[1];
>         ideal=Table[Random[Complex,{-1-I,+1+I}],{2},{2}]
>
> Out[2]= {{0.337385+0.6624 I], 0.563615-0.750732 I},{0.869075+0.200504 I,
> 0.516709+0.938178 I}}
>
> In[3]:= output=Fourier[ideal];
>         Do[output[[i,j]]=ideal[[i,j]],{i,1,2},{j,1,2}];
>         output
>
> Out[3]= {{0.337385+0.337385 I, 0.563615+0.563615 I},{0.869075+0.869075 I,
>         0.516709+0.516709 I}}
>
> Why does Out[3] not equal Out[2] ?  In Mathematica v3, there is no problem.
>

```

• Prev by Date: Re: Wheel mouse under X.
• Next by Date: Re: Clippling of polygons within a defined region
• Previous by thread: Re: HELP : Mathematica v4 producing erroneous results ! Mathematica3 worked fine...
• Next by thread: Re: HELP : Mathematica v4 producing erroneous results ! Mathematica3 worked fine...