我使用多种输入为我的数学发展开发了附加的框架。无论如何,我遇到了两个不便之处:
我想在每个定理前添加空格。
我还希望为信息段落提供一个单一的环境。我开发了两个不同的环境,因为 {info} 不支持分页符,而 {mdframed}[style=infoframe] 在单页(短文本)中使用时无法在段落开头打印 (i) 符号
\documentclass[a4paper,11pt]{book}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{lmodern}
\usepackage[english]{babel}
\usepackage{tikz}
\usetikzlibrary{arrows.meta}
\usepackage{amsfonts}
\usepackage{amsmath}
\usepackage{stmaryrd}
%
\usepackage[skip=1\baselineskip, indent=0pt]{parskip}
%
\usepackage{mathtools}
%
%------------------------------------------------------------------------------------------------------------
\usepackage{framed}
\usepackage[framemethod=tikz]{mdframed}
\usepackage{pstricks}
\usepackage{unicode-math}
%
\usepackage[mathscr]{euscript}
%
\usepackage{parskip}
\usepackage{lipsum}
%
\usepackage{longtable}
%
\usepackage[thmmarks,framed,amsmath,thref]{ntheorem}%
\theoremseparator{:}
\theoremstyle{plain}
\theoremheaderfont{\normalfont\bfseries}
\theorembodyfont{\upshape}
%
\newtheorem{theorem}{Theorem}[chapter]
\newframedtheorem{importantTheorem}[theorem]{Theorem}
%
\newtheorem{prop}{Proposition}[chapter]
\newframedtheorem{importantProp}[prop]{Proposition}
%
\newtheorem{defn}{Definition}[chapter]
\newframedtheorem{importantdefn}[defn]{Definition}
\newtheorem{fact}{Fact}[chapter]
%
\newtheorem{Lemma}{Lemma}[chapter]
\newtheorem*{axioms}{Axioms}
\newtheorem*{example}{Example}
\newtheorem{corollary}{Corollary}[theorem]
% ---------------------------------------------- Remove numbering from theorem-style items
\theoremstyle{nonumberplain}
\newtheorem{proof}{Proof}
\newframedtheorem{remark}{Remark}
%
\theoremsymbol{$\blacksquare$}
%
\usepackage[framemethod=tikz]{mdframed}
%----------------------------------------------------------- Additional frames style
% Principal MPD frame type
\mdfdefinestyle{mpdframe}{
frametitlebackgroundcolor =black!15,
frametitlerule =true,
roundcorner =10pt,
middlelinewidth =1pt,
innermargin =0.5cm,
outermargin =0.5cm,
innerleftmargin =0.5cm,
innerrightmargin =0.5cm,
innertopmargin =\topskip,
innerbottommargin =\topskip,
}
\mdfdefinestyle{note}{%
style=mpdframe,
frametitle={Remark},
}
\newmdenv[style=note]{note}
%---------------------------------------------------------- Style = Note
\mdfdefinestyle{info}{%
topline=false, bottomline=false,
leftline=false, rightline=false,
nobreak,
singleextra={%
\fill[black](P-|O)circle[radius=0.5em];
% \node at(P-|O){\color{white}\scriptsize\bf i};
\node at(P-|O){\color{white}\scriptsize\bf i};
\draw[very thick](P-|O)++(0,-0.8em)--(O);%--(O-|P);
}
}
\newmdenv[style=info]{info}
%-------------------------------------------------------------- Style = info
\mdfdefinestyle{question}{
innertopmargin=1.2\baselineskip,
innerbottommargin=0.8\baselineskip,
roundcorner=5pt,
nobreak,
singleextra={%
\draw(P-|O)node[xshift=1em,anchor=west,fill=white,draw,rounded corners=5pt]{%
Question \theQuestion\questionTitle};
},
}
\newcounter{Question} % Stores the current question number that gets iterated with each new question
% -------------------------------------------------------------- Style = Question
% Define a custom environment for numbered questions
\newenvironment{question}[1][\unskip]{
\bigskip
\stepcounter{Question}
\newcommand{\questionTitle}{~#1}
\begin{mdframed}[style=question]
}{
\end{mdframed}
\medskip
}
%\newmdenv[style=question]{question}
\global\mdfdefinestyle{infoframe}{%
linecolor=black,linewidth=1.25pt,%
topline=false, bottomline=false, rightline=false,%
leftmargin=1cm,rightmargin=1cm,
firstextra={%
\fill[black](P-|O)circle[radius=0.5em];
% \node at(P-|O){\color{white}\scriptsize\bf i};
\node at(P-|O){\color{white}\scriptsize\bf i};
\draw[very thick](P-|O)++(0,-0.8em)--(O);%--(O-|P);
}
}
%-----------------------------------------------------Surrounds proofs with leftbar
\surroundwithmdframed[
topline=false,
rightline=false,
bottomline=false,
leftmargin=\parindent,
skipabove=\medskipamount,
skipbelow=\medskipamount
]{proof}
%---------------------------------------------------------- Document
\begin{document}
\begin{theorem}
The fundamental theorem of calculus is a theorem that links the concept of differentiating a function (calculating its slopes, or rate of change at each time) with the concept of integrating a function (calculating the area under its graph, or the cumulative effect of small contributions). The two operations are inverses of each other apart from a constant value which depends on where one starts to compute area.
\end{theorem}
\begin{proof}
Suppose that m is evenly divisible by n. (This is where you assume that statement A is true.) This means that m = kn for some integer k. Suppose that m + 1 was also divisible by n. (This is where you assume that statement B is false. Now use this information!) The fact that m + 1 is evenly divisible by n means that m + 1 = jn for some integer j. Since we have both m = kn and m + 1 = jn, this implies that...
\end{proof}
\begin{importantTheorem}
The fundamental theorem of calculus is a theorem that links the concept of differentiating a function (calculating its slopes, or rate of change at each time) with the concept of integrating a function (calculating the area under its graph, or the cumulative effect of small contributions). The two operations are inverses of each other apart from a constant value which depends on where one starts to compute area.
\end{importantTheorem}
\begin{proof}
Suppose that m is evenly divisible by n. (This is where you assume that statement A is true.) This means that m = kn for some integer k. Suppose that m + 1 was also divisible by n. (This is where you assume that statement B is false. Now use this information!) The fact that m + 1 is evenly divisible by n means that m + 1 = jn for some integer j. Since we have both m = kn and m + 1 = jn, this implies that...
\end{proof}
\begin{prop}
The fundamental theorem of calculus is a theorem that links the concept of differentiating a function (calculating its slopes, or rate of change at each time) with the concept of integrating a function (calculating the area under its graph, or the cumulative effect of small contributions). The two operations are inverses of each other apart from a constant value which depends on where one starts to compute area.
\end{prop}
\begin{importantProp}
The fundamental theorem of calculus is a theorem that links the concept of differentiating a function (calculating its slopes, or rate of change at each time) with the concept of integrating a function (calculating the area under its graph, or the cumulative effect of small contributions). The two operations are inverses of each other apart from a constant value which depends on where one starts to compute area.
\end{importantProp}
\begin{remark}
Nota
\end{remark}
\begin{theorem}
The fundamental theorem of calculus is a theorem that links the concept of differentiating a function (calculating its slopes, or rate of change at each time) with the concept of integrating a function (calculating the area under its graph, or the cumulative effect of small contributions). The two operations are inverses of each other apart from a constant value which depends on where one starts to compute area.
\end{theorem}
\begin{proof}
Suppose that m is evenly divisible by n. (This is where you assume that statement A is true.) This means that m = kn for some integer k. Suppose that m + 1 was also divisible by n. (This is where you assume that statement B is false. Now use this information!) The fact that m + 1 is evenly divisible by n means that m + 1 = jn for some integer j. Since we have both m = kn and m + 1 = jn, this implies that...
\end{proof}
\begin{corollary}
Facts supported by the corollary
\end{corollary}
\vspace{12pt}
\begin{info}
Suppose that m is evenly divisible by n. (This is where you assume that statement A is true.) This means that m = kn for some integer k. Suppose that m + 1 was also divisible by n. (This is where you assume that statement B is false. Now use this information!) The fact that m + 1 is evenly divisible by n means that m + 1 = jn for some integer j. Since we have both m = kn and m + 1 = jn, this implies that...
\end{info}
%\vspace{12pt}
\begin{mdframed}[style=infoframe]
\lipsum
\end{mdframed}
\vspace{20pt}
\begin{mdframed}[style=infoframe]
Suppose that m is evenly divisible by n. (This is where you assume that statement A is true.) This means that m = kn for some integer k. Suppose that m + 1 was also divisible by n. (This is where you assume that statement B is false. Now use this information!) The fact that m + 1 is evenly divisible by n means that m + 1 = jn for some integer j. Since we have both m = kn and m + 1 = jn, this implies that...
\end{mdframed}
\end{document}