diff --git a/Documentation/doc/resources/1.8.13/BaseDoxyfile.in b/Documentation/doc/resources/1.8.13/BaseDoxyfile.in
index 706be1b14ca..0a5a8ae32c5 100644
--- a/Documentation/doc/resources/1.8.13/BaseDoxyfile.in
+++ b/Documentation/doc/resources/1.8.13/BaseDoxyfile.in
@@ -1595,7 +1595,7 @@ MATHJAX_EXTENSIONS = TeX/AMSmath \
# example see the documentation.
# This tag requires that the tag USE_MATHJAX is set to YES.
-MATHJAX_CODEFILE =
+MATHJAX_CODEFILE = ${CGAL_DOC_RESOURCE_DIR}/CGAL_mathjax.js
# When the SEARCHENGINE tag is enabled doxygen will generate a search box for
# the HTML output. The underlying search engine uses javascript and DHTML and
diff --git a/Documentation/doc/resources/1.8.13/CGAL_mathjax.js b/Documentation/doc/resources/1.8.13/CGAL_mathjax.js
new file mode 100644
index 00000000000..e93d75593c7
--- /dev/null
+++ b/Documentation/doc/resources/1.8.13/CGAL_mathjax.js
@@ -0,0 +1,32 @@
+//
diff --git a/Documentation/doc/resources/1.8.13/header.html b/Documentation/doc/resources/1.8.13/header.html
index f5ed0edf20d..8c8b86f5b9d 100644
--- a/Documentation/doc/resources/1.8.13/header.html
+++ b/Documentation/doc/resources/1.8.13/header.html
@@ -22,19 +22,6 @@ $mathjax
$extrastylesheet
diff --git a/Documentation/doc/resources/1.8.4/BaseDoxyfile.in b/Documentation/doc/resources/1.8.4/BaseDoxyfile.in
index f536183a247..29f6345b39d 100644
--- a/Documentation/doc/resources/1.8.4/BaseDoxyfile.in
+++ b/Documentation/doc/resources/1.8.4/BaseDoxyfile.in
@@ -1340,7 +1340,7 @@ MATHJAX_EXTENSIONS =
# The MATHJAX_CODEFILE tag can be used to specify a file with javascript
# pieces of code that will be used on startup of the MathJax code.
-MATHJAX_CODEFILE =
+MATHJAX_CODEFILE = ${CGAL_DOC_RESOURCE_DIR}/CGAL_mathjax.js
# When the SEARCHENGINE tag is enabled doxygen will generate a search box
# for the HTML output. The underlying search engine uses javascript
diff --git a/Documentation/doc/resources/1.8.4/CGAL_mathjax.js b/Documentation/doc/resources/1.8.4/CGAL_mathjax.js
new file mode 100644
index 00000000000..e93d75593c7
--- /dev/null
+++ b/Documentation/doc/resources/1.8.4/CGAL_mathjax.js
@@ -0,0 +1,32 @@
+//
diff --git a/Documentation/doc/resources/1.8.4/header.html b/Documentation/doc/resources/1.8.4/header.html
index 4b0aae2bff8..a98007ec2a5 100644
--- a/Documentation/doc/resources/1.8.4/header.html
+++ b/Documentation/doc/resources/1.8.4/header.html
@@ -11,7 +11,6 @@
-
@@ -26,19 +25,9 @@
$(document).ready(initResizable);
$search
+$mathjax
-\( \newcommand{\E}{\mathrm{E}} \) \( \newcommand{\A}{\mathrm{A}} \)
-\( \newcommand{\R}{\mathrm{R}} \) \( \newcommand{\N}{\mathrm{N}} \) \( \newcommand{\Q}{\mathrm{Q}} \) \( \newcommand{\Z}{\mathrm{Z}} \)
-\(
-\def\ccSum #1#2#3{
- \sum_{#1}^{#2}{#3}
-}
-
-\def\ccProd #1#2#3{
- \sum_{#1}^{#2}{#3}
-}\)
-
diff --git a/Nef_3/doc/Nef_3/Nef_3.txt b/Nef_3/doc/Nef_3/Nef_3.txt
index 952ce600f28..83de0ad0fce 100644
--- a/Nef_3/doc/Nef_3/Nef_3.txt
+++ b/Nef_3/doc/Nef_3/Nef_3.txt
@@ -5,13 +5,6 @@ namespace CGAL {
\anchor Chapter_3D_Boolean_Operations_on_Nef_Polyhedra
\anchor chapterNef3
-
-\f$
- \newcommand{\pyr}{\operatorname{Pyr}}
- \newcommand{\aff}{\operatorname{aff}}
-\f$
-
-
\cgalAutoToc
\authors Peter Hachenberger and Lutz Kettner
diff --git a/QP_solver/doc/QP_solver/CGAL/QP_models.h b/QP_solver/doc/QP_solver/CGAL/QP_models.h
index ddd16cdf7c2..a16d6b9a22d 100644
--- a/QP_solver/doc/QP_solver/CGAL/QP_models.h
+++ b/QP_solver/doc/QP_solver/CGAL/QP_models.h
@@ -6,18 +6,6 @@ namespace CGAL {
An object of class `Linear_program_from_iterators` describes a linear program of the form
-\f$
-\newcommand{\qprel}{\gtreqless}
-\newcommand{\qpx}{\mathbf{x}}
-\newcommand{\qpl}{\mathbf{l}}
-\newcommand{\qpu}{\mathbf{u}}
-\newcommand{\qpc}{\mathbf{c}}
-\newcommand{\qpb}{\mathbf{b}}
-\newcommand{\qpy}{\mathbf{y}}
-\newcommand{\qpw}{\mathbf{w}}
-\newcommand{\qplambda}{\mathbf{\lambda}}
-\f$
-
\f{eqnarray*}{
\mbox{(QP)}& \mbox{minimize}
& \qpc^{T}\qpx+c_0 \\
@@ -277,18 +265,6 @@ make_quadratic_program_from_iterators (
An object of class `Nonnegative_linear_program_from_iterators` describes a linear program of the form
-\f$
-\newcommand{\qprel}{\gtreqless}
-\newcommand{\qpx}{\mathbf{x}}
-\newcommand{\qpl}{\mathbf{l}}
-\newcommand{\qpu}{\mathbf{u}}
-\newcommand{\qpc}{\mathbf{c}}
-\newcommand{\qpb}{\mathbf{b}}
-\newcommand{\qpy}{\mathbf{y}}
-\newcommand{\qpw}{\mathbf{w}}
-\newcommand{\qplambda}{\mathbf{\lambda}}
-\f$
-
\f{eqnarray*}{
\mbox{(QP)}& \mbox{minimize}
&\qpc^{T}\qpx+c_0 \\
@@ -368,17 +344,6 @@ public:
An object of class `Nonnegative_quadratic_program_from_iterators` describes a convex quadratic program of the form
-\f$
-\newcommand{\qprel}{\gtreqless}
-\newcommand{\qpx}{\mathbf{x}}
-\newcommand{\qpl}{\mathbf{l}}
-\newcommand{\qpu}{\mathbf{u}}
-\newcommand{\qpc}{\mathbf{c}}
-\newcommand{\qpb}{\mathbf{b}}
-\newcommand{\qpy}{\mathbf{y}}
-\newcommand{\qpw}{\mathbf{w}}
-\newcommand{\qplambda}{\mathbf{\lambda}}
-\f$
\f{eqnarray*}{
\mbox{(QP)}& \mbox{minimize}
& \qpx^{T}D\qpx+\qpc^{T}\qpx+c_0 \\
@@ -463,17 +428,6 @@ public:
An object of class `Quadratic_program_from_iterators` describes a convex quadratic program of the form
-\f$
-\newcommand{\qprel}{\gtreqless}
-\newcommand{\qpx}{\mathbf{x}}
-\newcommand{\qpl}{\mathbf{l}}
-\newcommand{\qpu}{\mathbf{u}}
-\newcommand{\qpc}{\mathbf{c}}
-\newcommand{\qpb}{\mathbf{b}}
-\newcommand{\qpy}{\mathbf{y}}
-\newcommand{\qpw}{\mathbf{w}}
-\newcommand{\qplambda}{\mathbf{\lambda}}
-\f$
\f{eqnarray*}{
\mbox{(QP)}& \mbox{minimize}
& \qpx^{T}D\qpx+\qpc^{T}\qpx+c_0 \\
@@ -567,17 +521,6 @@ public:
An object of class `Quadratic_program_from_mps` describes a convex quadratic program of the
general form
-\f$
-\newcommand{\qprel}{\gtreqless}
-\newcommand{\qpx}{\mathbf{x}}
-\newcommand{\qpl}{\mathbf{l}}
-\newcommand{\qpu}{\mathbf{u}}
-\newcommand{\qpc}{\mathbf{c}}
-\newcommand{\qpb}{\mathbf{b}}
-\newcommand{\qpy}{\mathbf{y}}
-\newcommand{\qpw}{\mathbf{w}}
-\newcommand{\qplambda}{\mathbf{\lambda}}
-\f$
\f{eqnarray*}{
\mbox{(QP)}& \mbox{minimize}
& \qpx^{T}D\qpx+\qpc^{T}\qpx+c_0 \\
@@ -781,18 +724,6 @@ namespace CGAL {
/*!
\ingroup PkgQPSolverClasses
-\f$
-\newcommand{\qprel}{\gtreqless}
-\newcommand{\qpx}{\mathbf{x}}
-\newcommand{\qpl}{\mathbf{l}}
-\newcommand{\qpu}{\mathbf{u}}
-\newcommand{\qpc}{\mathbf{c}}
-\newcommand{\qpb}{\mathbf{b}}
-\newcommand{\qpy}{\mathbf{y}}
-\newcommand{\qpw}{\mathbf{w}}
-\newcommand{\qplambda}{\mathbf{\lambda}}
-\f$
-
An object of class `Quadratic_program` describes a convex quadratic program of the form
\f{eqnarray*}{
\mbox{(QP)}& \mbox{minimize}
diff --git a/QP_solver/doc/QP_solver/CGAL/QP_solution.h b/QP_solver/doc/QP_solver/CGAL/QP_solution.h
index 1ecb2b901a3..a77ce3dbf03 100644
--- a/QP_solver/doc/QP_solver/CGAL/QP_solution.h
+++ b/QP_solver/doc/QP_solver/CGAL/QP_solution.h
@@ -7,19 +7,6 @@ namespace CGAL {
An object of class `Quadratic_program_solution` represents the solution of a linear or
convex quadratic program of the general form
-\f$
-\newcommand{\qprel}{\gtreqless}
-\newcommand{\qpx}{\mathbf{x}}
-\newcommand{\qpl}{\mathbf{l}}
-\newcommand{\qpu}{\mathbf{u}}
-\newcommand{\qpc}{\mathbf{c}}
-\newcommand{\qpb}{\mathbf{b}}
-\newcommand{\qpy}{\mathbf{y}}
-\newcommand{\qpw}{\mathbf{w}}
-\newcommand{\qplambda}{\mathbf{\lambda}}
-\f$
-
-
\f{eqnarray*}{
\mbox{(QP)}& \mbox{minimize}
& \qpx^{T}D\qpx+\qpc^{T}\qpx+c_0 \\
diff --git a/QP_solver/doc/QP_solver/Concepts/LinearProgram.h b/QP_solver/doc/QP_solver/Concepts/LinearProgram.h
index 67c1d182973..d685c489899 100644
--- a/QP_solver/doc/QP_solver/Concepts/LinearProgram.h
+++ b/QP_solver/doc/QP_solver/Concepts/LinearProgram.h
@@ -5,18 +5,6 @@
A model of `LinearProgram` describes a linear program of the form
-\f$
-\newcommand{\qprel}{\gtreqless}
-\newcommand{\qpx}{\mathbf{x}}
-\newcommand{\qpl}{\mathbf{l}}
-\newcommand{\qpu}{\mathbf{u}}
-\newcommand{\qpc}{\mathbf{c}}
-\newcommand{\qpb}{\mathbf{b}}
-\newcommand{\qpy}{\mathbf{y}}
-\newcommand{\qpw}{\mathbf{w}}
-\newcommand{\qplambda}{\mathbf{\lambda}}
-\f$
-
\f{eqnarray*}{
\mbox{(QP)}& \mbox{minimize}
& \qpc^{T}\qpx+c_0 \\
diff --git a/QP_solver/doc/QP_solver/Concepts/NonnegativeLinearProgram.h b/QP_solver/doc/QP_solver/Concepts/NonnegativeLinearProgram.h
index 1dee9bd9895..e3a75a9aaf7 100644
--- a/QP_solver/doc/QP_solver/Concepts/NonnegativeLinearProgram.h
+++ b/QP_solver/doc/QP_solver/Concepts/NonnegativeLinearProgram.h
@@ -5,18 +5,6 @@
A model of `NonnegativeLinearProgram` describes a linear program of the form
-\f$
-\newcommand{\qprel}{\gtreqless}
-\newcommand{\qpx}{\mathbf{x}}
-\newcommand{\qpl}{\mathbf{l}}
-\newcommand{\qpu}{\mathbf{u}}
-\newcommand{\qpc}{\mathbf{c}}
-\newcommand{\qpb}{\mathbf{b}}
-\newcommand{\qpy}{\mathbf{y}}
-\newcommand{\qpw}{\mathbf{w}}
-\newcommand{\qplambda}{\mathbf{\lambda}}
-\f$
-
\f{eqnarray*}{
\mbox{(QP)}& \mbox{minimize}
&\qpc^{T}\qpx+c_0 \\
diff --git a/QP_solver/doc/QP_solver/Concepts/NonnegativeQuadraticProgram.h b/QP_solver/doc/QP_solver/Concepts/NonnegativeQuadraticProgram.h
index b4d50c71eab..585eb911b0a 100644
--- a/QP_solver/doc/QP_solver/Concepts/NonnegativeQuadraticProgram.h
+++ b/QP_solver/doc/QP_solver/Concepts/NonnegativeQuadraticProgram.h
@@ -5,17 +5,6 @@
A model of `NonnegativeQuadraticProgram` describes a convex quadratic program of the form
-\f$
-\newcommand{\qprel}{\gtreqless}
-\newcommand{\qpx}{\mathbf{x}}
-\newcommand{\qpl}{\mathbf{l}}
-\newcommand{\qpu}{\mathbf{u}}
-\newcommand{\qpc}{\mathbf{c}}
-\newcommand{\qpb}{\mathbf{b}}
-\newcommand{\qpy}{\mathbf{y}}
-\newcommand{\qpw}{\mathbf{w}}
-\newcommand{\qplambda}{\mathbf{\lambda}}
-\f$
\f{eqnarray*}{
\mbox{(QP)}& \mbox{minimize}
& \qpx^{T}D\qpx+\qpc^{T}\qpx+c_0 \\
diff --git a/QP_solver/doc/QP_solver/Concepts/QuadraticProgram.h b/QP_solver/doc/QP_solver/Concepts/QuadraticProgram.h
index 9d0a7eb8d3e..906ff67621e 100644
--- a/QP_solver/doc/QP_solver/Concepts/QuadraticProgram.h
+++ b/QP_solver/doc/QP_solver/Concepts/QuadraticProgram.h
@@ -5,18 +5,6 @@
A model of `QuadraticProgram` describes a convex quadratic program of the form
-\f$
-\newcommand{\qprel}{\gtreqless}
-\newcommand{\qpx}{\mathbf{x}}
-\newcommand{\qpl}{\mathbf{l}}
-\newcommand{\qpu}{\mathbf{u}}
-\newcommand{\qpc}{\mathbf{c}}
-\newcommand{\qpb}{\mathbf{b}}
-\newcommand{\qpy}{\mathbf{y}}
-\newcommand{\qpw}{\mathbf{w}}
-\newcommand{\qplambda}{\mathbf{\lambda}}
-\f$
-
\f{eqnarray*}{
\mbox{(QP)}& \mbox{minimize}
& \qpx^{T}D\qpx+\qpc^{T}\qpx+c_0 \\
diff --git a/QP_solver/doc/QP_solver/QP_solver.txt b/QP_solver/doc/QP_solver/QP_solver.txt
index 037747f31bf..dbdf2bcbeeb 100644
--- a/QP_solver/doc/QP_solver/QP_solver.txt
+++ b/QP_solver/doc/QP_solver/QP_solver.txt
@@ -8,18 +8,6 @@ namespace CGAL {
\authors Kaspar Fischer, Bernd Gärtner, Sven Schönherr, and Frans Wessendorp
-\f$
-\newcommand{\qprel}{\gtreqless}
-\newcommand{\qpx}{\mathbf{x}}
-\newcommand{\qpl}{\mathbf{l}}
-\newcommand{\qpu}{\mathbf{u}}
-\newcommand{\qpc}{\mathbf{c}}
-\newcommand{\qpb}{\mathbf{b}}
-\newcommand{\qpy}{\mathbf{y}}
-\newcommand{\qpw}{\mathbf{w}}
-\newcommand{\qplambda}{\mathbf{\lambda}}
-\f$
-
\section secQPdef Which Programs can be Solved?
This package lets you solve convex quadratic programs of the
diff --git a/Skin_surface_3/doc/Skin_surface_3/Skin_surface_3.txt b/Skin_surface_3/doc/Skin_surface_3/Skin_surface_3.txt
index 83e8823ca92..6fa40543a0f 100644
--- a/Skin_surface_3/doc/Skin_surface_3/Skin_surface_3.txt
+++ b/Skin_surface_3/doc/Skin_surface_3/Skin_surface_3.txt
@@ -5,11 +5,6 @@ namespace CGAL {
\mainpage User Manual
\anchor Chapter_3D_Skin_Surface_Meshing
\anchor chapterSkinSurface
-\htmlonly
-\( \newcommand\ssWpoint[1]{{\bf #1}} \)
-\( \newcommand\ssWeight[1]{w_{#1}} \)
-\( \newcommand{\dabs}[1]{{\parallel\! #1 \!\parallel}} \)
-\endhtmlonly
\cgalAutoToc
\author Nico Kruithof