答案1
很多时候我都会给人鱼钩,但今天我会给你一条鱼。我没有鱼钩了。
\documentclass[pstricks,border=20pt,12pt]{standalone}
\usepackage{pst-eucl,pst-plot}
\begin{document}
\pspicture[arrowinset=0,dimen=m,shortput=nab](9,8)
\pspolygon[fillstyle=vlines,hatchsep=1pt,linestyle=none](0,3)(0,0)(9,0)(9,-.2)(-.2,-.2)(-.2,3)
\psline(0,3)(0,0)(9,0)
\psframe(2,1)(6,3)\rput(4,2){$n$}\pcline{->}(6,2)(8,2)^{$u$}
\psRing*(3,.5){.5}{.1}\psRing*(5,.5){.5}{.1}
\pnodes(4,3){A}([offset=3.5,angle=-30]A){B}([offset=-1]B){C}
\cnodeput(B){M}{$m$}
\ncline{A}{M}_{$l$}
\ncline{->}{M}{C}\uput[-90](C){$mg$}
\pnodes(A|0,8){D}(B|D){E}([nodesep=-3.5]B){F}(F|A){G}
\psset{linestyle=dashed}
\psaxes[labels=none,ticks=none]{->}(0,3)(0,3)(9,8)[$x$,0][$y$,90]\uput[135](0,3){$0$}
\ncline[nodesepA=-1]{F}{M}
\pcline(F)(G)\ncput*{$l\cos\theta$}
\pcline(A)(D)\ncline{M}{E}
\psset{linestyle=solid}
\pstMarkAngle[MarkAngleRadius=1.5,arrows=<->]{B}{A}{D}{$\theta$}
\pcline(0,0|D)(D)^{$x$}
\pcline(D)(E)^{$l\sin\theta$}
\pcline{<-}(E)(9,0|E)^{$x$}
\endpspicture
\end{document}
各种各样的
一部只是为了好玩的动画。
\documentclass[pstricks,border=20pt,12pt]{standalone}
\usepackage{pst-eucl,pst-plot}
\begin{document}
\foreach \i in {20,25,...,50}{%
\pspicture[arrowinset=0,dimen=m,shortput=nab](9,8)
\pspolygon[fillstyle=vlines,hatchsep=1pt,linestyle=none](0,3)(0,0)(9,0)(9,-.2)(-.2,-.2)(-.2,3)
\psline(0,3)(0,0)(9,0)
\psframe(2,1)(6,3)\rput(4,2){$n$}\pcline{->}(6,2)(8,2)^{$u$}
\psRing*(3,.5){.5}{.1}\psRing*(5,.5){.5}{.1}
\pnodes(4,3){A}([offset=3.5,angle=-\i]A){B}([offset=-1]B){C}
\cnodeput(B){M}{$m$}
\ncline{A}{M}_{$l$}
\ncline{->}{M}{C}\uput[-90](C){$mg$}
\pnodes(A|0,8){D}(B|D){E}([nodesep=-3.5]B){F}(F|A){G}
\psset{linestyle=dashed}
\psaxes[labels=none,ticks=none]{->}(0,3)(0,3)(9,8)[$x$,0][$y$,90]\uput[135](0,3){$0$}
\ncline[nodesepA=-1]{F}{M}
\pcline(F)(G)\ncput*{$l\cos\theta$}
\pcline(A)(D)\ncline{M}{E}
\psset{linestyle=solid}
\pstMarkAngle[MarkAngleRadius=1.5,arrows=<->]{B}{A}{D}{$\theta$}
\pcline(0,0|D)(D)^{$x$}
\pcline(D)(E)^{$l\sin\theta$}
\pcline{<-}(E)(9,0|E)^{$x$}
\endpspicture}
\end{document}