Services & Resources / Wolfram Forums
MathGroup Archive
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 2001

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

Search the Archive

Solved: Packed array generation and complex numbers

  • To: mathgroup at
  • Subject: [mg31981] Solved: Packed array generation and complex numbers
  • From: Martin Johansson <martin.n.johansson at>
  • Date: Fri, 14 Dec 2001 16:53:13 -0500 (EST)
  • Organization: Ericsson Microwave Systems AB
  • References: <9ul29u$6lr$> <9uq7g6$abh$>
  • Sender: owner-wri-mathgroup at


as pointed out, the execution time "anomaly" can
be explained by some of the arguments being packed

The remaining question was then why some of the
arguments became packed arrays, and some not.

In private conservation, Sseziwa Mukasa suggested
it had to do with 'I' being an infinite precision
number. This turns out to be correct:

PackedArrayQ[Table[Random[],{i,n}]+(I//N) 1]
PackedArrayQ[(I//N) Table[Random[],{i,n}]]
PackedArrayQ[1+ Table[(I//N)Random[],{i,n}]]


So, by first calculating a floating-point 'I',
all results become packed arrays (and I save a
lot of time).

Ciao, Martin

Martin Johansson, Ph.D.
Senior Specialist
Advanced Base Station Antennas
m.johansson at

  • Prev by Date: Functions with Options
  • Next by Date: Re: restrictions on parameter
  • Previous by thread: ShowProgress in NonlinearFit
  • Next by thread: Re: restrictions on parameter