4

How can I draw this in LaTeX without colour (only black and white)?

image

I managed to get my code to represent every part but I need the arrow in the middle

\begin{tikzpicture}[sharp corners=2pt,inner sep=7pt,node distance=.8cm,every text node part/.style={align=center}]
\tikzstyle{block} = [rectangle, draw, fill=orange!30, 
    text width=10em, text centered, rounded corners, minimum height=4em]

% Draw rectangular nodes (switch sharp to smooth for different corners)
\node[draw, minimum height = 1cm, minimum width = 1cm] (state0){Lecture hall A };
\node[draw,below=1cm of state0, minimum height = 1cm, minimum width = 1cm](state2){ Female students };
\node[draw,right=1cm of state0, minimum height = 1cm, minimum width = 1cm](state1){Lecture hall A };
\node[draw,below=1cm of state1, minimum height = 1cm, minimum width = 1cm](state3){Male students};
width = 1cm](state2){ Female students };
\node[draw,right=2cm of state3, minimum height = 1cm, minimum
width = 1cm](state4){ Female students };
\node[draw,right=1cm of state4, minimum height = 1cm, minimum width = 1cm](state5){Male students};
\node [block, right=3cm of state1] (state6) {Lecture hall A};
%Draw arrows
\draw[-triangle 60] (state0) -- (state2) node [midway, above, left = 0.1cm]{};

\draw[-triangle 60] (state1) -- (state3) node [midway, above, right = 0.1cm]{};

\draw[-triangle 60] (state6) -- (state4) node [midway, above, right = 0.1cm]{};
\draw[-triangle 60] (state6) -- (state5) node [midway, above, right = 0.1cm]{};

output of code

Alan Munn
  • 218,180
  • 3
    Welcome to TeX.SX. Questions about how to draw specific graphics that just post an image of the desired result are really not reasonable questions to ask on the site. Please post a minimal compilable document showing that you've tried to produce the image and then people will be happy to help you with any specific problems you may have. See minimal working example (MWE) for what needs to go into such a document. – Martin Schröder Mar 29 '15 at 19:17
  • 1
    A suggestion: Do us a favour and change your username to something more telling than "user1234". – Martin Schröder Mar 29 '15 at 19:17
  • my trying this code represent the left part only – user72863 Mar 29 '15 at 19:21
  • 4
    Please don't downvote below a score of -1, even if the question in its current form needs some improvement. A score of -1 is enough to show that the question needs work, anything below that is of no use. Also, if you downvote or vote to close, please leave a comment explaining why you did so, but wait at least 24 hours after asking the OP for improvements to the question before voting to close. Don't forget, it's a new user! – Martin Schröder Mar 29 '15 at 19:23
  • Review this postinghttp://tex.stackexchange.com/questions/723/how-to-typeset-flowcharts-in-latex/99280#99280 for some ideas as you build your MWE showing what you can do and specifically how we can help you. – R. Schumacher Mar 29 '15 at 19:37

1 Answers1

2

Here's what I came up with.

\documentclass{article}
\usepackage{tikz}
\usetikzlibrary{positioning,shapes,arrows}

\begin{document}

\centering
\begin{tikzpicture}[sharp corners=2pt,inner sep=7pt,node distance=.8cm,every text node part/.style={align=center}]

% Draw rectangular nodes (switch sharp to smooth for different corners)
\node[draw] (state0){Lecture hall A };
\node[draw,below=2.5em of state0](state2){ Female students };
\node[draw,right=2em of state0](state1){Lecture hall A };
\node[draw,below=2.5em of state1](state3){Male students};
%Blank node for positioning
\node[right=2em of state1](blank){};
%Arrow
\node[single arrow, draw=black, fill=black!25, minimum height=4em, below=0.9em of blank](arrow){};
\node[draw, right=7em of state1, minimum height = 5em, minimum width =9em](state4){Lecture hall A};
%Blank node for positioning
\node[below=4em of state4](invis){};
\node[draw, below left=1em of invis](state5){Female students};
\node[draw, below right=1em of invis](state6){Male students};

%Draw arrows
\draw[-triangle 60] (state0) -- (state2) node [midway, above, left = 0.1cm] {};
\draw[-triangle 60] (state1) -- (state3) node [midway, above, right = 0.1cm] {};
\draw[-triangle 60] (state4.south) -- (state5);
\draw[-triangle 60] (state4.south) -- (state6);

\end{tikzpicture}

\end{document}

Output:

enter image description here

Christopher
  • 1,336
  • 11
  • 19