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 2007

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

Search the Archive

Re: Weird Print Result

  • To: mathgroup at
  • Subject: [mg74154] Re: Weird Print Result
  • From: dh <dh at>
  • Date: Mon, 12 Mar 2007 22:13:30 -0500 (EST)
  • Organization:
  • References: <et36rq$qgu$>

Hi Bruce,

consider your last line: Print /@ X[[1]]. Presumably you wanted: Print @ 

X[[1]] or Print[ X[[1]] ]. What you did, is to map Print on the first 

level of X[[1]]. As the output of Print is Null and as the Head of 

X[[1]] is Plus, you created: Plus[Null,Null,Null,Null]. This gives 4 

Null, correct?


Bruce Colletti wrote:

> Re Mathematica 5.2 under WinXP.


> The code below creates the correct output, except for a strange concluding "4 Null."


> What does this weird last line of output mean (list length?), why does it print, and how can it be suppressed?


> Thankx.


> Bruce



> n = 2;

> T = Array[p, {n, n}];

> X0 = Array[x, {n}];

> X = (Expand /@ (X0.MatrixPower[T, 2]));

> Print /@ X[[1]]


  • Prev by Date: Re: NDSolve. Getting the final values
  • Next by Date: Re: Multi-core Support in Mathematica 5.2
  • Previous by thread: Re: Weird Print Result
  • Next by thread: Re: Weird Print Result