How to make this graphics?

I can to do this

\begin{center}
\begin{tikzpicture}
\fill [red!50, domain=1:3, variable=\x]
(1, 0)
-- plot ({\x}, {2.2/(\x)})
-- (3, 0)
-- cycle;      \draw[->] (-1,0) -- (7,0) node[right] {$x$};
\draw[->] (0,-1) -- (0,4) node[above] {$y$};
\draw[scale=1.5,domain=0.35:4,smooth, variable=\x,black, ultra thick] plot ({\x},{1/(\x)});
\draw[dashed] (3,0)--(3,0.75);
\draw[dashed] (0,0.75)--(3,0.75);
\node at (-0.5,0.75){$\frac{1}{b}$};
\node at (3,-0.3){$b$};
\node at (1,-0.3){$a$};
\node at (-0.5,2.2) {$\frac{1}{a}$};
\draw[dashed] (1,0)--(1,2.2);
\draw[dashed] (0,2.2)--(1,2.2);
\node at (1,2.2) {$\bullet$};
\node at (3,0.75) {$\bullet$};
\end{tikzpicture}
\end{center}


But I can't this

• You have 1029 reputation don't format your code yet in the proper way oO – Astrinus Jun 11 '15 at 13:34
• Why is this downvoted again? – percusse Jun 11 '15 at 13:53
• – user10274 Jun 11 '15 at 14:04
• @Astrinus You have 947 reputation and your post isn't very constructive, – user10274 Jun 11 '15 at 14:07
• I haven't downvoted the question in fact. – Astrinus Jun 11 '15 at 14:31

\documentclass{scrartcl}
\usepackage{tikz}
\usetikzlibrary{calc,arrows.meta,intersections,patterns}
\begin{document}
\begin{center}
\begin{tikzpicture}[>={Triangle[length=.5cm]}]
\pgfmathdeclarefunction{func}{1}{\pgfmathparse{.7/(.3*#1)}}
\draw[->] (-1,0) -- (7,0) node[below] {$x$};
\draw[->] (0,-1) -- (0,4) node[left] {$y$};
\draw[domain=0.5:6,smooth, variable=\x,black, ultra thick]
plot ({\x},{func(\x)});
\node[below] at (1,0) {\strut$a$};
\node[below] at (2,0) {\strut$c$};
\node[below] at (3,0) {\strut$d$};
\node[below] at (4,0) {\strut$e$};
\node[below] at (5,0) {\strut$b$};
\foreach \n in {1,...,5}
\draw[very thin] (\n,0) -- (\n,{func(\n)});
\foreach \n [remember=\n as \lastn (initially 1)] in {2,...,5}
\filldraw[very thin,pattern=north west lines] (\n,{func(\n)}) rectangle (\lastn,0);
\end{tikzpicture}
\end{center}
\end{document}