Services & Resources / Wolfram Forums
-----
 /
MathGroup Archive
1992
*January
*February
*March
*April
*May
*June
*July
*August
*September
*October
*November
*December
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 1992

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

Search the Archive

Re: Re-indexing Mathematica

  • To: mathgroup at yoda.physics.unc.edu
  • Subject: Re: Re-indexing Mathematica
  • From: jacobson at cello.hpl.hp.com
  • Date: Mon, 20 Jul 92 08:27:20 -0700

David Tindall McMath wants to have zero-based subscripting.  If he is
willing to use function call syntax like this ZPart[somearray,2,3],
instead of regular subscript notation, like somearray[[2,3]], here is
the code:


ZPart[obj_,partlist___] := Part[obj,Apply[Sequence,
				  Map[#+1&,{partlist}]]]


  -- David Jacobson





  • Prev by Date: Re: Table[ ...If[...i...] ,{i,...}]
  • Next by Date: FontForm
  • Previous by thread: Re-indexing Mathematica
  • Next by thread: Re: Re-indexing Mathematica