Skip to content

Instantly share code, notes, and snippets.

@mcnees
Created September 11, 2017 18:21
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mcnees/eb7dba504829ec273a630e6952ea6ff2 to your computer and use it in GitHub Desktop.
Save mcnees/eb7dba504829ec273a630e6952ea6ff2 to your computer and use it in GitHub Desktop.
Toast / Airplane Wine phase diagram
\documentclass[crop=true, border=10pt]{standalone}
\usepackage{xcolor}
\usepackage{tikz}
\usetikzlibrary{arrows.meta}
% Some colors I like. The first six are modified versions of colors from
% the Gnome Project "Tango" palette.
\definecolor{plum}{rgb}{0.36078, 0.20784, 0.4}
\definecolor{chameleon}{rgb}{0.30588, 0.60392, 0.023529}
\definecolor{cornflower}{rgb}{0.12549, 0.29020, 0.52941}
\definecolor{scarlet}{rgb}{0.8, 0, 0}
\definecolor{brick}{rgb}{0.64314, 0, 0}
\definecolor{sunrise}{rgb}{0.80784, 0.36078, 0}
\definecolor{lightblue}{rgb}{0.15,0.35,0.75}
\definecolor{carolina}{RGB}{153, 186, 221}
% A custom arrowhead for use on x, y, z axes
\tikzstyle{axisarrow} = [-{Latex[inset=0pt,length=5pt]}]
\begin{document}
\begin{tikzpicture}[scale=1.2]
% Draw the grid.
\draw [cornflower!20,step=0.25,thin] (-3,-3) grid (3,3);
\draw [cornflower!40,step=1.0,thin] (-3,-3) grid (3,3);
% Draw Axes
\draw[axisarrow] (-2.75,-3) -- (-2.75,3);
\node[inner sep=0pt] at (-2.5,2.8) {$P$};
\draw[axisarrow] (-3,-2.75) -- (3,-2.75);
\node[inner sep=0pt] at (2.8,-2.5) {$T$};
% Draw phase boundaries
\draw[thick, cornflower] (-2.75,-2.75) edge[out=20,in=240] (-0.5,-1);
\draw[thick, cornflower] (-0.5,-1) -- (-1,2.8);
\draw[thick, cornflower] (-0.5,-1) edge[out=20,in=250] (2.6,2.2);
% Label Cold Toast phase
\node[inner sep=0pt] at (-1.75,1) {\begin{tabular}{c} Cold \\ Toast \end{tabular}};
% Label Toast phase
\node[inner sep=0pt] at (0.5,1) {Toast};
% Label Airplane Wine phase
\node[inner sep=0pt] at (1,-2) {\begin{tabular}{c} Airplane \\ Wine \end{tabular}};
% Point to and label the Toast Point
\draw[scarlet] (1,-1) edge[out=190,in=350,axisarrow] (-0.5,-1);
\node[inner sep=0pt] at (1.6,-1) {{\scriptsize Toast Point}};
\end{tikzpicture}
\end{document}
@mcnees
Copy link
Author

mcnees commented Sep 11, 2017

screen shot 2017-09-11 at 1 08 33 pm

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment