MathGroup Archive 2006

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

Search the Archive

Re: Plot a function on Time Scales

  • To: mathgroup at smc.vnet.net
  • Subject: [mg63588] Re: [mg63568] Plot a function on Time Scales
  • From: <bsyehuda at gmail.com>
  • Date: Fri, 6 Jan 2006 05:24:31 -0500 (EST)
  • References: <200601051102.GAA24336@smc.vnet.net> <76e8f8180601051431g36bf3066md7c68b92454a9831@mail.gmail.com>
  • Sender: owner-wri-mathgroup at wolfram.com

Hi,
It is better to add the PlotRange->All for DisplayTogether
yehuda

On 1/6/06, bsyehuda at gmail.com <bsyehuda at gmail.com> wrote:
>
> Hi,
> use the following code (it is working ok). The only warning is when you
> need two discrete points, then duplicate one of them so the length of the
> list will be at least three
>
> << Graphics`;
> f[x_] := x^2;
> genPoint =
>     Function[{func, points}, {Red, PointSize[0.01],
>         Point /@ ({#, func[#]} & /@ points)}];
> CreateMixedGraph[func_, range_] :=
>
>     DisplayTogether[
>       If[Length[#] == 2, Plot[f[x], {x, #[[1]], #[[2]]}],
>             Graphics[genPoint[func, #]]] & /@ range];
> CreateMixedGraph[f, {{-1, 1}, {2, 5, 8, 11}, {12, 20}}];
>
> Enjoy
> yehuda
>
> On 1/5/06, Unal Ufuktepe <unalufuktepe at iyte.edu.tr> wrote:
> >
> > Let f(x)=x^2 and I want to draw the graph of f on
> > T=[-1,1]U{2,5,8,11}U[12,20]
> > How can I plot this function on T with
> > Mathematica without spliting the graph?
> > Any idea? (I tried the PiecewisePlot but did not work with 5.2)
> > Thanks
> > nal
> > Ufuktepe,PhD
> > Izmir Institute of Technology
> > Department of Mathematics,
> > G=FClbahce-Urla, Izmir 35435
> > Phone:(232)-7507614
> >
> >
>



  • Prev by Date: Re: Plot a function on Time Scales
  • Next by Date: Re: Conditional drop of list elements
  • Previous by thread: Re: Plot a function on Time Scales
  • Next by thread: Re: Plot a function on Time Scales