3

Is it possible to encase numbers in hearts instead of parenthesis when my equations are enumerated?

1 Answers1

3

Set the equation's "tag form" using mathtools:

enter image description here

\documentclass{article}

\usepackage{mathtools}

% \newtagform{<name>}{<left>}{<right>}
\newtagform{hearts}{$\heartsuit$}{$\heartsuit$}
\usetagform{hearts}

\begin{document}

See~\eqref{eq:abc}.
\begin{equation}
  f(x) = ax^2 + bx + c \label{eq:abc}
\end{equation}

\end{document}

Perhaps you might be interested in putting the number inside a heart:

enter image description here

\documentclass{article}

\usepackage{mathtools,graphicx}

\newcommand{\enheart}[1]{%
  \smash{%
    \ooalign{%
      \scalebox{1.5}{\raisebox{-.2ex}{$\heartsuit$}}\cr
      \hidewidth\raisebox{.5ex}{\tiny #1}\hidewidth}}}
% \newtagform{<name>}[<inner>]{<left>}{<right>}
\newtagform{hearts}[\enheart]{}{}
\usetagform{hearts}

\begin{document}

See~\eqref{eq:abc}.
\begin{equation}
  f(x) = ax^2 + bx + c \label{eq:abc}
\end{equation}

\end{document}

You'll have to shrink the number and enlarge the heart, which might cause problems with line-spacing (hence the \smash).

To switch back to the default, use \usetagform{default}.

Werner
  • 603,163