But try some code as follows; tweak as you like:

x = var('x')
g1 = plot(sin(x), 0, 2*pi, rgbcolor=(0,0,1))
g2 = plot(cos(x), 0, 2*pi, rgbcolor=(1,0,0), linestyle = "--")
g1 + g2    # show their sum

See attached file.

Dean

---

On Feb 16, 2008 11:49 AM, William Stein <[EMAIL PROTECTED]> wrote:

>
> On Feb 16, 2008 10:21 AM, D. M. Monarres <[EMAIL PROTECTED]> wrote:
> >
> > Hello all,
> >
> > First of all, I would like to thank all of the sage developers. Sage
> > has been a very useful tool for both graduate work and teaching.
> >
> > I have a question about plotting. The plot function allows for a list
> > of functions as an argument, is there any way that I could specify
> > the plot colors for each of the curves.
>
> No, this is not implemented yet.
>
>  -- William
>
> > For example, when I would
> > want to talk about graph transformations in lecture I would like to
> > show the original graph in blue and a scaled graph in red.
> >
> > I know about using the + operator with graphs and use that when I am
> > constructing graphs for myself but when I am in class I think my
> > students get distracted when there is too much code on the screen.
> >
> > What I am thinking about is something like
> >
> >
> > sage: f(x) = x^2
> > sage: g(x) = (x-5)^2
> >
> >
> > sage: plot( [f,g], (x,-10,10), rgbcolor= [ (0,0,1) , (1,0,0) ] )
> >
> > (but I know that this doesn't work.
> >
> > Am I missing something obvious?
> >
> >
> >
> > --
> > David Monarres
> > [EMAIL PROTECTED]
> >
> > Nothing takes the taste out of peanut butter quite like unrequited love.
> >                  -- Charlie Brown
> >
> >
> > >
> >
>
>
>
> --
> William Stein
> Associate Professor of Mathematics
> University of Washington
> http://wstein.org
>
> >
>

--~--~---------~--~----~------------~-------~--~----~
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sage-support
URLs: http://www.sagemath.org
-~----------~----~----~----~------~----~------~--~---

<<inline: sage_image_two_graphs.png>>

Reply via email to