[pstricks] new diagram + psmatrix

s khan khan62901 at hotmail.com
Wed Jun 14 00:37:26 CEST 2006


Herbert:
Excellent!!! Thank you very very much. This is what I wanted. ---Khan



>s khan wrote:
>
> > Thanks. If we view the pdf file of the following code, we see that some
> > arrows are on the boxes, which looks ugly!
> >
> > What I want is: the three-left-arrow heads should be on the ?left sides?
> > of the left boxes and the ?right sides? of the right boxes.
> >
> > If possible, I want all the arrows generated from one point of the
> > bottom side of the top box.
>
>-- put the psmatrix first in a box
>-- write it with arrows
>-- write it again without the arrows to get the boxes
>     over the arrows
>-- use always \ncdiag
>
>Herbert
>
>
>\documentclass[a4paper]{article}
>
>\usepackage{pstricks}
>\usepackage{pst-node,graphicx}
>\definecolor{Pink}{rgb}{1.,0.75,0.8}
>\pagestyle{empty}
>\setlength\parindent{0pt}
>\newsavebox\PBox
>\begin{document}
>\psset{linearc=0} % it makes a round corner of connection link
>
>\savebox\PBox{%
>\begin{psmatrix}[rowsep=1cm,colsep=.5cm]
>& \psshadowbox[linearc=5mm,fillstyle=solid,fillcolor=Pink]
>     { \begin{tabular}{c}
>     $ f1  = a \, q_1 + b \, q_2 $ \\
>     $ f2  = c \, q_1 + d \, q_2 $ \\
>     \end{tabular} }  &   \\% end of 1st row
>\psshadowbox[linearc=5mm,shadow=true,fillstyle=solid,fillcolor=Pink]{
>\begin{tabular}{c}
>$L_1 = t (q_1+ q_2)\dot{q}_1 - \dot{q}_2 + \frac{dg}{dt}  $ \\
>when $a=0, b=1, c=2, d=1$
>\end{tabular}
>}
>& &
>\psshadowbox[linearc=5mm,shadow=true,fillstyle=solid,fillcolor=Pink]{
>\begin{tabular}{c}
>$L_1 = t (q_1+ q_2)\dot{q}_1 - \dot{q}_2 + \frac{dg}{dt}  $ \\
>when $a=0, b=1, c=2, d=1$
>\end{tabular}
>} \\
>\psshadowbox[linearc=5mm,shadow=true,fillstyle=solid,fillcolor=Pink]{
>\begin{tabular}{c}
>$L_1 = t (q_1+ q_2)\dot{q}_1 - \dot{q}_2 + \frac{dg}{dt}  $ \\
>when $a=0, b=1, c=2, d=1$
>\end{tabular}
>}
>& &
>\psshadowbox[linearc=5mm,shadow=true,fillstyle=solid,fillcolor=Pink]{
>\begin{tabular}{c}
>$L_1 = t (q_1+ q_2)\dot{q}_1 - \dot{q}_2 + \frac{dg}{dt}  $ \\
>when $a=0, b=1, c=2, d=1$
>\end{tabular}
>} \\
>\psshadowbox[linearc=5mm,shadow=true,fillstyle=solid,fillcolor=Pink]{
>\begin{tabular}{c}
>$L_1 = t (q_1+ q_2)\dot{q}_1 - \dot{q}_2 + \frac{dg}{dt}  $ \\
>when $a=0, b=1, c=2, d=1$
>\end{tabular}
>}
>& &
>\psshadowbox[linearc=5mm,shadow=true,fillstyle=solid,fillcolor=Pink]{
>\begin{tabular}{c}
>$L_1 = t (q_1+ q_2)\dot{q}_1 - \dot{q}_2 + \frac{dg}{dt}  $ \\
>when $a=0, b=1, c=2, d=1$
>\end{tabular}
>}
>\end{psmatrix}}%
>\rput[lt](0,0){\usebox\PBox}%
>%\rput[lt](0,0){\resizebox{\linewidth}{!}{\usebox\PBox}}% alternative
>\psset{linewidth=1.5pt,arrowsize=7pt,angleA=-90,arm=0}%
>\ncdiag{->}{1,2}{4,1}%
>\ncdiag[angleB=180]{->}{1,2}{4,3}%
>%
>\ncdiag{->}{1,2}{3,1}%
>\ncdiag[angleB=180]{->}{1,2}{3,3}%
>%
>\ncdiag{->}{1,2}{2,1}%
>\ncdiag[angleB=180]{->}{1,2}{2,3}%
>\rput[lt](0,0){\usebox\PBox}%
>%\rput[lt](0,0){\resizebox{\linewidth}{!}{\usebox\PBox}}% alternative
>
>\end{document}
>
>
>
>_______________________________________________
>pstricks mailing list
>pstricks at tug.org
>http://tug.org/mailman/listinfo/pstricks

_________________________________________________________________
Don’t just search. Find. Check out the new MSN Search! 
http://search.msn.click-url.com/go/onm00200636ave/direct/01/




More information about the PSTricks mailing list