{
  "id": "eulers-formula",
  "title": "Euler's Formula",
  "lang": "en",
  "source_lang": "en",
  "summary": "Euler’s formula relates complex exponentials to sine and cosine, connecting rotation, oscillation, and the algebra of complex numbers.",
  "category": "mathematics",
  "subcategory": "analysis",
  "type": "concept",
  "aliases": [
    "Euler’s exponential formula",
    "Euler’s relation"
  ],
  "generated_at": "2026-11-03",
  "model": "pro/gpt-6.1-sol",
  "url": "https://aiwiki.page/en/eulers-formula/",
  "translations": {
    "zh-Hans": {
      "url": "https://aiwiki.page/zh/eulers-formula/",
      "json": "https://aiwiki.page/zh/eulers-formula.json"
    }
  },
  "sections": [
    {
      "heading": "",
      "text": "Euler’s formula is the identity\n\n\\[e^{i\\theta}=\\cos\\theta+i\\sin\\theta,\\]\n\nwhere \\(e\\) is Euler’s number, \\(i\\) is the imaginary unit satisfying \\(i^2=-1\\), and \\(\\theta\\) is a real angle measured in radians. It connects the exponential function with the trigonometric functions, showing that an exponential with a purely imaginary exponent describes a point moving around the unit circle. Named after Leonhard Euler, the formula is a central identity in complex analysis.\n\nIts importance extends beyond the evaluation of complex expressions. Euler’s formula turns multiplication into the addition of angles, represents sinusoidal motion through exponentials, and supplies the basic functions used in Fourier analysis. It also underlies methods for solving differential equations, analyzing electrical circuits, describing waves, and constructing rotations. At \\(\\theta=\\pi\\), it gives the special case \\(e^{i\\pi}+1=0\\), commonly called Euler’s identity."
    },
    {
      "heading": "Mathematical statement and conventions",
      "text": "The expression \\(e^{i\\theta}\\) is a complex number, not a real exponential with an unusual numerical input. Every complex number can be written \\(x+iy\\), where \\(x\\) and \\(y\\) are real numbers. Euler’s formula identifies the real and imaginary parts of this particular exponential:\n\n\\[\\operatorname{Re}(e^{i\\theta})=\\cos\\theta, \\qquad \\operatorname{Im}(e^{i\\theta})=\\sin\\theta.\\]\n\nThus an expression involving one complex exponential contains two real-valued functions. This pairing is especially useful when two quantities vary sinusoidally with a quarter-cycle phase difference.\n\nThe angle must be measured in radians for the formula to have this form. Radian measure defines an angle as arc length divided by radius, so a complete turn corresponds to \\(2\\pi\\), where \\pi is the ratio of a circle’s circumference to its diameter. If a numerical angle \\(\\alpha\\) is expressed in degrees, the corresponding exponential is \\(e^{i\\pi\\alpha/180}\\). The radian convention also ensures that the derivatives of sine and cosine have their familiar forms without additional conversion factors.\n\nThe modulus, or absolute value, of \\(x+iy\\) is \\(\\sqrt{x^2+y^2}\\). Consequently,\n\n\\[|e^{i\\theta}| =\\sqrt{\\cos^2\\theta+\\sin^2\\theta} =1.\\]\n\nThe complex exponential therefore remains on the unit circle when its exponent is purely imaginary. This contrasts with the real exponential \\(e^x\\), whose values are positive and whose magnitude changes as \\(x\\) changes. Imaginary increments in an exponent change phase, while real increments change magnitude.\n\nMore generally, for \\(z=x+iy\\),\n\n\\[e^z=e^{x+iy}=e^x(\\cos y+i\\sin y).\\]\n\nThis formula separates the two roles of a complex exponent: \\(e^x\\) is a positive scale factor, and \\(y\\) is an angle. In particular, \\(e^z\\) is never zero, its modulus is \\(e^x\\), and it is periodic in the imaginary direction:\n\n\\[e^{z+2\\pi i}=e^z.\\]\n\nThese properties distinguish the complex exponential from its restriction to the real line, which is one-to-one.\n\nThe notation \\(e^z\\) is justified by an extension of real exponentiation, usually constructed through an infinite series or a differential equation. Euler’s formula is then a theorem about that extension. In another common presentation, the formula helps define the complex exponential from independently established real exponential and trigonometric functions. Either approach requires verification that the resulting function obeys the exponential law \\(e^{z+w}=e^ze^w\\)."
    },
    {
      "heading": "Historical development",
      "text": "Euler’s formula emerged from the gradual recognition that logarithms, trigonometry, and imaginary quantities belonged to a common mathematical framework. During the seventeenth and early eighteenth centuries, complex expressions increasingly appeared in algebraic calculations, although their geometric and analytic interpretation was not yet standardized. Trigonometric addition formulas already suggested that certain expressions involving sine and cosine had a multiplicative structure resembling the rules for powers.\n\nAbraham de Moivre developed a closely related connection between complex powers and multiple angles. In its modern form, de Moivre’s formula states\n\n\\[(\\cos\\theta+i\\sin\\theta)^n =\\cos(n\\theta)+i\\sin(n\\theta)\\]\n\nfor every integer \\(n\\). This identity concerns integer powers and can be proved directly from the trigonometric addition formulas. Euler’s formula places the same relationship within the broader theory of exponential functions, allowing a continuous parameter to replace the integer exponent.\n\nRoger Cotes published a related logarithmic relationship in 1714. In modern notation and with suitable choices of angle and logarithm, it connects the logarithm of \\(\\cos\\theta+i\\sin\\theta\\) with \\(i\\theta\\). Such statements require care because a complex logarithm has multiple values, a feature not fully organized in the early development of the subject. Cotes’s work nevertheless represents an important predecessor to the exponential-trigonometric connection associated with Euler.\n\nEuler presented the relationship prominently in his 1748 work Introductio in analysin infinitorum. His treatment brought exponential and trigonometric functions together through the systematic use of infinite series and imaginary quantities. It also expressed sine and cosine in terms of exponentials with imaginary arguments. These expressions made it possible to move between algebraic operations on exponentials and identities involving circular functions, providing a particularly effective language for analysis.\n\nThe modern theorem belongs to a more rigorous framework than the formal manipulations through which many of its consequences were first discovered. Nineteenth-century developments in convergence, complex differentiation, and the geometry of complex numbers clarified why the relevant series can be differentiated and rearranged. The formula’s historical significance therefore lies not only in a striking equality but also in its role in unifying previously separate classes of functions. The name “Euler’s formula” is also used for unrelated results, including his polyhedral relation \\(V-E+F=2\\); the exponential formula is distinguished by its connection between \\(e^{i\\theta}\\), cosine, and sine."
    },
    {
      "heading": "Proofs from series and differential equations",
      "text": "A standard proof begins with the power-series definition of the exponential:\n\n\\[e^z=\\sum_{n=0}^{\\infty}\\frac{z^n}{n!}.\\]\n\nHere \\(n!\\) denotes the factorial of \\(n\\), with \\(0!=1\\). This series converges absolutely for every complex \\(z\\). Substituting \\(z=i\\theta\\), and using the repeating pattern \\(1,i,-1,-i\\) for powers of \\(i\\), gives\n\n\\[\\begin{aligned} e^{i\\theta} &=\\left(1-\\frac{\\theta^2}{2!} +\\frac{\\theta^4}{4!}-\\cdots\\right)\\\\ &\\quad+i\\left(\\theta-\\frac{\\theta^3}{3!} +\\frac{\\theta^5}{5!}-\\cdots\\right). \\end{aligned}\\]\n\nThe two series in parentheses are the Taylor series of cosine and sine, respectively. Absolute convergence justifies separating the even-indexed and odd-indexed terms.\n\nThis proof establishes more than a formal resemblance between expressions. On every bounded region of the complex plane, the exponential series and its differentiated series converge uniformly. The corresponding results for sine and cosine allow these functions to be differentiated term by term. The equality is consequently compatible with the analytic properties of all three functions, rather than depending on an informal substitution into a real-variable formula.\n\nA second proof uses an ordinary differential equation. Let\n\n\\[f(\\theta)=\\cos\\theta+i\\sin\\theta.\\]\n\nThen\n\n\\[f'(\\theta)=-\\sin\\theta+i\\cos\\theta=if(\\theta), \\qquad f(0)=1.\\]\n\nThe function \\(g(\\theta)=e^{i\\theta}\\) satisfies the same initial-value problem,\n\n\\[g'=ig,\\qquad g(0)=1.\\]\n\nUniqueness of solutions implies \\(f=g\\). Although the equation is complex-valued, it can be regarded as a system of two real equations. Writing \\(f=x+iy\\) gives\n\n\\[x'=-y,\\qquad y'=x,\\]\n\nwith \\(x(0)=1\\) and \\(y(0)=0\\).\n\nA closely related argument avoids explicitly invoking a uniqueness theorem. If complex exponentiation and its differentiation rule have already been established, define\n\n\\[h(\\theta)=e^{-i\\theta}(\\cos\\theta+i\\sin\\theta).\\]\n\nThe product rule yields \\(h'(\\theta)=0\\), so \\(h\\) is constant. Since \\(h(0)=1\\), multiplication by \\(e^{i\\theta}\\) gives Euler’s formula. The vanishing derivative can be interpreted componentwise for the real and imaginary parts.\n\nThese proofs depend on how the functions were introduced. If sine and cosine are defined geometrically, their derivative formulas and series expansions require prior justification. If all three functions are defined by their power series, the first proof is immediate once convergence is established. If the complex exponential is defined through a differential equation, uniqueness becomes the central step. A valid proof must keep these dependencies clear: a derivative or identity derived from Euler’s formula cannot independently be used to establish the same formula."
    },
    {
      "heading": "Circular geometry, multiplication, and roots",
      "text": "In the complex plane, the number \\(x+iy\\) is represented by the point \\((x,y)\\). Euler’s formula identifies\n\n\\[e^{i\\theta}\\longleftrightarrow(\\cos\\theta,\\sin\\theta),\\]\n\nso it parametrizes the unit circle counterclockwise from the point \\(1\\). Differentiating with respect to \\(\\theta\\) gives\n\n\\[\\frac{d}{d\\theta}e^{i\\theta}=ie^{i\\theta}.\\]\n\nMultiplication by \\(i\\) rotates a vector through a right angle. The velocity is therefore perpendicular to the radius and has unit magnitude, explaining geometrically why the path is circular and why \\(\\theta\\) measures arc length on the unit circle.\n\nEvery nonzero complex number has a polar representation\n\n\\[z=re^{i\\theta}, \\qquad r=|z|>0.\\]\n\nThe angle \\(\\theta\\), called an argument of \\(z\\), is determined only up to an integer multiple of \\(2\\pi\\). In polar coordinates, multiplication becomes\n\n\\[(r_1e^{i\\theta_1})(r_2e^{i\\theta_2}) =r_1r_2e^{i(\\theta_1+\\theta_2)}.\\]\n\nThus magnitudes multiply and arguments add. Multiplication by a fixed nonzero complex number is a rotation combined with uniform scaling; division reverses these operations.\n\nThe exponential law immediately produces the trigonometric addition formulas. Expanding both sides of\n\n\\[e^{i(\\alpha+\\beta)}=e^{i\\alpha}e^{i\\beta}\\]\n\nand equating real and imaginary parts gives\n\n\\[\\cos(\\alpha+\\beta) =\\cos\\alpha\\cos\\beta-\\sin\\alpha\\sin\\beta,\\]\n\n\\[\\sin(\\alpha+\\beta) =\\sin\\alpha\\cos\\beta+\\cos\\alpha\\sin\\beta.\\]\n\nInteger powers similarly yield de Moivre’s formula. This is one reason exponential notation simplifies trigonometric calculations: an angle-addition problem becomes an application of familiar multiplication rules.\n\nSetting \\(\\theta=\\pi\\) yields Euler’s identity,\n\n\\[e^{i\\pi}+1=0.\\]\n\nOther special angles give \\(e^{i\\pi/2}=i\\) and \\(e^{2\\pi i}=1\\). More generally, the \\(n\\)th roots of unity are\n\n\\[\\zeta_k=e^{2\\pi ik/n}, \\qquad k=0,1,\\ldots,n-1.\\]\n\nThey are the vertices of a regular \\(n\\)-sided polygon inscribed in the unit circle. Multiplication permutes these roots, and the powers of \\(e^{2\\pi i/n}\\) generate all of them.\n\nFor a nonzero number \\(w=re^{i\\theta}\\), its \\(n\\) distinct \\(n\\)th roots are\n\n\\[z_k=r^{1/n}e^{i(\\theta+2\\pi k)/n}, \\qquad k=0,\\ldots,n-1.\\]\n\nFor example, the cube roots of \\(1\\) are \\(1\\), \\(-\\tfrac12+i\\tfrac{\\sqrt3}{2}\\), and \\(-\\tfrac12-i\\tfrac{\\sqrt3}{2}\\). Their equally spaced arguments make the algebraic symmetry visible. In group theory, the unit complex numbers form a group under multiplication, and the map \\(\\theta\\mapsto e^{i\\theta}\\) converts addition of real numbers into that group operation."
    },
    {
      "heading": "Complex arguments and logarithms",
      "text": "Euler’s formula explains both the usefulness and the multivalued nature of the complex logarithm. If\n\n\\[z=re^{i\\theta}\\ne0,\\]\n\nthen every solution \\(w\\) of \\(e^w=z\\) has the form\n\n\\[w=\\ln r+i(\\theta+2\\pi k), \\qquad k\\in\\mathbb Z.\\]\n\nThe real part is fixed by the modulus, while the imaginary part records any possible argument. Unlike the real exponential, the complex exponential is not injective: changing an input by \\(2\\pi i k\\) leaves its value unchanged.\n\nA single-valued logarithm can be obtained by choosing a branch of the argument. A standard analytic principal branch uses\n\n\\[-\\pi<\\operatorname{Arg}z<\\pi\\]\n\non the complex plane with the nonpositive real axis removed, and defines\n\n\\[\\operatorname{Log}z=\\ln|z|+i\\operatorname{Arg}z.\\]\n\nOn this domain, \\(\\operatorname{Log}\\) is an analytic function with derivative \\(1/z\\). Some conventions assign a principal value on the negative real axis as well, but that assignment does not remove the discontinuity across the axis.\n\nThe obstruction to choosing a continuous argument on the entire punctured plane is geometric. Traveling once counterclockwise around the origin increases a continuously tracked angle by \\(2\\pi\\), even though the starting and ending points coincide. This phenomenon connects the exponential to topology. The kernel of the homomorphism from the additive real numbers to the unit circle is \\(2\\pi\\mathbb Z\\), so angles are naturally identified modulo full turns.\n\nBranch choices affect logarithmic identities. Although \\(e^{u+v}=e^ue^v\\) holds for all complex \\(u,v\\), a chosen logarithm need not satisfy\n\n\\[\\operatorname{Log}(zw)=\\operatorname{Log}z+\\operatorname{Log}w.\\]\n\nFor example, let \\(z=w=e^{3\\pi i/4}\\). Then \\(zw=-i\\), and the principal logarithms satisfy\n\n\\[\\operatorname{Log}z+\\operatorname{Log}w=\\frac{3\\pi i}{2}, \\qquad \\operatorname{Log}(zw)=-\\frac{\\pi i}{2}.\\]\n\nThe values differ by \\(2\\pi i\\), exactly the period of the exponential.\n\nComplex powers inherit the same issue. After choosing a logarithm, one may define \\(z^\\alpha=\\exp(\\alpha\\operatorname{Log}z)\\). Allowing all logarithm values instead produces a generally multivalued power. For instance, using the principal value of the logarithm at \\(i\\),\n\n\\[i^i=\\exp\\!\\left(i\\frac{\\pi i}{2}\\right)=e^{-\\pi/2}.\\]\n\nUsing every logarithm of \\(i\\) gives the values \\(e^{-\\pi/2-2\\pi k}\\), with \\(k\\in\\mathbb Z\\). These are real and positive despite involving an imaginary base and exponent. Their multiplicity reflects the periodicity already present in Euler’s formula."
    },
    {
      "heading": "Fourier analysis and spectral representations",
      "text": "Euler’s formula allows sine and cosine to be written as combinations of complex exponentials:\n\n\\[\\cos\\theta=\\frac{e^{i\\theta}+e^{-i\\theta}}{2}, \\qquad \\sin\\theta=\\frac{e^{i\\theta}-e^{-i\\theta}}{2i}.\\]\n\nThese identities follow by adding and subtracting the formulas for \\(e^{i\\theta}\\) and \\(e^{-i\\theta}\\). They replace separate sine and cosine calculations with a single exponential notation and form a foundation of harmonic analysis.\n\nFor a sufficiently well-behaved \\(2\\pi\\)-periodic function, a Fourier series can be written\n\n\\[f(t)\\sim\\sum_{n\\in\\mathbb Z}c_ne^{int}, \\qquad c_n=\\frac{1}{2\\pi}\\int_{-\\pi}^{\\pi}f(t)e^{-int}\\,dt.\\]\n\nThe symbol \\(\\sim\\) does not, by itself, assert convergence in every possible sense; convergence depends on the function and the chosen setting. The exponential functions are orthogonal because\n\n\\[\\frac{1}{2\\pi}\\int_{-\\pi}^{\\pi} e^{int}\\overline{e^{imt}}\\,dt = \\begin{cases} 1,&n=m,\\\\ 0,&n\\ne m. \\end{cases}\\]\n\nHere the overline denotes complex conjugation. This orthogonality separates different integer frequencies under the relevant inner product.\n\nIf \\(f\\) is real-valued, its coefficients satisfy \\(c_{-n}=\\overline{c_n}\\). Positive and negative frequencies are therefore not independent pieces of information in a real signal. For example,\n\n\\[A\\cos(\\omega t+\\phi) =\\frac{A}{2}e^{i\\phi}e^{i\\omega t} +\\frac{A}{2}e^{-i\\phi}e^{-i\\omega t}.\\]\n\nThe two terms rotate in opposite directions in the complex plane and add to a real oscillation. Negative frequency in this representation records the direction of phase rotation, rather than a negative number of cycles counted in time.\n\nThe Fourier transform extends this representation from discrete frequencies to a continuous frequency variable. With one common angular-frequency convention,\n\n\\[\\widehat f(\\omega) =\\int_{-\\infty}^{\\infty}f(t)e^{-i\\omega t}\\,dt.\\]\n\nBecause differentiating \\(e^{i\\omega t}\\) multiplies it by \\(i\\omega\\), differentiation becomes multiplication in the frequency domain under suitable hypotheses:\n\n\\[\\widehat{f'}(\\omega)=i\\omega\\widehat f(\\omega).\\]\n\nLikewise, convolution becomes multiplication. These properties turn many linear operations on signals or functions into simpler algebraic operations on their frequency components.\n\nFor sampled data, the discrete Fourier transform uses a finite collection of roots of unity:\n\n\\[X_k=\\sum_{n=0}^{N-1}x_n e^{-2\\pi i kn/N}, \\qquad k=0,\\ldots,N-1.\\]\n\nThe fast Fourier transform exploits symmetries among these roots to reduce the arithmetic required to compute the transform. Euler’s formula thereby links the geometry of equally spaced points on a circle to practical calculations in audio processing, imaging, numerical simulation, and communications."
    },
    {
      "heading": "Differential equations, oscillations, and phasors",
      "text": "Complex exponentials are particularly effective in linear differential equations because differentiation preserves their form:\n\n\\[\\frac{d}{dt}e^{st}=se^{st}.\\]\n\nWhen \\(s=\\sigma+i\\omega\\), Euler’s formula gives\n\n\\[e^{st}=e^{\\sigma t} \\bigl(\\cos\\omega t+i\\sin\\omega t\\bigr).\\]\n\nThe real part \\(\\sigma\\) controls exponential growth or decay, while the imaginary part \\(\\omega\\) controls oscillation. This separates two qualitatively different features of a solution within one parameter.\n\nFor the harmonic oscillator,\n\n\\[x''+\\omega_0^2x=0,\\]\n\nthe characteristic equation is \\(s^2+\\omega_0^2=0\\), with roots \\(s=\\pm i\\omega_0\\). Complex exponential solutions therefore combine into the real general solution\n\n\\[x(t)=A\\cos\\omega_0t+B\\sin\\omega_0t.\\]\n\nFor the damped equation\n\n\\[x''+2\\gamma x'+\\omega_0^2x=0,\\]\n\nthe underdamped case \\(0<\\gamma<\\omega_0\\) has roots\n\n\\[-\\gamma\\pm i\\sqrt{\\omega_0^2-\\gamma^2}.\\]\n\nThe resulting real motion is a sinusoid multiplied by the decaying envelope \\(e^{-\\gamma t}\\). The geometry of the complex roots directly identifies the decay rate and oscillation frequency.\n\nIn sinusoidal steady-state analysis, a phasor records an oscillation’s amplitude and phase in a fixed complex number:\n\n\\[x(t)=\\operatorname{Re}\\{Xe^{i\\omega t}\\}, \\qquad X=Ae^{i\\phi}.\\]\n\nAt a common frequency \\(\\omega\\), differentiation corresponds to replacing \\(X\\) by \\(i\\omega X\\). This reduces linear differential equations to algebraic equations between complex amplitudes. The method describes steady-state sinusoidal behavior; transient terms still require separate treatment when they are relevant.\n\nFor example, under the \\(e^{i\\omega t}\\) convention, the impedances of an ideal resistor, inductor, and capacitor are\n\n\\[Z_R=R,\\qquad Z_L=i\\omega L,\\qquad Z_C=\\frac{1}{i\\omega C}.\\]\n\nTheir phases encode the relative timing of voltage and current. Changing to an \\(e^{-i\\omega t}\\) convention changes the associated signs, but not the physical predictions when the convention is used consistently. This convention dependence is a recurring practical issue in engineering applications of Euler’s formula.\n\nTraveling waves are similarly represented by \\(e^{i(kx-\\omega t)}\\), whose real part is \\(\\cos(kx-\\omega t)\\). Spatial and temporal derivatives become multiplication by \\(ik\\) and \\(-i\\omega\\), respectively, simplifying wave equations. In quantum mechanics, an energy eigenstate acquires the time-dependent factor \\(e^{-iEt/\\hbar}\\), where \\(\\hbar\\) is the reduced Planck constant. Such a factor has unit modulus: it changes phase without changing the state’s norm. Relative phases between components can affect interference, even though a common overall phase does not change measurement probabilities."
    },
    {
      "heading": "Matrix exponentials and rotation groups",
      "text": "Euler’s formula has a direct counterpart in linear algebra. Consider the real matrix\n\n\\[J= \\begin{pmatrix} 0&-1\\\\ 1&0 \\end{pmatrix}, \\qquad J^2=-I.\\]\n\nBecause \\(J\\) satisfies the same quadratic relation as \\(i\\), its powers repeat in the same pattern. Defining the matrix exponential by its convergent power series gives\n\n\\[e^{\\theta J}=I\\cos\\theta+J\\sin\\theta = \\begin{pmatrix} \\cos\\theta&-\\sin\\theta\\\\ \\sin\\theta&\\cos\\theta \\end{pmatrix}.\\]\n\nThis is the matrix for counterclockwise rotation through angle \\(\\theta\\) in the real plane.\n\nThe correspondence is exact, not merely analogous. Associate the complex number \\(a+ib\\) with the real matrix\n\n\\[\\begin{pmatrix} a&-b\\\\ b&a \\end{pmatrix}.\\]\n\nThis association preserves addition and multiplication. Under the identification of \\(x+iy\\) with the column vector \\((x,y)^{\\mathsf T}\\), complex multiplication becomes a real linear map. Multiplication by \\(e^{i\\theta}\\) is therefore the same operation as applying the rotation matrix \\(e^{\\theta J}\\). The complex plane and the two-dimensional real vector space are describing the same transformation in different notation.\n\nThe rotation matrices satisfy\n\n\\[R(\\alpha)R(\\beta)=R(\\alpha+\\beta), \\qquad R(\\theta)^{\\mathsf T}R(\\theta)=I, \\qquad \\det R(\\theta)=1.\\]\n\nThey form the special orthogonal group \\(SO(2)\\), an example of a Lie group. The matrix \\(J\\) is its infinitesimal generator: it describes the instantaneous rate of change of rotation at angle zero. Euler’s formula thus provides an elementary example of the relationship between continuous transformation groups and their generators.\n\nA broader matrix version arises for complex matrices \\(A\\):\n\n\\[e^{iA}=\\cos A+i\\sin A,\\]\n\nwhere the exponential, sine, and cosine are all defined by power series. The proof separates even and odd powers exactly as in the scalar case. This identity involves a single matrix. It does not imply that exponentials of arbitrary different matrices obey the scalar addition law: generally,\n\n\\[e^{A+B}\\ne e^Ae^B\\]\n\nunless additional conditions, such as \\(AB=BA\\), hold.\n\nIf \\(H\\) is Hermitian, then \\(e^{iH}\\) is a unitary matrix. By the spectral theorem, its real eigenvalues \\(\\lambda_j\\) are transformed into eigenvalues \\(e^{i\\lambda_j}\\) on the unit circle. The scalar formula therefore explains why exponentiating \\(i\\) times a Hermitian matrix preserves lengths and inner products. A related extension holds for a quaternion \\(u\\) with zero real part and unit norm: since \\(u^2=-1\\),\n\n\\[e^{u\\theta}=\\cos\\theta+u\\sin\\theta.\\]\n\nThis identity is used in quaternion representations of three-dimensional rotations, where the quaternion parameter involves half the physical rotation angle."
    },
    {
      "heading": "Numerical evaluation and limitations of naive computation",
      "text": "Although Euler’s formula is exact, its numerical implementation involves approximation. A standard way to evaluate \\(e^{i\\theta}\\) is to compute \\(\\cos\\theta\\) and \\(\\sin\\theta\\) with mathematical-library routines and combine them. For \\(z=x+iy\\), the corresponding expression is\n\n\\[e^z=e^x(\\cos y+i\\sin y).\\]\n\nThe scale factor can overflow or underflow when \\(x\\) is too large in magnitude for the available floating-point arithmetic. A purely imaginary exponent has modulus one and avoids that particular difficulty, but its angle can still be difficult to evaluate accurately.\n\nThe main issue for large real angles is argument reduction. Trigonometric routines replace an angle by an equivalent smaller angle modulo a multiple of \\(\\pi/2\\) or \\(2\\pi\\), then use approximations on a short interval. If the original angle is very large, a small relative error in the stored value can correspond to a substantial absolute phase error. Accurate reduction also requires sufficiently precise constants and arithmetic; subtracting a coarse floating-point approximation to a large multiple of \\(2\\pi\\) can lose the small remainder that determines the answer.\n\nDirect summation of the exponential Taylor series is not a universally reliable alternative. For large \\(|\\theta|\\), individual terms of\n\n\\[\\sum_{n=0}^{\\infty}\\frac{(i\\theta)^n}{n!}\\]\n\nmay have enormous magnitudes even though the final answer has modulus one. Cancellation among those terms can destroy significant digits. This illustrates the distinction between an identity that proves convergence and an algorithm with good numerical stability. Practical evaluation typically combines range reduction with carefully chosen polynomial or rational approximations.\n\nSmall arguments raise a different cancellation problem. Computing \\(e^{i\\theta}-1\\) by first evaluating the exponential and then subtracting \\(1\\) can lose relative accuracy when \\(\\theta\\) is close to zero. The identity\n\n\\[e^{i\\theta}-1 =2i\\,e^{i\\theta/2}\\sin(\\theta/2)\\]\n\nprovides an alternative that avoids subtracting nearly equal real parts. Similarly,\n\n\\[1-\\cos\\theta=2\\sin^2(\\theta/2)\\]\n\nis often preferable to direct subtraction for small \\(\\theta\\). Such reformulations matter in difference formulas and algorithms that manipulate small phase changes.\n\nRepeated rotation introduces accumulated rounding error. In exact arithmetic, the recurrence\n\n\\[z_{n+1}=e^{i\\Delta\\theta}z_n\\]\n\npreserves \\(|z_n|\\), but computed values can drift away from the unit circle after many steps. Recomputing selected values from their angles or applying normalization can control different aspects of this drift, depending on the application. Closely related issues occur when generating Fourier-transform factors and simulating oscillatory systems: an exact unit-modulus identity does not by itself guarantee that a finite-precision implementation preserves magnitude or phase indefinitely."
    }
  ],
  "links": [
    "e-mathematical-constant",
    "exponential-function",
    "trigonometric-functions",
    "leonhard-euler",
    "complex-analysis",
    "complex-number",
    "real-number",
    "pi",
    "absolute-value",
    "circle",
    "exponentiation",
    "de-moivres-formula",
    "power-series",
    "factorial",
    "taylor-series",
    "ordinary-differential-equation",
    "mathematical-proof",
    "polar-coordinates",
    "roots-of-unity",
    "polygon",
    "group-theory",
    "logarithm",
    "analytic-function",
    "topology",
    "harmonic-analysis",
    "fourier-series",
    "inner-product",
    "fourier-transform",
    "convolution",
    "discrete-fourier-transform",
    "fast-fourier-transform",
    "differential-equation",
    "phasor",
    "quantum-mechanics",
    "planck-constant",
    "linear-algebra",
    "matrix",
    "matrix-exponential",
    "linear-map",
    "lie-group",
    "unitary-matrix",
    "spectral-theorem",
    "quaternion",
    "floating-point-arithmetic",
    "numerical-stability"
  ],
  "sources": [],
  "license": "https://creativecommons.org/licenses/by/4.0/"
}