MathGroup Archive 2012

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

Search the Archive

Re: Parenthesis reduction

  • To: mathgroup at
  • Subject: [mg126956] Re: Parenthesis reduction
  • From: John Doty <noqsiaerospace at>
  • Date: Wed, 20 Jun 2012 03:50:18 -0400 (EDT)
  • Delivered-to:
  • References: <jrlfoa$c2s$> <jrmthi$h6o$> <jrp8sq$q97$>

On Tuesday, June 19, 2012 3:14:34 AM UTC-4, Nasser M. Abbasi wrote:
 using V 8.04, this does nothing?
> In[1]:= Sequence@@{{a,b,c},{d,e,f},{g,h,i}}
> Out[1]= Sequence[{a,b,c},{d,e,f},{g,h,i}]

What did you expect it to do? {a,b,c},{d,e,f},{g,h,i} is not a proper expression: it has no head, so Sequence[] cannot return it. Sequence[] is not really comprehensible as a "function": in effect it edits its caller's argument list!

Try f[Sequence@@{{a,b,c},{d,e,f},{g,h,i}}]

Always remember that fundamentally, Mathematica is *rewriting expressions* according to rules that *often* correspond to procedure or function evaluation, but sometimes are really something else.

  • Prev by Date: Moment function
  • Next by Date: NDSolve profiling
  • Previous by thread: Re: Parenthesis reduction
  • Next by thread: Export points 3D plots