# [pstricks] drawing inverses

Dougherty, Michael michael.dougherty at swosu.edu
Mon Jun 12 18:56:59 CEST 2006

Well thanks for the thanks, but also apologies to all as I was in a hurry and not only wasn't precise, but got a couple things wrong.  Just for the record, I meant plot the x-coordinate as your function, and also I guess my graph didn't actually have the y=sin x part graphed on the example I yanked.  I guess what I should have said was obvious enough in context.

I have to say, I love pstricks.  I'm working on a calculus book and pstricks lets me do it all in the code, without importing anything.  (It won't be a 4-color, US$165 book like some, but will have lots of functions plotted, thanks to pstricks!) --Mike D. http://faculty.swosu.edu/michael.dougherty/book/book.html -----Original Message----- From: pstricks-bounces at tug.org on behalf of Thushyanthan Baskaran Sent: Mon 6/12/2006 5:50 AM To: Graphics with PSTricks Subject: Re: [pstricks] drawing inverses Hi, man thanks for your suggestions... The \parametricplot command did the trick :). Regards, Thushy Dougherty, Michael wrote: > Use the parametric plot and have the function be the y-value. Where you originally graphed with > \psplot{xmin}{xmax}{f(x)} > now you do > \parametricplot{tmin}{tmax}{f(t) t} > It knows that there will be two outputs, kind of like a stack that ends up with two entries after all the unary and binary operations. > > For an example, let me be lazy and copy something from a book I'm writing, where you have sin x and arcsin x graphed together. I probably could take some shortcuts but it's what I have on file. > > --Mike Dougherty > > \begin{pspicture}(-2,-4)(2,4) > \psset{yunit=.5cm} > \psaxes[Dy=20]{<->}(0,0)(-2,-8)(2,8) > \parametricplot[linecolor=gray,% > plotpoints=2000]{-8}{8}{t 180 mul 3.14159265 div sin t} > \parametricplot[plotpoints=100,linewidth=2pt]% > {-1.5708}{1.5708}{t 180 mul 3.14159265 div sin t} > \psline(-.2,-3.1415)(.2,-3.1415) > \psline(-.2,3.1415)(.2,3.1415) > \rput[l](.3,-3.1415){$-\pi$} > \rput[l](.3,3.1415){$\pi$} > > \psline(-.2,-6.28)(.2,-6.28) > \psline(-.2,6.28)(.2,6.28) > \rput[l](.3,-6.28){$-2\pi$} > \rput[l](.3,6.28){$2\pi\$}
> \pscircle[fillcolor=black,fillstyle=solid](1,1.5708){.07}
> \pscircle[fillcolor=black,fillstyle=solid](-1,-1.5708){.07}
> \end{pspicture}
>
>
>
> -----Original Message-----
> From: pstricks-bounces at tug.org on behalf of Thushyanthan Baskaran
> Sent: Sun 6/11/2006 1:36 PM
> To: pstricks at tug.org
> Subject: [pstricks] drawing inverses
>
>
>
> Hi,
>
> I would like to draw a function and its inverse together on a graph.
> However, since my original function cannot be solved explicitly for the
> dependent variable, I do not have an explicit function that I could use
> with psplot. Is there any other solution for drawing inverses?
>
>
> _______________________________________________
> pstricks mailing list
> pstricks at tug.org
> http://tug.org/mailman/listinfo/pstricks
>
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> pstricks mailing list
> pstricks at tug.org
> http://tug.org/mailman/listinfo/pstricks

--
Philipps-University Marburg
Department of Public Finance

Phone: +49-6421-282 3173
Fax:   +49-6421-282 4852
_______________________________________________
pstricks mailing list
pstricks at tug.org
http://tug.org/mailman/listinfo/pstricks

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/ms-tnef
Size: 4228 bytes
Desc: not available
Url : http://tug.org/pipermail/pstricks/attachments/20060612/41464ec3/attachment.bin