\usepackage[T1]{fontenc}
\usepackage{titlesec}
%\titlespacing*{\section}{0pt}{3pt}{0pt}
%\titlespacing*{\subsection}{0pt}{2pt}{0pt}
%\titlespacing*{\subsubsection}{0pt}{1pt}{0pt}
% \usepackage[margin=1in]{geometry}
\usepackage{complexity}
%\usepackage{mathpazo}
\usepackage{lmodern}
\usepackage{amssymb,amsmath,amsopn,mathtools}
\usepackage{mathrsfs}
\usepackage{ifxetex,ifluatex}
\usepackage{ifthen}
% \usepackage{fixltx2e} % provides \textsubscript
\usepackage{bbm}
\usepackage{dsfont}
\usepackage{mathtools}
% \usepackage{enumerate}
% \usepackage[shortlabels]{enumitem}
\usepackage{algpseudocode}
%\usepackage{algorithm}
% \usepackage[colorlinks]{hyperref}
\usepackage{float}
\usepackage{graphicx}
\usepackage{changepage}
\usepackage{xcolor}
\usepackage{tikz}
\usepackage{mathpazo}
\hypersetup{
  citecolor=blue,
  linkcolor=black,
  urlcolor=black,
}
\algnotext{EndFor}
\algnotext{EndIf}
\algnotext{EndWhile}
\algdef{SE}[DOWHILE]{Do}{doWhile}{\algorithmicdo}[1]{\algorithmicwhile\ #1}%
%\usepackage{authblk}

% preetum
\usepackage{graphicx}
\usepackage{caption}
\usepackage{subcaption}
\usepackage{listings}
\usepackage{multicol}
\usepackage{wrapfig}

\newcommand{\cqed}{\hfill$\lrcorner$}
\newcommand{\mdp}{{\textsc{GapDist}}}
\newcommand{\sncp}{{\textsc{GapSNC}}}
\newcommand{\odd}{{\textsc{GapOddSet}}}
\newcommand{\kvec}{\textsc{MLD}}
\newcommand{\gapvec}{\textsc{GapVectorSum}}
\newcommand{\csp}{\textsc{Gap2CSP}}
\newcommand{\kclique}{k\textsc{-clique}}
\newcommand{\kdense}{k\textsc{-Densest}}
\newcommand{\snvp}{\textsc{GapSNV}}
\newcommand{\svp}{GapSVP}
\newcommand{\den}{\textsc{Den}}
\newcommand{\bA}{{\mathbf{A}}}
\newcommand{\bB}{{\mathbf{B}}}
\newcommand{\bx}{{\mathbf{x}}}
\newcommand{\by}{{\mathbf{y}}}
\newcommand{\bL}{{\mathbf{L}}}
\newcommand{\bT}{{\mathbf{T}}}
\newcommand{\bs}{{\mathbf{s}}}
\newcommand{\bz}{{\mathbf{z}}}
\newcommand{\bp}{{\mathbf{p}}}
\newcommand{\bzero}{{\mathbf{0}}}
\newcommand{\uni}{\text{unique}}
\newcommand{\Id}{{\rm Id}}

% macros (preetum)
\newcommand{\card}[1]{\ensuremath{|#1|}}
\DeclareMathOperator*{\val}{val}
\DeclareMathOperator*{\var}{var}
\DeclareMathOperator*{\cl}{cl}
\DeclareMathOperator*{\opt}{OPT}
\DeclareMathOperator*{\disa}{disagr}
\DeclareMathOperator*{\rdisa}{rdisagr}
\DeclareMathOperator*{\lp}{LP}
\DeclareMathOperator*{\lpc}{\mathcal{L}}
\DeclareMathOperator*{\argmin}{argmin}
\DeclareMathOperator*{\argmax}{argmax}
\DeclareMathOperator*{\polyloglog}{polyloglog}
\DeclareMathOperator*{\supp}{supp}
\DeclareMathOperator{\sos}{sos}
\DeclareMathOperator{\cli}{CLIQUE}
\DeclareMathOperator*{\maj}{Majority}
\DeclareMathOperator*{\unsat}{UNSAT}
\DeclareMathOperator*{\EX}{\mathbb{E}}
%\DeclareMathOperator*{\deg}{deg}
\newcommand{\etal}{\text{et al.}}
\newcommand{\etals}{\text{et al. }}
\newcommand{\cQ}{\mathcal{Q}}
\newcommand{\cG}{\mathcal{G}}
\newcommand{\cW}{\mathcal{W}}
\newcommand{\tcW}{\widehat{\cW}}
\newcommand{\cC}{\mathcal{C}}
\newcommand{\cV}{\mathcal{V}}
\newcommand{\cX}{{\rm{X}}} % irit: I don't like the caligraphic X because it looks like a swastika and bad historical connotations. Can we find something else?
\newcommand{\cI}{\mathcal{I}}
%\newcommand{\cP}{\mathcal{P}}
\newcommand{\cK}{\mathcal{K}}
\newcommand{\cA}{\mathcal{A}}
\newcommand{\cB}{\mathcal{B}}
%\newcommand{\cS}{\mathcal{S}}
\newcommand{\cT}{\mathcal{T}}
\newcommand{\cF}{\mathcal{F}}
\newcommand{\tcS}{\widetilde{\cS}}
\newcommand{\tcT}{\widetilde{\cT}}
\newcommand{\cU}{\mathcal{U}}
\newcommand{\cD}{\mathcal{D}}
\newcommand{\tGamma}{\tilde{\Gamma}}
\newcommand{\tG}{\tilde{G}}
\newcommand{\tV}{\tilde{V}}
\newcommand{\tE}{\tilde{E}}
\newcommand{\tw}{\tilde{w}}
\newcommand{\tC}{\tilde{C}}
\newcommand{\tO}{\tilde{O}}
\newcommand{\tcF}{\tilde{\cF}}
\newcommand{\tSigma}{\tilde{\Sigma}}
\newcommand{\ttau}{\tilde{\tau}}
\newcommand{\tP}{\tilde{P}}
\newcommand{\tS}{\tilde{S}}
\newcommand{\tU}{\tilde{U}}
\newcommand{\tu}{\tilde{u}}
\newcommand{\tv}{\tilde{v}}
\newcommand{\tcP}{\tilde{\cP}}
\newcommand{\tPhi}{\widetilde{\Phi}}
\newcommand{\x}{\times}
\newcommand{\Z}{\mathbb{Z}}
\newcommand{\Q}{\mathbb{Q}}
\newcommand{\N}{\mathbb{N}}
\newcommand{\Fp}{\mathbb{F}_p}
\newcommand{\F}{\mathbb{F}_2}
\newcommand{\bbA}{\mathbb{A}}
\newcommand{\scrA}{\mathscr{A}}
\newcommand{\scrP}{\mathscr{P}}
\newcommand{\Rz}{\mathbb{R}_{\geq 0}}
\newcommand{\ind}{\mathds{1}}
\newcommand{\vone}{\mathbf{1}}
\newcommand{\cost}{\cC}
\newcommand{\geqs}{\geqslant}
\newcommand{\leqs}{\leqslant}
% \renewcommand{\E}{\mathbb{E}}
\newcommand{\ow}{\overline{w}}
\newcommand{\f}{\frac}
\newcommand{\reg}{\text{reg}}
\newcommand{\greedy}{\text{greedy}}
\renewcommand{\bar}{\overline}
\renewcommand{\epsilon}{\varepsilon}
\newcommand{\nullset}{\emptyset}
% \newcommand{\set}[1]{\{#1\}}
\newcommand{\DYES}{\mathcal{D}_{YES}}
\newcommand{\DNO}{\mathcal{D}_{NO}}
\newcommand{\YES}{{\sc YES}~}
\newcommand{\NO}{{\sc NO}~}
\newcommand{\loglog}{\log\log}
% \renewcommand{\polylog}{\text{polylog}}
% \renewcommand{\poly}{\text{poly}}
\newcommand{\psim}{\psi_{\text{maj}}}
\newcommand{\agr}{\text{agree}}
\newcommand{\napprox}{\not\approx}

\newcommand{\beq}{\begin{equation}}
\newcommand{\eeq}{\end{equation}}
\def\bal#1\eal{\begin{align}#1\end{align}}

\usepackage{xcolor}
%\newcommand{\TODO}[1][TODO]{\textcolor{red}{#1}}
\definecolor{xxxcolor}{rgb}{0.8,0,0}
\newcommand{\TODO}[1]{{\color{xxxcolor}{[TODO: }\emph{#1}{]}}}

% \newenvironment{proof}[1][Proof]{\par
%   \normalfont
%   \topsep6\p@\@plus6\p@ \trivlist
% \item[\hskip\labelsep\itshape
%   #1.]\ignorespaces
% }{%
%   \qed\endtrivlist
% }
\newenvironment{proofof}[1][Proof]{\par
  \normalfont
  \topsep6\p@\@plus6\p@ \trivlist
\item[\hskip\labelsep\itshape
  Proof of #1.]\ignorespaces
}{%
  \qed\endtrivlist
}
\newenvironment{subproof}[1][Proof]{\par
  \normalfont
  \topsep6\p@\@plus6\p@ \trivlist
\item[\hskip\labelsep\itshape
  #1.]\ignorespaces
}{%
  \cqed\endtrivlist
}
%\newcommand{\proofof}[1][]{\proof[Proof of #1]}
%\newcommand{\proof}{{\bf Proof. }}
%\newcommand{\proofof}[1][]{{\bf Proof of #1.}}
\newcommand{\result}{{\bf Result. }}
%\newcommand{\qed}{$\square$}
% \newcommand{\qed}{\mbox{}\hspace*{\fill}\nolinebreak$\square$}
% \newcommand{\st}{~\text{s.t.}~}
% \newtheorem{theorem}{Theorem}[section]
% \newtheorem{lemma}[theorem]{Lemma}
% \newtheorem{definition}[theorem]{Definition}
% \newtheorem{conjecture}[theorem]{Conjecture}
% \newtheorem{corollary}[theorem]{Corollary}
% \newtheorem{remark}[theorem]{Remark}
% \newtheorem{fact}[theorem]{Fact}
% \newtheorem{proposition}[theorem]{Proposition}
% \newtheorem{observation}[theorem]{Observation}
% \newtheorem{claim}[theorem]{Claim}
% \newtheorem{hypothesis}[theorem]{Hypothesis}
% \newtheorem{question}[theorem]{Open Question}

\let\Oldforall\forall
\renewcommand{\forall}{~\Oldforall} % add some space before foralls
\renewcommand{\arraystretch}{1.5} % add more space in table

\let\Oldsum\sum
%\renewcommand{\sum}{\Oldsum\limits}
\let\Oldinf\inf
\renewcommand{\inf}{\Oldinf\limits}
\let\Oldsup\sup
\renewcommand{\sup}{\Oldsup\limits}
