Text Formatting ⇒ How to insert Section in the middle of Proof?
How to insert Section in the middle of Proof?
I need to insert Section name into the middle of Proof.
To be more specific,as the Proof takes multiple pages, I need to insert Section name on the top of each page, although it is still within the same proof.
Any suggestions?
Thanks a lot.
Learn LaTeX easily with newest books:
The LaTeX Beginner's Guide: 2nd edition and perfect for students writing a thesis
The LaTeX Cookbook: 2nd edition full of practical examples for mathematics, physics, chemistry, and more
LaTeX Graphics with TikZ: the first book about TikZ for perfect drawings in your LaTeX thesis
How to insert Section in the middle of Proof?
I dont't understand... in the middle or on top of each page? You confused me there.ychao wrote:Dear all,
I need to insert Section name into the middle of Proof.
To be more specific,as the Proof takes multiple pages, I need to insert Section name on the top of each page, although it is still within the same proof...
What exactly do you want to do? Which document class are you using? What are your current settings for the relevant objects mentioned (the proof, the section)?
Re: How to insert Section in the middle of Proof?
Actually, I want to put the Section name on top of each page for a long proof, BUT not the first page of the proof. That's why I want to insert the Section name into the middle of proof.
Any ideas?
How to insert Section in the middle of Proof?
Code: Select all
\documentclass{article}
\usepackage[pagestyles]{titlesec}
\usepackage{amsthm}
\usepackage{lipsum}
\newpagestyle{proofheader}{%
\sethead{}{Proof of the main result}{}
}
\begin{document}
\section{Proof of the main result}
\begin{proof}
\lipsum[1-7]
{% to keep the page style local
\pagestyle{proofheader}
\lipsum[1-30]\thispagestyle{proofheader}
}
\end{proof}
\section{Another section}
\lipsum[1-20]
\end{document}