2

I need help drawing the following systems in Latex for a paper. I am no tikz expert so it is beyond my capabilities at the moment. Schematic drawing of the systems Any help is appreciated.

This is how far I managed with the help of the tips below

    \documentclass[10pt]{article}  

\usepackage{tikz}
\usetikzlibrary{calc,,patterns,decorations.pathmorphing,decorations.markings}
\usetikzlibrary{positioning}

\usepackage{pgfplots}

\begin{document}

\begin{tikzpicture}
\tikzstyle{ground}=[fill,pattern=north east lines,draw=none,minimum width=4em,minimum height=1em]

\node[draw, minimum width=12em,minimum height=1em, inner sep=0] (S1) at (0,0){cap};
\path (S1.south west) -- (S1.south east) coordinate[pos=0.05](p1) coordinate[pos=0.9](p2)coordinate[pos=0.5](c1);

% left leg
\node[draw, minimum width=1em,minimum height=8em,  yshift=0em, xshift=-0.05em, inner sep=0,below=-0.05em of p1 ] (S2){};
% ground at left leg
\node (ground1) at (S1.south) [ground,yshift=-8em,xshift=-5.5em,anchor=north] {};
\draw (ground1.north west) -- (ground1.north east);

% right leg
\node[draw, minimum width=1em,minimum height=8em, yshift=0em,xshift=0.7em, inner sep=0,below=-0.05em of p2 ] (S3){};
% ground at left leg
\node (ground2) at (S1.south) [ground,yshift=-8em,xshift=5.5em,anchor=north] {};
\draw (ground2.north west) -- (ground2.north east);

\node[draw, minimum width=1em,minimum height=12em, inner sep=0,below=0em of c1 ] (S4){L};

\node[draw, minimum width=1em,minimum height=12em, inner sep=0,below=0em of c1, rotate around={10:(c1)},dashed] (S4){$ \theta $};

 \draw[-latex, thick] (0.70,-4.25) -- node[above] {$\large\mathsf{F_w}$} +(1.5,0);

\end{tikzpicture}
%%%%%%%%%%%%%%%
\vspace{2cm}

\begin{tikzpicture}
\tikzstyle{ground}=[fill,pattern=north east lines,draw=none,minimum width=4em,minimum height=1em]
\tikzstyle{spring}=[thick,decorate,decoration={zigzag,pre length=0.3cm,post length=0.3cm,segment length=6}]

\node[draw, minimum width=12em,minimum height=1em, dashed, inner sep=0] (S1) at (0,0){cap};
\path (S1.south west) -- (S1.south east) coordinate[pos=0.05](p1) coordinate[pos=0.9](p2)
coordinate[pos=0.5](c1);

\node[draw, minimum width=12em,minimum height=1em,  inner sep=0] (S1b) at (1em,0){ };
\path (S1b.south west) -- (S1b.south east) coordinate[pos=0.05](p1b) coordinate[pos=0.9](p2b)
coordinate[pos=0.5](c1b);

\path (S1.south west) -- (S1.south east) 
coordinate[pos=0.05](p3) coordinate[pos=0.9](p4) coordinate[pos=0.5](c2);

% left leg
%\node[draw, minimum width=1em,minimum height=8em,  yshift=0em, xshift=-0.05em, inner sep=0,below=-0.05em of p1 ] (S2){};
% ground at left leg
\node (ground1) at (S1.south) [ground,yshift=-8em,xshift=-5.5em,anchor=north] {};
\draw (ground1.north west) -- (ground1.north east);
\draw [spring](ground1.north) -- ($(S1b.south east)!(ground1.north)!(S1b.south west)$);

% right leg
%\node[draw, minimum width=1em,minimum height=8em, yshift=0em,xshift=0.7em, inner sep=0,below=-0.05em of p2 ] (S3){};
% ground at left leg
\node (ground2) at (S1.south) [ground, yshift=-8em,xshift=5.5em, anchor=north] {};
\draw (ground2.north west) -- (ground2.north east);
\draw [spring](ground2.north) -- ($(S1b.south east)!(ground2.north)!(S1b.south west)$);


\node[draw, minimum width=1em,minimum height=12em, dashed, inner sep=0,below=0em of c1 ] (S4){};

\node[draw, minimum width=1em,minimum height=12em, yshift=0.35em,xshift=2.0em, inner sep=0,below=0em of c1, rotate around={-10:(c2)}] (S4){$ \theta $};

\draw[-latex, thick] (2,0) -- node[above] {$\large\mathsf{F_x}$} +(1.5,0);
\draw[-latex, thick] (0,0.15) -- node[right] {$\large\mathsf{F_y}$} +(0,1.0);

\end{tikzpicture}
%%%%%%%%%%%%%%%

\vspace{2cm}
%%%%%%%%%%%%%%%%%%%%%%
\begin{tikzpicture}
\tikzstyle{ground}=[fill,pattern=north east lines,draw=none,minimum width=4em,minimum height=1em]
\tikzstyle{spring}=[thick,decorate,decoration={zigzag,pre length=0.3cm,post length=0.3cm,segment length=6}]

\node[draw, minimum width=12em,minimum height=1em, inner sep=0] (S1) at (0,0){cap};
path (S1.south west) -- (S1.south east) coordinate[pos=0.1](p1)
 coordinate[pos=0.9](p2)coordinate[pos=0.5](c1);


% left leg
\node[draw, minimum width=1em,minimum height=8em,  yshift=0em, xshift=-0.05em, inner sep=0,below=-0.05em of p1 ] (S2){};
% ground at left leg
\node (ground1) at (S1.south) [ground,yshift=-8em,xshift=-5.5em,anchor=north] {};
\draw (ground1.north west) -- (ground1.north east);

% right leg
\node[draw, minimum width=1em,minimum height=8em, yshift=0em,xshift=0.7em, inner sep=0,below=-0.05em of p2 ] (S3){};
% ground at left leg
\node (ground2) at (S1.south) [ground,yshift=-8em,xshift=5.5em,anchor=north] {};
\draw (ground2.north west) -- (ground2.north east);


%\node[ minimum width=1em,minimum height=8em, inner sep=0, below=0em of c1 ] (S4){};
\draw [spring](c1) -- ($(S1.south east)!(c1)!(S1.south west)$);
%\node[ minimum width=1em,minimum height=8em, inner sep=0,below=0em of c1, rotate around={15:(c1)}] (S4b){};

%\draw[decoration={zigzag,amplitude=1em},decorate] (S4.north) -- (S4.south);
%\draw[decoration={zigzag,amplitude=1em},decorate] (S4b.north) -- (S4b.south);

%\node[ minimum width=1em,minimum height=8em, inner sep=0,below=0em of S4.south,draw ] (S5){};
%\node[ minimum width=1em,minimum height=8em, inner sep=0,below=0em of S4b.south, draw ] (S5){};

\end{tikzpicture}
%%%%%%%%%%%%%%%%%%%%%%%%%

\end{document}

Specific questions

  1. How to add tilt to the springs?
  2. how to complete figure 3?
  • 1
    Welcome I think this question tex.stackexchange.com/questions/13933/… is what you want right? – percusse Jun 2 '15 at 16:08
  • Yes, It's very similar to what I need in terms of quality. – Dimiter P Jun 2 '15 at 16:09
  • 3
    So can we close this question then? – percusse Jun 2 '15 at 16:23
  • No. The systems are obviously different as you can see from my drawing. I cant' make it myself. – Dimiter P Jun 2 '15 at 16:27
4

a proposal for the first two diagrams the third should be easily

\documentclass[10pt]{article}  

\usepackage{tikz}
\usetikzlibrary{calc,decorations}
\usetikzlibrary{positioning}

\usepackage{pgfplots}


\begin{document}

\begin{tikzpicture}
\node[draw, minimum width=12em,minimum height=1em, inner sep=0] (S1) at (0,0){};
\path (S1.south west) -- (S1.south east) coordinate[pos=0.1](p1) coordinate[pos=0.9](p2)coordinate[pos=0.5](c1);
\node[draw, minimum width=1em,minimum height=8em, inner sep=0,below=0em of p1 ] (S2){};
\node[draw, minimum width=1em,minimum height=8em, inner sep=0,below=0em of p2 ] (S3){};

\node[draw, minimum width=1em,minimum height=12em, inner sep=0,below=0em of c1 ] (S4){};
\node[draw, minimum width=1em,minimum height=12em, inner sep=0,below=0em of c1, rotate around={10:(c1)},dashed] (S4){};

\end{tikzpicture}
\begin{tikzpicture}
\node[draw, minimum width=12em,minimum height=1em, inner sep=0] (S1) at (0,0){};
\path (S1.south west) -- (S1.south east) coordinate[pos=0.1](p1) coordinate[pos=0.9](p2)coordinate[pos=0.5](c1);
\node[draw, minimum width=1em,minimum height=8em, inner sep=0,below=0em of p1 ] (S2){};
\node[draw, minimum width=1em,minimum height=8em, inner sep=0,below=0em of p2 ] (S3){};

\node[ minimum width=1em,minimum height=8em, inner sep=0,below=0em of c1 ] (S4){};
\node[ minimum width=1em,minimum height=8em, inner sep=0,below=0em of c1, rotate around={15:(c1)}] (S4b){};

\draw[decoration={zigzag,amplitude=1em},decorate] (S4.north) -- (S4.south);
\draw[decoration={zigzag,amplitude=1em},decorate] (S4b.north) -- (S4b.south);

\node[ minimum width=1em,minimum height=8em, inner sep=0,below=0em of S4.south,draw ] (S5){};
\node[ minimum width=1em,minimum height=8em, inner sep=0,below=0em of S4b.south, draw ] (S5){};

\end{tikzpicture}

\end{document}

enter image description here

2
\documentclass[tikz,border=2mm]{standalone}
\usepackage{pgfplots}
\pgfplotsset{compat=newest}

\begin{document}
    \begin{tikzpicture}
        \pgfmathsetmacro{\angle}{7};
        \draw (0,0) rectangle (1,5);
        \draw (-1,0) -- (2,0);
        \draw (10,0) rectangle (11,5);
        \draw (9,0) -- (12,0);
        \draw (0,5) rectangle (11,6);
        \draw (-2,-2) .. controls (-1,-2) and (0,-1) .. (3,-1) .. controls (10,-1) and (10.5,-2) .. (13,-2);

        \draw[dashed] (5.75,5) rectangle (5.25,-5);
        \draw[-latex, ultra thick] (3.5,-4) -- node[above] {\Large\sffamily$\mathsf{Fw}$} +(1.5,0);
        \draw (5.75,5) -- (5.25,5) -- ++({270+\angle}:10) -- node[below] {$\mathsf{theta}$} ++(\angle:0.5) -- cycle;
        \node[font=\Huge\sffamily] at (3,3) {$\mathsf{L}$};
    \end{tikzpicture}

    \begin{tikzpicture}
        \draw (0,0) rectangle (1,5);
        \draw (-1,0) -- (2,0);
        \draw (10,0) rectangle (11,5);
        \draw (9,0) -- (12,0);
        \draw (0,5) rectangle (11,6);
        \draw (-2,-2) .. controls (-1,-2) and (0,-1) .. (3,-1) .. controls (10,-1) and (10.5,-2) .. (13,-2);

        \draw (5.75,-.5) rectangle (5.25,-7);
        \draw[dashed] (7.25,-.5) rectangle (6.75,-7);
        \draw[decorate, decoration={zigzag,amplitude=6pt}] (5.5,5) -- (5.5,-.5);
        \draw[decorate, decoration={zigzag,amplitude=6pt}, dashed] (5.5,5) -- (7,-.5);
        \draw[-latex, ultra thick] (3,-5) node[above] {\Large\sffamily$\mathsf{Fx}$} -- +(1.5,0);
        \draw[-latex, ultra thick] (4.5,2) -- +(0,1.5);
        \node[font=\Huge\sffamily] at (4.5,-6) {$\mathsf{L}$};
    \end{tikzpicture}

    \begin{tikzpicture}
        \draw[decorate, decoration={zigzag,amplitude=10pt,segment length=30pt}] (0,5) -- node[midway, xshift=-30pt, font=\sffamily] {$\mathsf{k}$} (0.5,0);
        \draw (-1,0) -- (2,0);
        \draw[decorate, decoration={zigzag,amplitude=10pt,segment length=30pt}] (10,5) -- node[midway, xshift=30pt, font=\sffamily] {$\mathsf{k}$} (10.5,0);
        \draw (9,0) -- (12,0);
        \draw (0,5) rectangle (11,6);
        \draw (-2,-2) .. controls (-1,-2) and (0,-1) .. (3,-1) .. controls (10,-1) and (10.5,-2) .. (13,-2);

        \draw[dashed] (5.75,5) rectangle (5.25,-5);
        \draw (6.75,5) node[below right] {$\mathsf{theta}$} -- (5.75,-5) -- (5.25,-5) -- (6.25,5);
        \draw[-latex, ultra thick] (4.5,-3) -- (4.65,-1.5);
        \draw[-latex, ultra thick] (4,6.9) node[left] {$\mathsf{Fx}$} -- +(1.5,0);
        \draw[-latex, ultra thick] (4,7) -- +(0,1.5) node[left] {$\mathsf{Fy}$};
    \end{tikzpicture}
\end{document}

enter image description here

enter image description here

enter image description here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.