Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.soft-sys.math.mathematica > #1878
| From | "Christopher O. Young" <cy56@comcast.net> |
|---|---|
| Newsgroups | comp.soft-sys.math.mathematica |
| Subject | Re: How to roll up multiple Line calls into a loop |
| Date | 2011-04-25 11:29 +0000 |
| Organization | Steven M. Christensen and Associates, Inc and MathTensor, Inc. |
| Message-ID | <ip3lv0$r9r$1@smc.vnet.net> (permalink) |
| References | <iorih5$o6t$1@smc.vnet.net> <iouedm$6h6$1@smc.vnet.net> |
On 4/23/11 7:50 AM, in article iouedm$6h6$1@smc.vnet.net, "Dan"
<dflatin@rcn.com> wrote:
> Graphics[(Line[{{0,11-#},{#,0}}]&)/@Range[10]]
If we want to avoid typing out "Range", we can just define "R" as Range.
Then we can do this with:
Graphics[
Line[{{0, 10 - #}, {#, 0}}] & /@ 0~R~10
]
It looks like the ampersand will apply to the whole Line[ ] expression
without having to parenthesize it.
What I'd really like to do is have a more intuitive expression such as the
ellipsis character, =8A, for Range, and to be able to use it the way "+" and
"-" are used, without having to type the tildes on either side to show it's
an infix symbol.
At any rate, here it is with the ellipsis defined as Range:
\[Ellipsis] = Range
Graphics[
Line[{{0, 10 - #}, {#, 0}}] & /@ 0~\[Ellipsis]~10
]
Back to comp.soft-sys.math.mathematica | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
How to roll up multiple Line calls into a loop Sol Lederman <sol.lederman@gmail.com> - 2011-04-22 09:41 +0000
Re: How to roll up multiple Line calls into a loop Dan <dflatin@rcn.com> - 2011-04-23 11:50 +0000
Re: How to roll up multiple Line calls into a loop "Christopher O. Young" <cy56@comcast.net> - 2011-04-25 11:29 +0000
Re: How to roll up multiple Line calls into a loop Albert Retey <awnl@gmx-topmail.de> - 2011-04-23 11:51 +0000
Re: How to roll up multiple Line calls into a loop "Christopher O. Young" <cy56@comcast.net> - 2011-04-23 11:51 +0000
Re: How to roll up multiple Line calls into a loop Helen Read <readhpr@gmail.com> - 2011-04-23 11:51 +0000
Re: How to roll up multiple Line calls into a loop Peter Pein <petsie@dordos.net> - 2011-04-23 11:52 +0000
Re: How to roll up multiple Line calls into a loop roby <roby.nowak@gmail.com> - 2011-04-23 11:52 +0000
Re: How to roll up multiple Line calls into a loop Yves Klett <yves.klett@googlemail.com> - 2011-04-24 12:24 +0000
Short-cut for reiteration, via postfix usage of Table as pure "Christopher O. Young" <cy56@comcast.net> - 2011-04-25 11:27 +0000
Short-cut for reiteration, via postfix usage of Table as pure "Christopher O. Young" <cy56@comcast.net> - 2011-04-25 11:27 +0000
Re: Short-cut for reiteration, via postfix usage of Table as pure Peter Pein <petsie@dordos.net> - 2011-04-26 10:51 +0000
Re: Short-cut for reiteration, via postfix usage of Table as pure Peter Pein <petsie@dordos.net> - 2011-04-26 10:50 +0000
Re: Short-cut for reiteration. Concise, readable symbols and "Christopher O. Young" <cy56@comcast.net> - 2011-04-27 09:38 +0000
csiph-web