diff --git a/doc/computation/fluid.rst b/doc/computation/fluid.rst
index 070cb7b3..ea6f0569 100644
--- a/doc/computation/fluid.rst
+++ b/doc/computation/fluid.rst
@@ -520,8 +520,14 @@ in the surrounding flow a circulation of sufficient strength to hold the rear st
This is the Kutta condition, a fluid dynamic phenomenon that can be observed for solid bodies with sharp corners, such
as slender bodies or the trailing edges of airfoils.
-.. cssclass:: caption-small
.. figure:: ../images/computation/kutta_cond_plate.svg
+ :class: only-light
+ :figwidth: 95%
+ :align: left
+
+.. cssclass:: caption-small
+.. figure:: ../images/computation/kutta_cond_plate_dark.svg
+ :class: only-dark
:figwidth: 95%
:align: left
diff --git a/doc/computation/index.rst b/doc/computation/index.rst
index 190be5ac..9e7dcedc 100644
--- a/doc/computation/index.rst
+++ b/doc/computation/index.rst
@@ -966,6 +966,12 @@ is :math:`E f`. The matrix of basis vectors is constructed as follows.
.. image:: ../images/computation/contact_frame.svg
:width: 700px
:align: center
+ :class: only-light
+
+.. image:: ../images/computation/contact_frame_dark.svg
+ :width: 700px
+ :align: center
+ :class: only-dark
The figure illustrates the full basis set corresponding to the case :math:`n = 6`. Otherwise we use only the first
:math:`n` or :math:`2(n-1)` columns depending on the cone type. Elliptic cones are easier to understand. Since the
@@ -1325,6 +1331,12 @@ representations of the constraint Jacobian and related matrices.
.. image:: ../images/computation/gPGS.svg
:width: 500px
:align: center
+ :class: only-light
+
+ .. image:: ../images/computation/gPGS_dark.svg
+ :width: 500px
+ :align: center
+ :class: only-dark
When using pyramidal friction cones, the problem involves box constraints to which PGS has traditionally been
applied. If we applied PGS directly to the conic constraints resulting from elliptic friction cones, it would get
@@ -1424,12 +1436,18 @@ approximations, no matter how accurate the approximation is. The figure below il
where the pyramid is not even an approximation, but represents the same constraint set as the elliptic cone. We plot the
contours of the penalty/shadow for the pyramidal (red) and elliptic (dashed blue) cones, for different friction
coefficients varying from left to right. Mathematically, the penalty in the pyramidal case is a quadratic spline, while
-the penalty in the elliptic case contains pieces that are quadratics minus square roots of quadratics - allowing
+the penalty in the elliptic case contains pieces that are quadratics minus square roots of quadratics -- allowing
circular contours around the tip of the cone.
.. image:: ../images/computation/softcontact.png
:width: 600px
:align: center
+ :class: only-light
+
+.. image:: ../images/computation/softcontact_dark.png
+ :width: 600px
+ :align: center
+ :class: only-dark
In summary, elliptic and pyramidal friction cones define different soft-contact dynamics (although they are usually very
close). The elliptic model is more principled and more consistent with physical intuition, and the corresponding solvers
diff --git a/doc/images/computation/contact_frame_dark.svg b/doc/images/computation/contact_frame_dark.svg
new file mode 100644
index 00000000..ea67cb4f
--- /dev/null
+++ b/doc/images/computation/contact_frame_dark.svg
@@ -0,0 +1,296 @@
+
+
diff --git a/doc/images/computation/gPGS_dark.svg b/doc/images/computation/gPGS_dark.svg
new file mode 100644
index 00000000..7a8cca57
--- /dev/null
+++ b/doc/images/computation/gPGS_dark.svg
@@ -0,0 +1,102 @@
+
+
diff --git a/doc/images/computation/kutta_cond_plate_dark.svg b/doc/images/computation/kutta_cond_plate_dark.svg
new file mode 100644
index 00000000..18ea52df
--- /dev/null
+++ b/doc/images/computation/kutta_cond_plate_dark.svg
@@ -0,0 +1,124 @@
+
+
diff --git a/doc/images/computation/softcontact_dark.png b/doc/images/computation/softcontact_dark.png
new file mode 100644
index 00000000..f10cf3f9
Binary files /dev/null and b/doc/images/computation/softcontact_dark.png differ
diff --git a/doc/images/modeling/flexelem.png b/doc/images/modeling/flexelem.png
index 39df7463..74dbe6a8 100644
Binary files a/doc/images/modeling/flexelem.png and b/doc/images/modeling/flexelem.png differ
diff --git a/doc/images/modeling/impedance_dark.png b/doc/images/modeling/impedance_dark.png
new file mode 100644
index 00000000..ecb40fd7
Binary files /dev/null and b/doc/images/modeling/impedance_dark.png differ
diff --git a/doc/images/modeling/musclemodel_dark.png b/doc/images/modeling/musclemodel_dark.png
new file mode 100644
index 00000000..c301fe66
Binary files /dev/null and b/doc/images/modeling/musclemodel_dark.png differ
diff --git a/doc/images/modeling/musclerange_dark.png b/doc/images/modeling/musclerange_dark.png
new file mode 100644
index 00000000..8c7bf8e6
Binary files /dev/null and b/doc/images/modeling/musclerange_dark.png differ
diff --git a/doc/modeling.rst b/doc/modeling.rst
index b146407f..5cd4cbb6 100644
--- a/doc/modeling.rst
+++ b/doc/modeling.rst
@@ -318,7 +318,15 @@ of the function :math:`d(r)` is determined by the element-specific parameter vec
units of :math:`\text{width}`. Note that when :math:`\text{power}` is 1, the function is linear regardless of the
:math:`\text{midpoint}`.
- |image0|
+ .. image:: images/modeling/impedance.png
+ :width: 600px
+ :align: center
+ :class: only-light
+
+ .. image:: images/modeling/impedance_dark.png
+ :width: 600px
+ :align: center
+ :class: only-dark
These plots show the impedance :math:`d(r)` on the vertical axis, as a function of the constraint violation :math:`r`
on the horizontal axis.
@@ -865,7 +873,15 @@ The advantage of the scaled quantities is that all muscles behave similarly in t
captured by the Force-Length-Velocity (:math:`\text{\small FLV}`) function measured in many experimental papers. We
approximate this function as follows:
-|image1|
+.. image:: images/modeling/musclemodel.png
+ :width: 650px
+ :align: center
+ :class: only-light
+
+.. image:: images/modeling/musclemodel_dark.png
+ :width: 650px
+ :align: center
+ :class: only-dark
The function is in the form:
@@ -907,7 +923,15 @@ Before embarking on a mission to design more accurate :math:`\text{\small FLV}`
operating range of the muscle has a bigger effect than the shape of the :math:`\text{\small FLV}` function, and in many
cases this parameter is unknown. Below is a graphical illustration:
-|image2|
+.. image:: images/modeling/musclerange.png
+ :width: 500px
+ :align: center
+ :class: only-light
+
+.. image:: images/modeling/musclerange_dark.png
+ :width: 500px
+ :align: center
+ :class: only-dark
This figure format is common in the biomechanics literature, showing the operating range of each muscle superimposed on
the normalized :math:`\text{FL}` curve (ignore the vertical displacement). Our default range is shown in black. The blue
@@ -1311,7 +1335,9 @@ A flex is a collection of MuJoCo bodies that are connected with massless stretch
capsules (1D flex), triangles (2D flex), or tetrahedra (3D flex). In all cases we allow a radius, which makes the
elements smooth and also volumetric in 1D and 2D. The primitive elements are illustrated below:
-|flexelem|
+.. image:: images/modeling/flexelem.png
+ :width: 600px
+ :align: center
Thus far these look like geoms. But the key difference is that they deform: as the bodies (vertices) move independently
of each other, the shape of the elements changes in real time. Collisions and contact forces are now generalized to
@@ -1677,12 +1703,6 @@ in a visible way, and the energy fluctuates around the initial value instead of
-.. |image0| image:: images/modeling/impedance.png
- :width: 600px
-.. |image1| image:: images/modeling/musclemodel.png
- :width: 650px
-.. |image2| image:: images/modeling/musclerange.png
- :width: 400px
.. |image3| image:: images/modeling/tendonwraps.png
:width: 500px
.. |image4| image:: images/modeling/particle.png
@@ -1719,8 +1739,6 @@ in a visible way, and the energy fluctuates around the initial value instead of
:height: 250px
.. |particle| image:: images/models/particle.gif
:width: 270px
-.. |flexelem| image:: images/modeling/flexelem.png
- :width: 400px
.. |bunny1| image:: images/modeling/bunny1.png
:width: 300px
.. |bunny2| image:: images/modeling/bunny2.png