我想在solution
环境中放置一个结束标记,我试过了
\documentclass{article}
\usepackage{amsthm}
\usepackage{amssymb,amsmath}
\newtheorem{mytheorem}{Theorem}[section]
\newtheorem{ex}{Example}[section]
\begin{document}
\section{Section one}
\begin{mytheorem}
If \(U\) or \(V\) then...
\begin{proof}[Proof]
The Proof
\begin{equation*}
Ax = b.
\end{equation*}
\end{proof}
\end{mytheorem}
\begin{ex}
This is a example
\end{ex}
\begin{proof}[Solution]
\renewcommand{\qedsymbol}{\ensuremath{\diamondsuit}}
This is a solution
\end{proof}
\end{document}
如何在序言中写入命令以在solution
环境中放置结束标记?
答案1
用这个
\newenvironment{mysol}{%
\begin{proof}[Solution]}{%
\renewcommand{\qedsymbol}{\ensuremath{\diamondsuit}}%
\end{proof}%
}
然后你只需根据环境编写解决方案mysol
。