\begin{tikzpicture}[line cap=round,line join=round,>=triangle 45,x=0.7cm,y=0.7cm]
\begin{axis}[
x=0.7cm,y=0.7cm,
axis lines=middle,
ymajorgrids=true,
xmajorgrids=true,
xmin=-3.6496285752994115,
xmax=8.806566338252164,
ymin=-2.794350995226838,
ymax=4.886305932298563,
xtick={-3.0,-2.0,...,8.0},
ytick={-2.0,-1.0,...,4.0},]
\clip(-3.6496285752994115,-2.794350995226838) rectangle (8.806566338252164,4.886305932298563);

\draw [samples=50,rotate around={0.:(0.,0.)},xshift=0.cm,yshift=0.cm,line width=1.pt,domain=-3.0:-2.0)] plot (\x,{(-0.0*(\x)^3+0.5*(\x)^2+3.5*(\x)+7.0)/1.0}););
\draw [samples=50,rotate around={0.:(0.,0.)},xshift=0.cm,yshift=0.cm,line width=1.pt,domain=-2.0:0.0)] plot (\x,{(-0.125*(\x)^3+-0.75*(\x)^2+0.0*(\x)+4.0)/1.0}););
\draw [samples=50,rotate around={0.:(0.,0.)},xshift=0.cm,yshift=0.cm,line width=1.pt,domain=0.0:3.0)] plot (\x,{(-0.052*(\x)^3+-0.067*(\x)^2+0.0*(\x)+4.0)/1.0}););
\draw [samples=50,rotate around={0.:(0.,0.)},xshift=0.cm,yshift=0.cm,line width=1.pt,domain=3.0:4.0)] plot (\x,{(2.2*(\x)^3+-23.2*(\x)^2+78.0*(\x)+-82.6)/1.0}););
\draw [samples=50,rotate around={0.:(0.,0.)},xshift=0.cm,yshift=0.cm,line width=1.pt,domain=4.0:5.0)] plot (\x,{(0.0*(\x)^3+1.0*(\x)^2+-10.0*(\x)+23.0)/1.0}););
\draw [samples=50,rotate around={0.:(0.,0.)},xshift=0.cm,yshift=0.cm,line width=1.pt,domain=5.0:6.0)] plot (\x,{(-0.0*(\x)^3+1.0*(\x)^2+-10.0*(\x)+23.0)/1.0}););
\draw [samples=50,rotate around={0.:(0.,0.)},xshift=0.cm,yshift=0.cm,line width=1.pt,domain=6.0:8.0)] plot (\x,{(-0.25*(\x)^3+4.75*(\x)^2+-28.0*(\x)+50.0)/1.0}););

\begin{scriptsize}
\draw [color=black] (-3.,1.)-- ++(-1.5pt,0 pt) -- ++(3.0pt,0 pt) ++(-1.5pt,-1.5pt) -- ++(0 pt,3.0pt);
\draw [color=black] (0.,4.)-- ++(-1.5pt,0 pt) -- ++(3.0pt,0 pt) ++(-1.5pt,-1.5pt) -- ++(0 pt,3.0pt);
\draw [color=black] (-2.,2.)-- ++(-1.5pt,0 pt) -- ++(3.0pt,0 pt) ++(-1.5pt,-1.5pt) -- ++(0 pt,3.0pt);
\draw [color=black] (3.,2.)-- ++(-1.5pt,0 pt) -- ++(3.0pt,0 pt) ++(-1.5pt,-1.5pt) -- ++(0 pt,3.0pt);
\draw [color=black] (5.,-2.)-- ++(-1.5pt,0 pt) -- ++(3.0pt,0 pt) ++(-1.5pt,-1.5pt) -- ++(0 pt,3.0pt);
\draw [color=black] (4.,-1.)-- ++(-1.5pt,0 pt) -- ++(3.0pt,0 pt) ++(-1.5pt,-1.5pt) -- ++(0 pt,3.0pt);
\draw [color=black] (6.,-1.)-- ++(-1.5pt,0 pt) -- ++(3.0pt,0 pt) ++(-1.5pt,-1.5pt) -- ++(0 pt,3.0pt);
\draw [color=black] (8.,2.)-- ++(-1.5pt,0 pt) -- ++(3.0pt,0 pt) ++(-1.5pt,-1.5pt) -- ++(0 pt,3.0pt);
\end{scriptsize}
\end{axis}
\end{tikzpicture}
