MathGroup Archive 2009

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

Search the Archive

Re: The Principle "Everything is an expression"

  • To: mathgroup at smc.vnet.net
  • Subject: [mg101227] Re: The Principle "Everything is an expression"
  • From: Armand Tamzarian <mike.honeychurch at gmail.com>
  • Date: Sat, 27 Jun 2009 06:04:02 -0400 (EDT)
  • References: <h2295n$hou$1@smc.vnet.net>

On Jun 26, 5:50 am, Alexey <lehi... at gmail.com> wrote:
> Hello,
>
> I think that the underlying principle "Everything is an expression" in
> Mathematica is great and is one of the most exciting advantages of the
> Mathematica system.
>
> But it is disappointing that this principle is still fails even on
> such basic example as representation of a simple Plot. Consider the
> following:
>
> g = Plot[Sin[x], {x, 0.2, 10}]
> Show[FullGraphics[g], AspectRatio -> 1/GoldenRatio]
>
> It is clear that the two generated images are significantly different.
> This means that the function FullGraphics[] does not gives the true
> expression-representation of the first plot. Is it true that in really
> we can not get the true representation of the plot as an expression?
> And the principle mentioned really fails even on this? Or there is
> another way to get it?
>
> Thank you for your attention a priori.

Not sure I follow you. FullGraphics definition in the documentation
says: "takes a graphics object, and generates a *new* one in which
objects specified by graphics options are given as explicit lists of
graphics primitives."

So it is a different (under the hood) representation. I'm guessing
what you really want is FullForm[g]??? This gives you the expression-
representation of the first plot.

g, i.e. your Plot, is an expression ...you can do stuff with it: g /.
Hue[_, _, _] -> RGBColor[1, 0, 0]

Mike


  • Prev by Date: Re: The Principle "Everything is an expression"
  • Next by Date: Re: interpolation and to extract between 3D plots
  • Previous by thread: Re: The Principle "Everything is an expression"
  • Next by thread: Re: The Principle "Everything is an expression"