I have not tried this yet and have no ideas for this? could anyone can help? Thank you very much in advance!!
1 Answers
This could be a solution combining tcolorbox and TiKZ.
\documentclass{article}
\usepackage[most]{tcolorbox}
\usepackage{mathtools}
\usetikzlibrary{decorations.pathreplacing}
\tcbset{
boxmath/.style 2 args={%
enhanced,
sharp corners, colback=white,
colframe=#1, remember as=#2, size=fbox}
}
\begin{document}
[
e^x=\tcboxmath[boxmath={blue}{approx}]{1+x+\frac{x^2}{2!}+\frac{x^3}{3!}+\dots++\frac{x^n}{n!}}+\tcboxmath[boxmath={red}{trunc}]{\frac{x^{n+1}}{{n+1}!}+\dots}
]
\begin{tikzpicture}[remember picture, overlay, font=\sffamily]
\draw[blue,->] (approx.north) --++(120:5mm) node[anchor=south]{Approximation};
\draw[red,->] (trunc.north) --++(70:5mm) node[anchor=south]{Truncation Errors};
\draw[decorate, decoration={brace, mirror, raise=3pt, amplitude=2mm}] (approx.south west)--(trunc.south east) node[below=3mm, midway]{Exact mathematical formulation};
\end{tikzpicture}
\end{document}
- 136,588


tikzmarkyou'll find plenty of examples. – Rmano Feb 10 '21 at 08:13