# System Theory Block

I'm currently working on my Bachelor's Thesis and writing using Latex. I think it is a very handy tool and text as well as tikz figures just look so much better, provided you have a nice template.

What I'm currently trying to achieve is a tikz figure as follows. I think it compromises a lot of things that I will certainly need for further figures. It would be great if someone would help out ! I am currently stuck and can only display the two system blocks process and model ...

Thank you very much :)

There are some softwares you can draw and it give to you the tikz code. KtikZ is one of those. Other is GeoGebra.

I use other, named TikzEdt, that you can insert some full code that software give to us. And we can write in tikz and, if is well coded, will show the result side of code.

With code below I have this output.

\usetikzlibrary{arrows, decorations.markings}

% for double arrows
% adapt line thickness and line width, if needed
\tikzstyle{processo} = [%
rectangle,
minimum width=3cm,
minimum height=1cm,
text centered,
draw=black,
text width=3cm,
fill=orange!30]
\tikzstyle{vecArrow} = [thick, decoration={markings,mark=at position
1 with {\arrow[semithick]{open triangle 60}}},
double distance=1.4pt, shorten >= 5.5pt,
preaction = {decorate},
postaction = {draw,line width=1.4pt, white,shorten >= 4.5pt}]
\tikzstyle{vecArrowB} = [thick,
double distance=1.4pt, shorten >= -1pt,
preaction = {decorate},
postaction = {draw,line width=1.4pt, white,shorten >= 4.5pt}]
\tikzstyle{innerWhite} = [semithick, white,line width=1.4pt, shorten >= 4.5pt]

\begin{tikzpicture}[thick]
\node(a) {u(i)};
\node[inner sep=0,minimum size=0,right of=a] (k) {}; % invisible node
\node[draw,processo,right of=k,yshift=1.5cm,xshift=2cm] (b) {process};
\node[draw,processo,right of=k,yshift=-1.5cm,xshift=2cm] (c) {model f(u,$\theta$)};
\node[draw,circle,right of = b,xshift=2cm] (d) {};
\node[inner sep=0,minimum size=0,above of=d,yshift=0.5cm] (e) {}; % invisible node
\node[draw,circle,right of=d,xshift=0.5cm,yshift=-1.5cm] (f) {}; % invisible node
\node[above of=f,yshift=-1.4cm,xshift=-0.1cm] (g) {-};
\node[above of=f,xshift=1.5cm,yshift=-1cm] (g) {}; %invisible node

% 1st pass: draw arrows
\draw[vecArrowB] (a) to (k);
\draw[vecArrow] (k) |- (b);
\draw[vecArrow] (k) |- (c);
\draw[arrows=->] (b)  -- node[above]{$y_u(i)$} (d);
\draw[arrows=->] (e) -- node[left,yshift=0.3cm]{$n(i)$} (d);
\draw[arrows=->] (d) node[above,xshift=1cm]{$y(i)$} -| (f);
\draw[arrows=->] (c) node[below,xshift=4cm]{$\hat{y}(i)$} -| (f);
\draw[arrows=->] (f) -- node[above]{$e(i)$} (g);

% 2nd pass: copy some from 1st pass, and replace vecArrow with innerWhite
\draw[innerWhite] (a) -- (k);
\draw[innerWhite] (k) |- (b);
\draw[innerWhite] (k) |- (c);

% Note: If you have no branches, the 2nd pass is not needed
\end{tikzpicture}

• Hi ! Thank you very much :) However, why are the lines on the left not connected where u(i) is split ? – aladin Dec 26 '19 at 19:20

I prefer to use cirkuiTikz.

The image at the bottom is achived with:

\documentclass[12pt]{standalone}
\usepackage{circuitikz}
\begin{document}
\begin{circuitikz}
\draw (0,0)
to[short]++(2,0)
to[short]++(0,1)