[Tex/LaTex] Tikz: Put control points on tangent of curve point

tikz-pgf

I want to achieve the following (this is a mockup drawing in Inkscape):
Curve in Inkscape

I want to draw a smooth curve through three coordinates and I want the control points of the second coordinate (labeled "P" in the image above) to lie on the tangent of Point P, so that I can stretch them out to either side to control the smoothness of the curve at that point. Further, the curve should leave the first point (which is the one on the bottom left) at 5 degrees and enter the last point (upper right) at -90 degress. This is not depicted in the image above.

Unfortunately, I do not know how to achieve this. I tried the following:

\documentclass[border=5pt,tikz]{standalone}

\usepackage{tikz}
\usetikzlibrary{calc,intersections,through}
\tikzset{point/.style={circle,inner sep=0pt,minimum size=3pt,fill=red}}

\begin{document}
\begin{tikzpicture}

\coordinate [label=left:$A$] (A) at (0,0);
\coordinate [label=above:$B$] (B) at (11,6);
\coordinate [label=right:$C$] (C) at (16,14);
\coordinate [label=above:$D$] (D) at (16,28);

\draw[thick] (A) .. controls +(5:3)  and ([turn]1:1) .. (B) .. controls ([turn]1:1) and +(-90:3) .. (C);
\draw[thick] (C) -- (D);

\node[point] at (A) {};
\node[point] at (B) {};
\node[point] at (C) {};
\node[point] at (D) {};

\end{tikzpicture}
\end{document}

But that does not give the desired result, as you can see here:
Curve in Tikz

Can anybody please give me a hint how to align control points to the tangent of a curve point? Any help is greatly appreciated.

Best Answer

Your approach is quit good, unfortunately it is not consistent used. First, your curve is larger that A4 paper , so you need to reduce it. For example as I do in the code below:

    \documentclass[border=5pt,tikz]{standalone}  
    \usetikzlibrary{arrows}
    \tikzset{point/.style={circle,inner sep=0pt,minimum size=3pt,fill=red}}

         \begin{document}
    \begin{tikzpicture}
    \coordinate [label=left: $A$] (A) at (0,0);
    \coordinate [label=above:$B$] (B) at (5,2.5);
    \coordinate [label=above:$C$] (C) at (8,10);

    \draw[thick] (A) .. controls +(05:2) and +(225:1) .. (B) 
                     .. controls +(45:1) and +(-90:5) .. (C);
    % only for show of tangents
    \draw[red,dashed,-*] (A) -- + (  5:2);
    \draw[red,dashed,-*] (B) -- + (225:2);
    \draw[red,dashed,-*] (B) -- + ( 45:2);
    \draw[red,dashed,-*] (C) -- + (270:2);
    %
    \node[point] at (A) {};
    \node[point] at (B) {};
    \node[point] at (C) {};
    \end{tikzpicture}
        \end{document}

It gives:

enter image description here

In it the tangent of start point and end point determined +(05:2) and +(225:1), where +(05:2) determine "departure" angle at start of curve and +(225:2) departure angle at end of curve. With + is indicated, that this ponts are relative to start and end of curve.