[pstricks] question about pst-solides3d: projection on a plane
Clemens Schäfermeier
XC-lemens at web.de
Thu May 31 22:27:07 CEST 2012
Am 28.05.2012 20:01, schrieb Herbert Voss:
> Am 28.05.2012 11:30, schrieb Clemens Schäfermeier:
>> i can't see why it is possible to project the xsin function to the first
>> plane "monplane1" but it isn't to do this projection with ysin on
>> "monplane2". any hint is greatly appreciated!
>>
>> %%%%
>> \documentclass[a4paper]{article}
>> \usepackage{pstricks,pst-solides3d}
>
> you also need package pst-math . However, a better choice is
>
> \defFunction[algebraic]{ysin}(y){}{sin(x)}{}
>
> There is nothing to project on the plane [0 1 0 0]. Use
> another plane or change the viewpoint:
>
> \documentclass[a4paper]{article}
> \usepackage{pst-solides3d,pst-math}
> \begin{document}
>
> \psset{unit=1cm,viewpoint=20 60 20 rtp2xyz,lightsrc=28 55 25
> rtp2xyz,Decran=20}
>
> \begin{pspicture}[showgrid=false,solidmemory](-5,-5)(5,4)
> \defFunction[]{ysin}(y){}{y SIN}{}
>
> \psSolid[object=plan,definition=equation,
> args={[1 1 1 0] -22.5},name=monplane2]
> \psProjection[object=courbe,plan=monplane2,linecolor=green,range=-3 3,
> resolution=720,function=ysin]
>
> \end{pspicture}
>
> \end{document}
>
>
> Herbert
> _______________________________________________
> PSTricks mailing list
> PSTricks at tug.org
> http://tug.org/mailman/listinfo/pstricks
> archive: http://www.tug.org/pipermail/pstricks/
hi herbert,
thanks a lot for your reply. but the function i've "tried" to define was
(at least something like) z=f(x,y)=sin(x) which should be projectable on
a plane with the normalvector (x=0,y=1,z=0). if you plot a function like
that and think about the (x,z) plane, the projection is just the sine.
maybe i got the idea of this special psProjection thing wrong.
i could also repost my issue in other terms:
how to draw the following figure
\defFunction[]{xsin}(x){x SIN}{}{}
\psSolid[object=plan,
definition=equation,
args={[1 0 0 0] 90},
action=none,
name=monplane1]
\psProjection[object=courbe,
plan=monplane1,
linecolor=red,
range=-3 3,resolution=720,
function=xsin]
rotated by 90 degrees around the z-axis without changing the "global"
coordinate system?
best regards
clemens
More information about the PSTricks
mailing list