I'm new to latex and am using some stuff from a document my professor sent out.
I'm trying to define something in a paper I'm writing. Here is what I have:
\documentclass[11pt]{amsart}
\usepackage{amssymb,latexsym,amsmath,amsthm,enumitem,hyperref}
\usepackage{graphics,graphicx,multicol,tikz,pgfplots,tkz-
euclide,relsize,framed}
\usetikzlibrary{calc}
\tikzset{fontscale/.style = {font=\relsize{#1}}}
\setlength{\topmargin}{-0.750in}
\setlength{\textheight}{9.5in}
\setlength{\textwidth}{6.5in}
\setlength{\oddsidemargin}{0in}
\setlength{\evensidemargin}{0in}
\allowdisplaybreaks
\renewcommand{\labelenumi}{(\alph{enumi})}
\renewcommand{\labelenumii}{\roman{enumii}.}
\setlength\arraycolsep{2pt}
\begin{document}
\section{Important Definitions and Theorems}
\subsection{Definition [Sparsity]}
The \emph{sparsity} of $x \in \mathbb{R}^n$ is defined by
\begin{equation}
\norm{x}_{0} = card{k \in {1, 2, . . . , n} : x_k \neq 0}
\end{equation}
\end{document}
However, when I run this I get an Undefined Control Sequence error and I'm not sure what that means or how to fix it, hence I have come for your merciful help. Thanks!
Best Answer
The command
\norm
is not defined by default. A common way to define it is to usemathtools
and\DeclarPairedDelimiter
, so that\norm
can be calledwhere the calls with the optional argument manually set the size of the delimiter; the
*
-form uses automatically extensible delimiter (to be used sparingly).Instead of abusing
\subsection
I defined proper environments for theorems and definition (add the others you need).I also defined an operator name for the cardinality.
The braces for delimiting the set definition should be
\{
and\}
.Because of the nested sets, I used
\big
for the outer braces (it's optional)....
should be\dots
.Instead of guessing at the appropriate values for the page parameters, just set the desired text height and width, then issue
\calclayout
(a command proper ofamsart
) to set the others.