For the braces, you can use a brace
decoration (from the decorations.pathreplacing
library); for the title, you can use a \node
placed at (current bounding box.north)
(or any other desired location), for example:
\documentclass[class=minimal,border=0pt]{standalone}
\usepackage{tikz}
\usetikzlibrary{calc,decorations.pathreplacing}
\begin{document}
\begin{tikzpicture}[domain=0:5,scale=1,thick]
%Define linear parameters for supply and demand
\def\dint{4.5} %Y-intercept for DEMAND.
\def\dslp{-0.5} %Slope for DEMAND.
\def\sint{1.2} %Y-intercept for SUPPLY.
\def\sslp{0.8} %Slope for SUPPLY.
\def\pfc{2.5} %Price floor or ceiling
\def\demand{\x,{\dslp*\x+\dint}}
\def\supply{\x,{\sslp*\x+\sint}}
% Define coordinates.
\coordinate (ints) at ({(\sint-\dint)/(\dslp-\sslp)},{(\sint-\dint)/(\dslp-\sslp)*\sslp+\sint});
\coordinate (ep) at (0,{(\sint-\dint)/(\dslp-\sslp)*\sslp+\sint});
\coordinate (eq) at ({(\sint-\dint)/(\dslp-\sslp)},0);
\coordinate (dint) at (0,{\dint});
\coordinate (sint) at (0,{\sint});
\coordinate (pfq) at ({(\pfc-\dint)/(\dslp)},0);
\coordinate (pfp) at ({(\pfc-\dint)/(\dslp)},{\pfc});
\coordinate (sfq) at ({(\pfc-\sint)/(\sslp)},0);
\coordinate (sfp) at ({(\pfc-\sint)/(\sslp)},{\pfc});
% DEMAND
\draw[thick,color=blue] plot (\demand) node[right] {$P(q) = -\frac{1}{2}q+\frac{9}{2}$};
% SUPPLY
\draw[thick,color=purple] plot (\supply) node[right] {Supply};
% Draw axes, and dotted equilibrium lines.
\draw[->] (0,0) -- (6.2,0) node[right] {$Q$};
\draw[->] (0,0) -- (0,6.2) node[above] {$P$};
%Price floor and ceiling lines
\draw[dashed,color=black] plot (\x,{\pfc}) node[right] {$P_c$};
\draw[dashed] (pfp) -- (pfq) node[below] (qd) {$Q_d$};
\draw[dashed] (sfp) -- (sfq) node[below] (qs) {$Q_s$};
\draw[->,baseline=5] ($(0,{\pfc})+(-1.5,0.7)$) node[label= left:Price Ceiling] {} -- ($(0,{\pfc})+(-.1,0.1)$);
\draw[decorate,decoration={brace,mirror}] (qs.south) -- node[below] {some text} (qd.south);
\draw[decorate,decoration={brace,mirror}]
([yshift=-1.2cm]0,0) -- node[below] {some text} ([yshift=-1.2cm]6.2,0);
\node at ([yshift=10pt]current bounding box.north) {A diagram illustrating supply versus demand};
\end{tikzpicture}
\end{document}
By way of demonstration, \maketitle
behaves differently depending on the class the document uses. So...
book
class with \maketitle
\documentclass{book}
\title{The Triangulation of Titling Data in
Non-Linear Gaussian Fashion via $\rho$ Series}
\date{October 31, 475}
\author{John Doe\\ Magic Department, Richard Miles University
\and Richard Row, \LaTeX\ Academy}
\date{April 4,2013}
\usepackage{kantlipsum}
\begin{document}
\maketitle
\kant[1]
\end{document}
report
with \maketitle
produces a similar result.
article
class with \maketitle
\documentclass{article}
\title{The Triangulation of Titling Data in
Non-Linear Gaussian Fashion via $\rho$ Series}
\date{October 31, 475}
\author{John Doe\\ Magic Department, Richard Miles University
\and Richard Row, \LaTeX\ Academy}
\date{April 4,2013}
\usepackage{kantlipsum}
\begin{document}
\maketitle
\kant[1]
\end{document}
article
class with titlepage
\documentclass{report}
\title{The Triangulation of Titling Data in
Non-Linear Gaussian Fashion via $\rho$ Series}
\date{October 31, 475}
\author{John Doe\\ Magic Department, Richard Miles University
\and Richard Row, \LaTeX\ Academy}
\date{April 4,2013}
\usepackage{kantlipsum}
\begin{document}
\begin{titlepage}
\maketitle
\end{titlepage}
\kant[1]
\end{document}
Note the use of \maketitle
within the titlepage
environment. This is because titlepage
just gives you an empty page to design as you will. If you don't put anything in it, it is just an empty page.
book
class with titlepage
produces similar output.
An easier way to achieve the same result given that you don't really want to customise the layout of the title would be to just use \maketitle
with the book
class (as above) or, in article
, to use the titlepage
option for the class:
\documentclass[titlepage]{article}
\title{The Triangulation of Titling Data in
Non-Linear Gaussian Fashion via $\rho$ Series}
\date{October 31, 475}
\author{John Doe\\ Magic Department, Richard Miles University
\and Richard Row, \LaTeX\ Academy}
\date{April 4,2013}
\usepackage{kantlipsum}
\begin{document}
\maketitle
\kant[1]
\end{document}
Best Answer
Here are two possibilities, both of which entail placing two images within the argument of a single
\titlepic
invocation.