I am trying to use tikz to plot this picture

enter image description here

Any idea?

  • Begin here: \begin{tikzpicture} \draw [red,very thick](0,0)node[left]{L2}--(2,0)node[right]{F2}--(0,1)node[left]{L1}--(2,1)node[right]{F1}--cycle; \end{tikzpicture} – ferahfeza Apr 15 '19 at 23:30

One out of many ways.

 \foreach \X [count=\Y] in {red,red,blue,blue,green!70!black,green!70!black,green!70!black}
 {\draw[color=\X] (-1,-0.7*\Y) node (L\Y) {L\Y}  (1,-0.7*\Y) node (R\Y)  {R\Y}
 (L\Y) -- (R\Y); }
 \foreach \X/\Z [evaluate=\X as \Y using {int(\X+1)}] in
 {\draw[color=\Z] (L\X) -- (R\Y)  (L\Y) -- (R\X);}

enter image description here

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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