[PD] Graph a circle arc in an array?

Tyler Leavitt thecryoflove at gmail.com
Sun Apr 10 18:48:59 CEST 2011


Using the sqrt(r^2-x^2) formula I get the same results as with the [sin],
[cos]. Maybe I'm just implementing it wrong, but I can't figure out why it's
not plotting the correct y values...

Here's the patch I sent before with my implementation of the sqrt(r^2 - x^2)

On Sun, Apr 10, 2011 at 8:52 AM, Mathieu Bouchard <matju at artengine.ca>wrote:

> On Sun, 10 Apr 2011, Tyler Leavitt wrote:
>
>  I've not had any real success using the formulas with [sin] and [cos]...
>>
>
> I don't know why, but I had assumed that you wanted to plot something
> "parametrically", such as a path drawn from x(t) and y(t) functions, instead
> of a y(x) function. I was reading too fast.
>
> For a y(x) function, sqrt(r*r-x*x) is the formula to use.
>
> That is related to the fact that sqrt(1-x*x) = sin(acos(x)) = cos(asin(x))
> where asin is anti-sin and acos is anti-cos.
>
> It's also related to Pythagoras' theorem x*x + y*y = r*r which is also
> sin(t)*sin(t) + cos(t)*cos(t) = 1.
>
>
>  _______________________________________________________________________
> | Mathieu Bouchard ---- tél: +1.514.383.3801 ---- Villeray, Montréal, QC
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.puredata.info/pipermail/pd-list/attachments/20110410/38915e40/attachment-0001.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: circlearc.pd
Type: text/x-puredata
Size: 11205 bytes
Desc: not available
URL: <http://lists.puredata.info/pipermail/pd-list/attachments/20110410/38915e40/attachment-0001.bin>


More information about the Pd-list mailing list