17

A dual number is a number of the form $a+b\varepsilon$, where $a,b \in \mathbb{R}$ and $\varepsilon$ is a nonreal number with the property $\varepsilon^2=0$. Dual numbers are in some ways similar to the complex numbers $a+bi$, where $i^2=-1$.

Complex numbers have a very elegant geometric interpretation. Specifically, we can treat complex numbers as vectors in the complex plane. Addition and subtraction then follow the regular rules of vector arithmetic, and complex multiplication can be seen as a scaling and rotation of one vector by the magnitude and argument of another, respectively.

Is there a corresponding geometric interpretation for dual number arithmetic in the dual plane?

The Art Of Repetition
  • 2,428
  • 1
  • 7
  • 34
David Zhang
  • 9,125
  • 2
  • 43
  • 64

3 Answers3

12

Dual numbers, unlike complex numbers, illustrate Galileo's invariance principle. The infinitesimal part of a dual number represents the velocity.

In particular, whereas the multiplication of two complex numbers can be understood as a combination of scaling and rotation, the multiplication of dual numbers is actually equivalent to a scaling and shear mapping of plane, since $(1 + p \varepsilon)(1 + q \varepsilon) = 1 + (p+q) \varepsilon$. You can see that the classical velocity addition law emerges.

The "hyperbolic" multiplication law of special relativity (namely the corresponding velocity addition law $v\oplus u=(v+u)/(1+vu)$) requires Lorentz transformations, which can be packaged into different types of numbers like, for example, quaternions (see Generalized complex numbers).

5

Dual numbers are numbers with tangents. For any analytical function $f$ one obtains exactly $f(x+ε\dot x)=f(x)+εf'(x)\dot x$.

An old trick in computing derivatives is to turn an implementation of complex numbers into dual numbers by initializing $z=x+i\cdot 10^{-40}\cdot\dot x$, so that the imaginary part has practically no influence on the real part, and the derivative can easily be recovered from the imaginary part.

Lutz Lehmann
  • 131,652
  • What are the requirements on f for this to work? It seems to me that it only works for polynomial functions where the exponent is strictly positive (e.g. breaks for f:x->x^-1, or f:x->ln(x)). – ChrisR Dec 31 '16 at 06:51
  • For what to work? $(x+ε\dot x)^{-1}=(x-ε\dot x)/x^2$, $\ln(x+ε\dot x)=\ln(x)+ε\dot x/x$ etc. The complex trick works for all holomorphic functions. Of course one needs an implementation of them for a complex number type. – Lutz Lehmann Dec 31 '16 at 07:46
  • Do you have a paper or a reference with how to perform the natural logarithm of a dual number? I found a quite recent paper from two Italian researchers which describes the trigonometry functions and the inverse function, but not the log. Thank you. – ChrisR Dec 31 '16 at 07:50
  • You only need to know that $\ln$ is analytical and that $\frac{d}{dx}\ln x=1/x$, see the first formula in the answer. – Lutz Lehmann Dec 31 '16 at 07:52
  • Okay. So that means I can't feed a dual number into a function whose derivative I don't know in order to find the derivative of that function at the point \dot x? – ChrisR Dec 31 '16 at 07:54
1

You can imagine the dual numbers of the form $a + \epsilon \cdot b$ as situated on the orthogonal line centered at $a$ in the dual number "plane". You can also treat them as vectors but then the modulus is evaluated as $|| a + \epsilon \cdot b || = abs (a)$ because of the nilpotency.

user48672
  • 1,202