Derivative in LaTeX (\frac{d}{dx})

ddx\frac{d}{dx}
LaTeX command
\frac{d}{dx}
Package
No package needed: built into LaTeX
Mode
Math mode only

Where it is used

Leibniz notation for the derivative operator with respect to x, built from a fraction.

Writing \frac{d}{dx} gives the operator form used in rules like \frac{d}{dx}\sin x = \cos x, while \frac{dy}{dx} names the derivative of a dependent variable. Many style guides set the differential d upright, as \mathrm{d}, to separate it from a variable named d; a macro such as \newcommand{\diff}{\mathrm{d}} keeps this consistent. In running text, \frac shrinks to tiny script size, so prefer \tfrac or the slash form dy/dx there. For higher orders write \frac{d^2y}{dx^2}, with the exponent on d in the numerator but on x in the denominator.

Minimal compilable example

Paste this into an empty .tex file and compile it with pdfLaTeX, XeLaTeX or LuaLaTeX.

ddxe3x=3e3x\frac{d}{dx} e^{3x} = 3e^{3x}
\documentclass{article}
\begin{document}
Derivative: $\frac{d}{dx}$

\[ \frac{d}{dx} e^{3x} = 3e^{3x} \]
\end{document}

Related symbols

All Calculus at Analysis →

Frequently asked questions

How do I write Derivative in LaTeX?
Type \frac{d}{dx} in math mode, for example $\frac{d}{dx} e^{3x} = 3e^{3x}$. It works in plain LaTeX without loading any package.
Which package do I need for \frac{d}{dx}?
None. \frac{d}{dx} is part of standard LaTeX, so it compiles with nothing in the preamble but the document class.
Can I use \frac{d}{dx} in text mode, or only in math mode?
Only in math mode. Outside $...$ LaTeX stops with "Missing $ inserted", so write $\frac{d}{dx}$ in running text.
Math poweredSumulat ng LaTeX gamit ang AI

Pinakamahusay na AI LaTeX Editor, Alternatibo sa Overleaf

Tinutulungan ng Octree ang mga researcher mula sa 15+ na unibersidad na sumulat ng research papers nang mas mabilis gamit ang AI

  • Gumawa ng magagandang TikZ diagrams gamit ang AI
  • Mag-upload ng larawan at i-convert ito sa LaTeX nang walang problema
  • Makakuha ng instant na tulong sa pagsulat at pag-format ng research papers