Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.soft-sys.math.mathematica > #4216
| From | Helen Read <readhpr@gmail.com> |
|---|---|
| Newsgroups | comp.soft-sys.math.mathematica |
| Subject | Re: Can a Locator be Made to Track a Curve? |
| Date | 2011-08-08 08:23 +0000 |
| Organization | Steven M. Christensen and Associates, Inc and MathTensor, Inc. |
| Message-ID | <j1o6ek$4ig$1@smc.vnet.net> (permalink) |
| References | <201108060612.CAA13010@smc.vnet.net> <j1loki$nlf$1@smc.vnet.net> |
You might like to add a PlotLabel showing the coordinates.
f[x_] := Sin[x];
pt = {0, 0};
LocatorPane[Dynamic[pt, (pt[[1]] = #[[1]]; pt[[2]] = f[#[[1]]]) &],
Plot[Sin[x], {x, 0, 2 Pi}, PlotLabel -> Dynamic[pt]]]
HPR
P.S. -- Grumpy OT Aside: When did everyone in the world become
top-posters? I'm finding it everywhere...newsgroups, email from family,
friends, co-workers, basically everyone. For years I used to rearrange
it back to traditional bottom-posting when replying to something that
was top-posted, but top-posting has become so prevalent that I have
given up. Did I miss the memo that top-posting is now preferred?
On 8/7/2011 6:15 AM, Heike Gramberg wrote:
> You could do something like
>
> f[x_] := Sin[x];
> pt = {0, 0};
> LocatorPane[Dynamic[pt, (pt[[1]] = #[[1]]; pt[[2]] = f[#[[1]]])&],
> Plot[Sin[x], {x, 0, 2 Pi}]]
>
> Heike
>
> On 6 Aug 2011, at 08:12, Gregory Lypny wrote:
>
>> Hello everyone,
>>
>> Can a locator be constrained so that it tracks a curve?
>>
>> Regards,
>>
>> Gregory
>>
>
>
Back to comp.soft-sys.math.mathematica | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Re: Can a Locator be Made to Track a Curve? Heike Gramberg <heike.gramberg@gmail.com> - 2011-08-07 10:15 +0000 Re: Can a Locator be Made to Track a Curve? Helen Read <readhpr@gmail.com> - 2011-08-08 08:23 +0000 Re: Bottom and Top Posting "David Park" <djmpark@comcast.net> - 2011-08-09 11:18 +0000 Re: Can a Locator be Made to Track a Curve? DrMajorBob <btreat1@austin.rr.com> - 2011-08-09 11:20 +0000
csiph-web