%% Pan-STARRS short-cuts
\newcommand{\gps}{\ensuremath{g_{\rm P1}}}
\newcommand{\rps}{\ensuremath{r_{\rm P1}}}
\newcommand{\ips}{\ensuremath{i_{\rm P1}}}
\newcommand{\zps}{\ensuremath{z_{\rm P1}}}
\newcommand{\yps}{\ensuremath{y_{\rm P1}}}
\newcommand{\wps}{\ensuremath{w_{\rm P1}}}
\newcommand{\grizy}{\gps,\rps,\ips,\zps,\yps}
\newcommand\ugriz{$u^\prime g^\prime r^\prime i^\prime z^\prime$}
\newcommand{\PS}{\protect \hbox {Pan-STARRS}}
\newcommand\TP{$3\pi$}
\newcommand\TPS{$3\pi$ Survey}
\newcommand\PSONE{Pan-STARRS\,1}

% CZW: I used these in my paper.
%\newcommand{\ippprog}[1]{\textbf{\texttt{#1}}}
%\newcommand{\ippstage}[1]{\textsc{#1}}

% \def\arev#1#2{\acite{ARA\&A}{#1}{#2}}
% \def\aj#1#2{\acite{AJ}{#1}{#2}}
% \def\ana#1#2{\acite{A\&A}{#1}{#2}}
% \def\aas#1#2{\acite{A\&A}{#1}{#2}}
% \def\aap#1#2{\acite{A\&A}{#1}{#2}}
% \def\aass#1#2{\acite{A\&AS}{#1}{#2}}
% \def\anas#1#2{\acite{A\&AS}{#1}{#2}}
% \def\aaps#1#2{\acite{A\&AS}{#1}{#2}}
% \def\aal#1#2{\acite{A\&A}{#1}{L#2}}
% \def\aar#1#2{\acite{A\&AR}{#1}{#2}}
% \def\apj#1#2{\acite{ApJ}{#1}{#2}}
% \def\apjs#1#2{\acite{ApJS}{#1}{#2}}
% \def\apjl#1#2{\acite{ApJ}{#1}{L#2}}
% \def\apss#1#2{\acite{Ap\&SS}{#1}{#2}}
% \def\baas#1#2{\acite{BAAS}{#1}{#2}}
% \def\mn#1#2{\acite{MNRAS}{#1}{#2}}
% \def\mnras#1#2{\acite{MNRAS}{#1}{#2}}
% \def\nat#1#2{\acite{Nat}{#1}{#2}}
% \def\nature#1#2{\acite{Nat}{#1}{#2}}
% \def\pasj#1#2{\acite{PASJ}{#1}{#2}}
% \def\pasp#1#2{\acite{PASP}{#1}{#2}}
% \def\sov#1#2{\acite{SvA}{#1}{#2}}
% \def\sovl#1#2{\acite{SvA}{#1}{L#2}}
% \def\asr#1#2{\acite{Adv. in Space Research}{#1}{#2}}
% \def\ssr#1#2{\acite{Space Sci. Rev.}{#1}{#2}}
% \def\physrevd#1#2{\acite{Phys. Rev. D}{#1}{#2}}

\def\arev{ARA\&A}
\def\aj{AJ}
\def\ana{A\&A}
\def\aas{A\&A}
\def\aap{A\&A}
\def\aass{A\&AS}
\def\anas{A\&AS}
\def\aaps{A\&AS}
\def\aal{A\&A}
\def\aar{A\&AR}
\def\apj{ApJ}
\def\apjs{ApJS}
\def\apjl{ApJ}
\def\apss{Ap\&SS}
\def\baas{BAAS}
\def\mn{MNRAS}
\def\mnras{MNRAS}
\def\nat{Nat}
\def\nature{Nat}
\def\pasj{PASJ}
\def\pasp{PASP}
\def\sov{SvA}
\def\sovl{SvA}
\def\asr{Adv. in Space Research}
\def\ssr{Space Sci. Rev.}
\def\physrevd{Phys. Rev. D}

\newcommand\mytitle[1]{\vskip -5pt \subsection*{#1}}
\newcommand{\rref}{\par\noindent\hangindent 15pt \parskip 5pt {}}
% \renewcommand{\thepage}{}

% notes and related
\newcommand\note[1]{\textbf{\color{red}#1}}
\newcommand\tbd[1]{\textbf{\color{red}#1 (TBD)}}
\newcommand\tbr[1]{\textbf{\color{blue}#1 (TBR)}}
\newcommand\TBD[1]{\par\tbd{#1}\par}

\def\ippprog{\IPPprog}
\def\ippstage{\IPPstage}
\def\ippdbtable{\IPPdbtable}
\def\ippdbcolumn{\IPPdbcolumn}
\def\ippmisc{\IPPmisc}

\def\lesssim{\mathrel{\hbox{\rlap{\hbox{%
 \lower4pt\hbox{$\sim$}}}\hbox{$<$}}}}
\def\gtrsim{\mathrel{\hbox{\rlap{\hbox{%
 \lower4pt\hbox{$\sim$}}}\hbox{$>$}}}}
\newcommand{\Lbol}{\mbox{$L_{bol}$}}
\newcommand{\Teff}{\mbox{$T_{\rm eff}$}}
\newcommand{\logg}{\mbox{$\log(g)$}}
\newcommand{\WISE}{{\sl WISE}}

% Specific astrophysical symbols
\newcommand\mathdegree{^{\circ}}
\newcommand\degree{$^{\circ}$}
\newcommand\degrees{$^{\circ}$}
\newcommand\asec{\hbox{$^{\prime\prime}$}}
\newcommand\amin{\hbox{$^{\prime}$}}
\def \mpt       {\rlap{.}$^{\rm m}$}
\def \spt       {\rlap{.}$^{\rm s}$}
\def \ampt      {\rlap{.}$'$}
\def \aspt      {\rlap{.}$''$}
\def\fd{\hbox{$.\!\!^{\rm d}$}}

\def\fh{\hbox{$.\!\!^{\rm h}$}}

\def\fm{\hbox{$.\!\!^{\rm m}$}}

\def\fs{\hbox{$.\!\!^{\rm s}$}}

\def\fdg{\hbox{$.\!\!^\circ$}}

\def\farcm{\hbox{$.\mkern-4mu^\prime$}}

\def\farcs{\hbox{$.\!\!^{\prime\prime}$}}

\def\fp{\hbox{$.\!\!^{\scriptscriptstyle\rm p}$}}

%\def\degree{\hbox{$^\circ$}}
%\def\degrees\degree

\def\arcmin{\hbox{$^\prime$}}

\def\arcsec{\hbox{$^{\prime\prime}$}}

\def\utw{\smash{\rlap{\lower5pt\hbox{$\sim$}}}}

\def\udtw{\smash{\rlap{\lower6pt\hbox{$\approx$}}}}

\newcommand\by{$\times\:$}
\newcommand\MW{Milky Way}
\newcommand\M[1]{\mbox{M\hspace{0.2ex}#1}}
\newcommand\BVRI{{\em BVRI}}
\newcommand\REF[1]{{\bf #1}}
\newcommand\UBVRI{{\it UBVR$_c$I$_c$\/}}
\newcommand\BVRIcc{{\it BVR$_c$I$_c$\/}}
\newcommand\UBV{{\it UBV\/}}
\newcommand\RI{{\it R$_c$I$_c$}}
%
\newcommand\Einstein{{\em Einstein}}
\def\ion#1#2{#1$\,${\sc{#2}}\relax}
\newcommand\HII{\mbox{H\hspace{0.2ex}{\sc ii}}}
\newcommand\hii{\mbox{H\hspace{0.2ex}{\sc ii}}}
\newcommand\nii{\mbox{N\hspace{0.2ex}{\sc ii}}}
\newcommand\hi{\mbox{H\hspace{0.2ex}{\sc i}}}
\newcommand\HI{\mbox{H\hspace{0.2ex}{\sc i}}}
\newcommand\sd{\mbox{$\Sigma$-$D$}}
%
\newcommand\U{{$U$}}
\newcommand\B{{$B$}}
\newcommand\V{{$V$}}
\newcommand\R{{$R$}}
\newcommand\I{{$I$}}
\newcommand\J{{$J$}}
\newcommand\K{{$K$}}
\newcommand\bJ{\mbox{$b_J$}}
\newcommand\sii{\mbox{[{S\hspace{0.2ex}\sc ii}]}}
\newcommand\oiii{\mbox{[{O\hspace{0.2ex}\sc iii}]}}
\newcommand\oi{\mbox{[{O\hspace{0.2ex}\sc i}]}}
%
\newcommand\Halpha{\mbox{H$\alpha$}}
\newcommand\ha{\mbox{H$\alpha$}}
\newcommand\halpha{\mbox{H$\alpha$}}
\newcommand\Hbeta{H${\beta}$}
\newcommand\hbeta{H${\beta}$}
\newcommand\hgamma{H${\gamma}$}
\newcommand\Lam{$\lambda$}
\newcommand\dRAdDEC{$\delta$RA~-~$\delta$DEC}
\newcommand\HSV{\Halpha, \sii, $V$}
\newcommand\Ebv{\mbox{E$_{B-V}$}}
%
\newcommand\Msun{\mbox{\rm M$_\odot$}}        % solar mass
\newcommand\Rsun{\mbox{\rm R$_\odot$}}        % solar radius
\newcommand\Lsun{\mbox{$L_\odot$}}      % solar luminosity
\newcommand\msun{\mbox{\rm M$_\odot$}}        % solar mass
\newcommand\rsun{\mbox{\rm R$_\odot$}}        % solar radius
\newcommand\lsun{\mbox{$L_\odot$}}      % solar luminosity
\newcommand\Mearth{\mbox{\rm M$_\oplus$}}     % earth mass
\newcommand\Rearth{\mbox{\rm R$_\oplus$}}     % earth radius

\newcommand\mdot{$\dot M$}
\newcommand\dophot{{DoPHOT}}
\newcommand\Year{~year$^{-1}$}
\newcommand\Sec{~sec$^{-1}$}
\newcommand\Cm{~cm$^{-2}$}
\newcommand\Sr{~sr$^{-1}$}
\newcommand\ErgSec{erg~sec$^{-1}$}
\newcommand\ErgSecCm{\ErgSec~cm$^{-2}$}
\newcommand\ErgCmSec{erg~cm$^{-2}$~sec$^{-1}$}
\newcommand\ErgCmSecSr{\ErgCmSec~sr$^{-1}$}
\newcommand\ErgCmSecAsec{\ErgCmSec~arcsec$^{-2}$}
\newcommand{\EE}[2]{\mbox{{#1}~$\times$~10$^{#2}$}}
\newcommand{\TEN}[1]{\mbox{10$^{#1}$}}
%
% Specific mathematical symbols
\renewcommand\approx{\mbox{$\sim$}}
\newcommand\about{\mbox{$\sim$}}        
\newcommand\lt{$<$}
\newcommand\gt{$>$}
\newcommand\approxgt{\mbox{$^{>}\hspace{-0.24cm}_{\sim}$}}
\newcommand\approxlt{\mbox{$^{<}\hspace{-0.24cm}_{\sim}$}}
\newcommand\chisq{\mbox{$\chi^2$}}
%\newcommand\d{\partial}
\newcommand\grad{\nabla}
%
% Latin -- note: commas never included in definitions.
\newcommand\vv{{\it vice versa}}
\newcommand\etc{{etc.}}
\newcommand\ie{{i.e.}}
\newcommand\eg{{e.g.}}
\newcommand\cf{{cf.}}
\newcommand\etal{{et~al.}}
\newcommand\vs{{vs.}}
%
\newcommand\hs{@{\hspace{2.5mm}}}
\newcommand\Hs{@{\hspace{5.0mm}}}
\def\ds{$d_s~$}
\def \refer{\par\noindent\hangindent 20pt}
%
\newcommand\MIT{
\small Center for Space Research and Department of Physics \\
\small Massachusetts Institute of Technology, Room 37-624, Cambridge, MA 02139, USA \\ 
\vspace{0.3cm} \\ }
\newcommand\MITaddress{
\large Center for Space Research and Department of Physics \\
\large Massachusetts Institute of Technology, Room 37-624 \\
\large Cambridge, MA 02139, USA \\
\large (617) - 253 - 7457 
}
\newcommand\CfA{
\small Harvard-Smithsonian Center for Astrophysics \\
\small 60 Garden St., Cambridge, MA 02138 \\ 
\vspace{0.3cm} \\ }
\newcommand\UVA{
\small Astronomical Institute ``Anton Pannekoek'', University of Amsterdam and \\
\small Center for High Energy Astrophysics, NIKHEF-H, Kruislaan 403, 1098 SJ \\
\small Amsterdam, The Netherlands. \\ 
\vspace{0.3cm} \\ }
\newcommand\MPE{
\small Max-Planck-Institut f\"{u}r Extraterrestriche Physik \\
\small W-8046 Garching bei M\"{u}nchen, Germany\\ 
\vspace{0.3cm} \\ }
\newcommand\MPEaddress{
\large Max-Planck-Institut f\"{u}r Extraterrestriche Physik \\
\large W-8046 Garching bei M\"{u}nchen, Germany 
}
\newcommand\ROME{
\small Osservatorio Astronomico di Roma \\
\small Viale del Parco Mellini 84, I-00136 Roma, Italy \\
\vspace{0.3cm} \\ }
%
\newcommand\AFour[2]{
\setlength\oddsidemargin{-2.56cm}
\addtolength\oddsidemargin{#1}
\setlength\evensidemargin{-2.56cm}
\addtolength\evensidemargin{#1}
\setlength\textwidth{21.0cm}
\addtolength\textwidth{-#1}
\addtolength\textwidth{-#1}
\setlength\topmargin{-3.95cm}
\addtolength\topmargin{#1}
\setlength\textheight{29.7cm}
\addtolength\textheight{-1.2cm}  % footer space
\addtolength\textheight{-#1}
\addtolength\textheight{-#1}
}

\newcommand\Letter[2]{
\setlength\oddsidemargin{-1.0in}
\addtolength\oddsidemargin{#1}
\setlength\evensidemargin{-1.0in}
\addtolength\evensidemargin{#1}
\setlength\textwidth{8.5in}
\addtolength\textwidth{-#1}
\addtolength\textwidth{-#1}
\setlength\topmargin{-1.5in}
\addtolength\topmargin{#1}
\setlength\textheight{11.0in}
\addtolength\textheight{-0.5in}  % footer space
\addtolength\textheight{-#1}
\addtolength\textheight{-#1}
}

%  set margins
\newcommand{\WideMargins}{
  \setlength{\oddsidemargin}{0.0in}
  \setlength{\evensidemargin}{0.0in}
  \setlength{\textwidth}{6.5in}
  \setlength{\topmargin}{-0.5in}
  \setlength{\textheight}{9.0in} }
%
\newcommand{\GoodMargins}{
  \setlength{\oddsidemargin}{-0.25in}
  \setlength{\evensidemargin}{-0.25in}
  \setlength{\textwidth}{6.75in}
  \setlength{\topmargin}{-1.0in}
  \setlength{\textheight}{9.5in} }
%
\newcommand{\NarrowMargins}{
  \setlength{\oddsidemargin}{-0.5in}
  \setlength{\evensidemargin}{-0.5in}
  \setlength{\textwidth}{7.5in}
  \setlength{\topmargin}{-1.0in}
  \setlength{\textheight}{10.0in}   }
% %
% \newcommand{\NoMargins}{
%   \setlength{\oddsidemargin}{-2.56cm}
%   \setlength{\evensidemargin}{-2.56cm}
%   \setlength{\textwidth}{21.6cm}
%   \setlength{\topmargin}{-3.95cm}
%   \setlength{\textheight}{27.9cm}   }
% %
% \newcommand{\DefMargins}{
%   \setlength{\oddsidemargin}{0.0cm}
%   \setlength{\evensidemargin}{0.0cm}
%   \setlength{\textwidth}{21.6cm}
%   \setlength{\topmargin}{0.0cm}
%   \setlength{\textheight}{27.9cm}   }
% %
% \newcommand{\AAMargins}{
%   \setlength{\oddsidemargin}{0.7cm}
%   \setlength{\evensidemargin}{0.7cm}
%   \setlength{\textwidth}{16.0cm}
%   \setlength{\topmargin}{-0.5cm}
%   \setlength{\textheight}{21.7cm}   }
% %
\newcommand{\LandMargins}{
   \setlength{\oddsidemargin}{-2.0cm}
   \setlength{\evensidemargin}{-2.0cm}
   \setlength{\textwidth}{9.9in}
   \setlength{\topmargin}{-3.0cm}
   \setlength{\textheight}{7.5in}   }
% %
% 
\newcommand{\PSbox}[3]{\mbox{\rule{0in}{#3}\special{psfile=#1}\hspace{#2}}}
% 
%\newcommand{\note}[1]{({\bf #1})}
\newcommand\pagenote[1]{
\special{!userdict begin /bop-hook{gsave 50 30 translate
/Times-Roman findfont 36 scalefont setfont
0 0 moveto 0.75 setgray (\today: #1) show  grestore} def end }}
%/Times-Roman findfont 18 scalefont setfont 
%0.0 setgray (  \today) show grestore} def end }}
%
% default settings
\sloppy
\raggedbottom
\setcounter{topnumber}{100}
\setcounter{bottomnumber}{100}
\setcounter{totalnumber}{100}
\setcounter{tocdepth}{5}
%

%% \def\uncatcodespecials{\def\do##1{\catcode`##1=12}\dospecials}%
%% {\catcode`\`=\active\gdef`{\relax\lq}}% this line inhibits Spanish 
%%                                       % ligatures ?` and !` of \tt font
%% \def\setupc@de % see TeX Book, p. 381
%%     {\tt %
%%      \spaceskip=0pt \xspaceskip=0pt % just in case...
%%      \catcode`\`=\active
%%      \uncatcodespecials \obeyspaces
%%      \catcode`\{=1\catcode`\}=2
%%     }%
%% \def\SETUPC@DE % see TeX Book, p. 381
%%     {\tt %
%%      \spaceskip=0pt \xspaceskip=0pt % just in case...
%%      \catcode`\`=\active
%%      \uncatcodespecials \obeyspaces
%%     }%
%% 
%% \def\d@code#1{#1\endgroup}%
%% \def\D@CODE#1{\def\next##1#1{##1\endgroup}\next}%
%% 
%% \def\code{\begingroup\setupc@de\d@code}%
%% \def\CODE{\begingroup\SETUPC@DE\D@CODE}%

% \newcommand{\code}[1]{{\tt #1}}

% \newcommand{\Ref}{\vspace{1ex} \hangindent=20pt \hangafter=1 \noindent}

%% \DefineVerbatimEnvironment%
%%    {datatype}{Verbatim}{fontsize=\footnotesize}
%% 
%% \DefineVerbatimEnvironment%
%%   {prototype}{Verbatim}{fontsize=\footnotesize}
%% 
\newcommand{\Ref}{\par \hangindent=20pt \hangafter=1 \noindent}


%\newcommand\acite[3]{{\it #1}~{\bf #2}, {#3}}
%\newcommand\acite[3]{{#1}~{#2}, {#3}}
\newcommand\acite[3]{{#1}}

%
\newcommand{\iauc}[1]{IAU Circ.~{#1}}
%
\newcommand{\StartRef}{\hyphenpenalty=10000 \raggedright
\parskip=0pt \parindent=0pt }

\newcommand{\rulerlines}{
\put (0.0,0.0){\line(1,0){2.0}}
\put (18,0.0){\line(-1,0){2.0}}
\put (0.0,26.5){\line(1,0){2.0}}
\put (18,26.5){\line(-1,0){2.0}}
\put (0.0,0.0){\line(0,1){2.0}}
\put (18,0.0){\line(0,1){2.0}}
\put (0.0,26.5){\line(0,-1){2.0}}
\put (18,26.5){\line(0,-1){2.0}}
\put (0,0){\line(0,1){26.5}}
\put (0,1){\line(1,0){0.5}}
\put (0,2){\line(1,0){0.5}}
\put (0,3){\line(1,0){0.5}}
\put (0,4){\line(1,0){0.5}}
\put (0,5){\line(1,0){0.75}}
\put (0,6){\line(1,0){0.5}}
\put (0,7){\line(1,0){0.5}}
\put (0,8){\line(1,0){0.5}}
\put (0,9){\line(1,0){0.5}}
\put (0,10){\line(1,0){1}}
\put (0,11){\line(1,0){0.5}}
\put (0,12){\line(1,0){0.5}}
\put (0,13){\line(1,0){0.5}}
\put (0,14){\line(1,0){0.5}}
\put (0,15){\line(1,0){0.75}}
\put (0,16){\line(1,0){0.5}}
\put (0,17){\line(1,0){0.5}}
\put (0,18){\line(1,0){0.5}}
\put (0,19){\line(1,0){0.5}}
\put (0,20){\line(1,0){1}}
\put (0,21){\line(1,0){0.5}}
\put (0,22){\line(1,0){0.5}}
\put (0,23){\line(1,0){0.5}}
\put (0,24){\line(1,0){0.5}}
\put (0,25){\line(1,0){0.75}}
\put (0,26){\line(1,0){0.5}}
}

