Graphics, Figures & Tables ⇒ How to draw a figure in Latex
How to draw a figure in Latex
Could you please help me to draw the attached graph in latex? I tried multiple time but I am unable to do it.
Thank you very much for your time.
Best
- Attachments
-
- a.png (148.96 KiB) Viewed 1403 times
NEW: TikZ book now 40% off at Amazon.com for a short time.
And: Currently, Packt sells ebooks for $4.99 each if you buy 5 of their over 1000 ebooks. If you choose only a single one, $9.99. How about combining 3 LaTeX books with Python, gnuplot, mathplotlib, Matlab, ChatGPT or other AI books? Epub and PDF. Bundle (3 books, add more for higher discount): https://packt.link/MDH5p
How to draw a figure in Latex
Code: Select all
\documentclass{article}\usepackage{tikz}\newcommand*\foo{Just a little text to put into the box}\begin{document}\begin{tikzpicture}[>=latex, node distance=2cm]\coordinate (dummy) at (0,0);\node[left of=dummy, rectangle, draw, text width=3cm] (A) {\foo};\node[right of=dummy, rectangle, draw, text width=3cm] (B) {\foo};\node[below of=dummy, rectangle, draw, text width=2cm] (C) {Energy};\node[below of=C] (dummy2) {};\node[left of=dummy2, rectangle, draw, text width=3cm] (D) {\foo};\node[right of=dummy2, rectangle, draw, text width=3cm] (E) {\foo};\draw[thick, ->] (C) -- (A.south);\draw[thick, ->] (C) -- (B.south);\draw[thick, ->] (C) -- (D.north);\draw[thick, ->] (C) -- (E.north);\end{tikzpicture}\end{document}
KR
Rainer