I am trying to reproduce this element:
I am using these styles:
\usetikzlibrary{arrows.meta, bending, calc, chains, positioning,
shapes,patterns,decorations.pathmorphing,decorations.markings}
\tikzstyle{spring}=[thick,decorate,decoration={zigzag,pre
length=0.3cm,post length=0.3cm,segment length=6}]
\tikzstyle{damper}=[thick,decoration={markings,
mark connection node=dmp,
mark=at position 0.5 with
{
\node (dmp) [thick,inner sep=0pt,transform
shape,rotate=-90,minimum width=15pt,minimum
height=3pt,draw=none] {};
\draw [thick] ($(dmp.north east)+(2pt,0)$) -- (dmp.south east) --
(dmp.south west) -- ($(dmp.north west)+(2pt,0)$);
\draw [thick] ($(dmp.north)+(0,-5pt)$) -- ($(dmp.north)+
(0,5pt)$);
}
}, decorate]
\begin{tikzpicture}[
node distance = 0mm,
start chain = going right,
box/.style = {draw,
font=\linespread{0.75}\selectfont\small,
align=center, inner sep=2mm, outer sep=0pt,
on chain},
axs/.style = {draw, minimum width=12mm, minimum height=2mm,
inner sep=0pt, outer sep=0pt,
on chain, node contents={}},
arr/.style = {color=#1, line width=0.8mm,
shorten >=-1mm, shorten <=-1mm,
-{Stealth[length=1.6mm,width=3mm,flex=1.2]},
bend angle=60},
bar/.style = {draw, minimum width=0.1mm, minimum height=6mm,
inner sep=0pt, outer sep=0pt,
on chain, node contents={}},
]
I tried to use the solution given in Drawing Mechanical Systems in LaTeX.
But I was not able to find out a way to represent this element (maybe it can be useful to have a macro to insert it in the picture).
Exactly I would like to connect the left and right boxes created with:
\node (node_example) [box,label=below:$Example$] {example};
To my viscoelastic node just calling a macro that i can call as:
\node (new_node) [visco_elastic_node,....]{....}
What could I do?
Best Answer
The
spring
is stolen from Jake answer,damper
is drawn as small picturepic
, for rest of the image is used my answer on your previous question:Note (1): subscripts at arrows symbols are not correct, but this should not be problem to rewrite them ...
Note (2): If subscripts at variables J, C and
\theta
are descriptive text, i.e. not variables, they should be set upright (see lblb’s comment below). In this case (in all your equations ...) you should write$J_{\mathrm{M}}$
where theM
stands for Motore. Only variables should be italic in math. However, as far as I remember, literature about this topics is not very strict with this notation :-).