Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I have this...

\documentclass{standalone} 
\usepackage{tikz}
\usetikzlibrary{positioning,shapes.geometric,decorations.pathmorphing,decorations.pathreplacing,decorations.shapes,decorations.markings,patterns,calc,fit,arrows}

\begin{document}

\begin{tikzpicture}[>=latex',auto,inner sep=2mm,node distance=2cm and 3cm,scale=1]

%set styles for the axis between turbine and pump and for the boxes

\tikzset{box1/.style={draw,minimum width=2.5cm,rectangle,thick}}
\tikzset{deco/.style={decoration={markings,
                       mark=at position #1 with {\arrow{>}}},
                       postaction={decorate}}}
\tikzset{turb/.style={draw,trapezium,shape border rotate=90,inner sep=1pt,minimum width=2.5cm,trapezium stretches=true,trapezium angle=80,on grid}}   

% draw nodes
\node[turb] (turbine) {Turbine};
\node[box1,on grid,below left=of turbine] (condenser){Condenser};
%connections
\begin{scope}[>=triangle 45]
 \draw [deco=0.6]  (turbine.bottom left corner) |- (condenser);
 \end{scope}
%
\end{tikzpicture}
\end{document} 

enter image description here

But i need this way...new pink connection

enter image description here

Is it possible to connect near the end (Red line). say 1 or 2 mm away from turbine.bottom left corner...

enter image description here

share|improve this question

2 Answers 2

up vote 5 down vote accepted

($(turbine)!.5!(condenser)$) calculates the middle (0.5) between turbine and condenser.

turbine.south is equivalent to turbine.-90 (-90 is an angle) and condenser.east is equivalent to condenser.0.

So, here, two others possibilities:

\documentclass{standalone} 
\usepackage{tikz}
\usetikzlibrary{%
  positioning,shapes.geometric,decorations.pathmorphing,%
  decorations.pathreplacing,decorations.shapes,%
  decorations.markings,patterns,calc,fit,arrows,%
}

\begin{document}

\begin{tikzpicture}%
  [>=latex',auto,inner sep=2mm,node distance=2cm and 3cm,scale=1]

  % set styles for the axis between turbine and pump and for the boxes

  \tikzset{box1/.style={draw,minimum width=2.5cm,rectangle,thick}}
  \tikzset{
    deco/.style={%
      decoration={%
        markings,
        mark=at position #1 with {\arrow{>}}
      },
      postaction={decorate},
    },
    turb/.style={%
      draw,trapezium,shape border rotate=90,
      inner sep=1pt,minimum width=2.5cm,
      trapezium stretches=true,trapezium angle=80,on grid,
    }
  }   

  % draw nodes
  \node[turb] (turbine) {Turbine};
  \node[box1,on grid,below left=of turbine] (condenser){Condenser};
  % connections
  \begin{scope}[>=triangle 45]

    \draw [deco=0.5,red] (turbine.south)
    |- ($(turbine.south)!.5!(condenser.north)$)
    -| (condenser.north);

    \draw [deco=0.5,violet] (turbine.-70) |- (condenser.10);
  \end{scope}
%
\end{tikzpicture}
\end{document}

enter image description here

share|improve this answer

Adding

\draw [deco=0.7,pink] (turbine.south) |- ++(-1,-0.2) -| (condenser);

to the last scope is sufficient.

enter image description here

share|improve this answer
4  
A variant (without absolute coordinate) uses: \draw [deco=0.5,red] (turbine) |- ($(turbine)!.5!(condenser)$) -| (condenser); –  Paul Gaborit Jun 8 '12 at 6:32
1  
Very fine idea, with ($(turbine)!.5!(condenser)$) it's very easy to adjust the connection. Another possibility is (turbine.south) --++(0,-1em) -| (condenser); . –  Alain Matthes Jun 8 '12 at 6:42
    
Thank you... percusse –  sandu Jun 8 '12 at 6:44
    
@PolGab: THis also works well...Thank you. But ($(turbine)!.5!(condenser)$) is calc operation. i do not know the meaning... –  sandu Jun 8 '12 at 6:45
    
Can we use like numerical values like (0,-1em) instead of (turbine.south) –  sandu Jun 8 '12 at 7:03

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.