Lista enumerada central (formatação de indução matemática)
Estou tentando replicar este exercício:
Agora, tenho o seguinte (irei incluir um MWE para ele).
\documentclass[11pt]{article}
\usepackage[margin=1in]{geometry}
\usepackage{amsmath,amssymb}
\usepackage{enumitem}
\newcommand{\N}{\mathbb{N}}
\begin{document}
\begin{enumerate}
\item[2.] Prove the following variants of the Principle of Mathematical Induction:
\begin{enumerate}
\item For each $n\in\N$, let $P(n)$ be a proposition and let $n_0$ be some natural number. Suppose the following two results:
\begin{enumerate}[label={(\Alph*)}]
\item $P(n_0)$ is true.
\item If $P(k)$ is true, then $P(k+1)$ is also true.
\end{enumerate}
Then $P(n)$ is true for all natural numbers $n$ such that $n\geq n_0$.
\item For each $n\in\N$, let $P(n)$ be a proposition. Suppose the following two results:
\begin{enumerate}[label={(\Alph*)}]
\item $P(1)$ is true.
\item If $P(r)$ is true for all $r$ such that $1\leq r\leq k$, then $P(k+1)$ is true.
\end{enumerate}
Then $P(n)$ is true for all natural numbers $n$.
\end{enumerate}
\end{enumerate}
\end{document}
Como pode ser visto claramente, minha replicação é exata, exceto para as listas (A) - (B), que não consigo descobrir como centralizar. Se eu os colocar em um centerambiente, nada acontece. Se eu adicionar \centeringdentro dos ambientes enumerados, ambos os itens são centralizados individualmente. Se eu usar a varwidthsolução geralmente proposta (veja aqui ), obtenho uma formatação diferente da que desejo (estou supondo porque carrego o hyperrefpacote - veja aqui ).
Qualquer opinião sobre como minha formatação desejada pode ser alcançada, seria muito apreciada, obrigado!
Respostas
varwidthnão é capaz de fazer o seu negócio quando hyperrefquer fixar âncoras.
Você pode emular com um tabular, se seus itens não forem muito longos. No entanto, também adicionei uma abordagem diferente, simplesmente movendo os itens mais para a direita do enumerateque faria.
\documentclass[11pt]{article}
\usepackage[margin=1in]{geometry}
\usepackage{amsmath,amssymb}
\usepackage{enumitem}
\usepackage{varwidth}
\usepackage{hyperref}
\newcounter{tabitem}\newcounter{tabitemplus}
\newcommand{\tabitem}{\refstepcounter{tabitem}\makebox[\labelwidth][r]{\thetabitem\ }\ignorespaces}
\renewcommand{\theHtabitem}{\thetabitemplus\arabic{tabitem}}
\newenvironment{centerenum}[1][\Alph]
{%
\begin{center}
\setcounter{tabitem}{0}\stepcounter{tabitemplus}%
\renewcommand{\thetabitem}{(#1{tabitem})}%
\renewcommand{\arraystretch}{1.2}
\begin{tabular}{@{}l@{}}
}
{\end{tabular}\end{center}}
\newcommand{\N}{\mathbb{N}}
\begin{document}
\begin{enumerate}
% tabular
\item Prove the following variants of the Principle of Mathematical Induction:
\begin{enumerate}
\item For each $n\in\N$, let $P(n)$ be a proposition and let $n_0$ be some
natural number. Suppose the following two results:
\begin{centerenum}
\tabitem\label{A1} $P(n_0)$ is true.
\\
\tabitem\label{B1} If $P(k)$ is true, then $P(k+1)$ is also true.
\end{centerenum}
Then $P(n)$ is true for all natural numbers $n$ such that $n\geq n_0$.
\item For each $n\in\N$, let $P(n)$ be a proposition. Suppose the following two results:
\begin{centerenum}
\tabitem\label{A2} $P(0)$ is true.
\\
\tabitem\label{B2} If $P(r)$ is true for all $r$ such that $0\leq r\leq k$,
then $P(k+1)$ is true.
\end{centerenum}
Then $P(n)$ is true for all natural numbers $n$.
\end{enumerate}
% wider margin
\item Prove the following variants of the Principle of Mathematical Induction:
\begin{enumerate}
\item For each $n\in\N$, let $P(n)$ be a proposition and let $n_0$ be some
natural number. Suppose the following two results:
\begin{enumerate}[label={(\Alph*)},leftmargin=4em]
\item $P(n_0)$ is true.
\item If $P(k)$ is true, then $P(k+1)$ is also true.
\end{enumerate}
Then $P(n)$ is true for all natural numbers $n$ such that $n\geq n_0$.
\item For each $n\in\N$, let $P(n)$ be a proposition. Suppose the following two results:
\begin{enumerate}[label={(\Alph*)},leftmargin=4em]
\item $P(0)$ is true.
\item If $P(r)$ is true for all $r$ such that $0\leq r\leq k$, then $P(k+1)$ is true.
\end{enumerate}
Then $P(n)$ is true for all natural numbers $n$.
\end{enumerate}
\end{enumerate}
\end{document}
A segunda instância é muito mais atraente, na minha opinião.
Você precisa colocá-lo em um bloco e centralizá-lo como uma unidade. O mais fácil seria um, minipagemas você precisa especificar a largura. Uma alternativa é o varwidthpacote que define uma minipágina de largura variável. (Na minha opinião fica difícil de ler e prefiro a solução sem centrar).
\documentclass[11pt]{article}
\usepackage[margin=1in]{geometry}
\usepackage{amsmath,amssymb}
\usepackage{enumitem}
\newcommand{\N}{\mathbb{N}}
\usepackage{varwidth}
\begin{document}
\begin{enumerate}
\item[2.] Prove the following variants of the Principle of Mathematical Induction:
\begin{enumerate}
\item For each $n\in\N$, let $P(n)$ be a proposition and let $n_0$ be some natural number. Suppose the following two results:
\begin{center}
\begin{varwidth}{\linewidth}
\begin{enumerate}[label={(\Alph*)},parsep=0pt]
\item $P(n_0)$ is true.
\item If $P(k)$ is true, then $P(k+1)$ is also true.
\end{enumerate}
\end{varwidth}
\end{center}
Then $P(n)$ is true for all natural numbers $n$ such that $n\geq n_0$.
\item For each $n\in\N$, let $P(n)$ be a proposition. Suppose the following two results:
\begin{center}
\begin{varwidth}{\linewidth}
\begin{enumerate}[label={(\Alph*)},parsep=0pt]
\item $P(1)$ is true.
\item If $P(r)$ is true for all $r$ such that $1\leq r\leq k$, then $P(k+1)$ is true.
\end{enumerate}
\end{varwidth}
\end{center}
Then $P(n)$ is true for all natural numbers $n$.
\end{enumerate}
\end{enumerate}
\end{document}