Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.soft-sys.math.maple > #1344

Re: marking each curve in a 2-D plot

Newsgroups comp.soft-sys.math.maple
Date 2019-05-05 16:40 -0700
References <e31728b2-1081-4f79-b065-e174fbb95433@googlegroups.com> <qaga7n$n1j$1@dont-email.me>
Message-ID <ca484c18-862a-4d10-bd97-a346cc89770d@googlegroups.com> (permalink)
Subject Re: marking each curve in a 2-D plot
From jfh <john.harper@vuw.ac.nz>

Show all headers | View raw


On Friday, May 3, 2019 at 2:49:28 PM UTC+12, none Rouben Rostamian wrote:
> In article <e31728b2-1081-4f79-b065-e174fbb95433@googlegroups.com>,
> jfh  <john.harper@vuw.ac.nz> wrote:
> >This little two-line Maple program draws two curves y=f(x,H) on the same
> >(x,y) plane with different values of the variable H.
> >
> >f:=(x,H)->(cos(x)*exp(H*cos(x)));
> >plot([f(x,0.2),f(x,1)], x=0..2*Pi,scaling=constrained);
> >
> >How does one get the value of H written halfway along its own curve at
> >the point 
> >[Pi,f(Pi,H)] ? I am using Maple 2017 (X86 64 LINUX).
> 
> Give a name to that plot, as in:
> restart;
> with(plots):
> f:=(x,H)->(cos(x)*exp(H*cos(x)));
> p := plot([f(x,0.2),f(x,1)], x=0..2*Pi,scaling=constrained);
> 
> Then add text:
> display([p,
>   textplot([Pi,f(Pi,0.2), typeset(H = 0.2)], align=below),
>   textplot([Pi,f(Pi,1.0), typeset(H = 1.0)], align=above)]);
> 
> The result is not great because the added text overlaps with
> the axis labels, making a mess.  It's better to add the text
> at the far right, as in
> display([p,
>   textplot([2*Pi,f(2*Pi,0.2), typeset(H = 0.2)], align=right),
>   textplot([2*Pi,f(2*Pi,1.0), typeset(H = 1.0)], align=right)]);
> 
> 
> -- 
> Rouben Rostamian

Thank you. My problem was that none of ?plot ?plot/details or ?plot/options led to textplot or warn me that with(plots) and display were needed.

Back to comp.soft-sys.math.maple | Previous | NextPrevious in thread | Find similar


Thread

marking each curve in a 2-D plot jfh <john.harper@vuw.ac.nz> - 2019-05-02 18:37 -0700
  Re: marking each curve in a 2-D plot rouben@x301-3.(none) (Rouben Rostamian) - 2019-05-03 02:49 +0000
    Re: marking each curve in a 2-D plot jfh <john.harper@vuw.ac.nz> - 2019-05-05 16:40 -0700

csiph-web