Typically:
- $\rm d$ denotes the total derivative (sometimes called the exact differential):$$\frac{{\rm d}}{{\rm d}t}f(x,t)=\frac{\partial f}{\partial t}+\frac{\partial f}{\partial x}\frac{{\rm d}x}{{\rm d}t}$$This is also sometimes denoted via $$\frac{Df}{Dt},\,D_tf$$
- $\partial$ represents the partial derivative (derivative of $f(x,y)$ with respect to $x$ at constant $y$). This is sometimes denoted by $$f_{,x},\,f_x,\,\partial_xf$$
- $\delta$ is for small changes of a variable, for example minimizing the action $$\delta S=0$$ For larger differences, one uses $\Delta$, e.g.: $$\Delta y=y_2-y_1$$
NB: These definitions are not necessarily uniform across all subfields of physics, so take care to note the authors intent. Some counter-examples (out of many more):
- $D$ can denote the directional derivative of a multivariate function $f$ in the direction of $\mathbf{v}$: $$D_\mathbf{v}f(\mathbf{x}) = \nabla_\mathbf{v}f(\mathbf{x}) = \mathbf{v} \cdot \frac{\partial f(\mathbf{x})}{\partial\mathbf{x}}$$
- More generally $D_tT$ can be used to denote the covariant derivative of a tensor field $T$ along a curve $\gamma(t)$: $$D_tT=\nabla_{\dot\gamma(t)}T $$
- $\delta$ can also represent the functional derivative: $$\delta F(\rho,\phi)=\int\frac{\delta F}{\delta\rho}(x)\delta\rho(x)\,dx$$
- The symbol $\mathrm{d}$ may denote the exterior derivative, which acts on differential forms; on a $p$-form, $$\mathrm{d} \omega_p = \frac{1}{p!} \partial_{[a} \omega_{a_1 \dots a_p]} \mathrm{d}x^a \wedge \mathrm{d}x^{a_1} \wedge \dots \wedge \mathrm{d}x^{a_p}$$ which maps it to a $(p+1)$-form, though combinatorial factors may vary based on convention.
- The $\delta$ symbol can also denote the inexact differential, which is found in your thermodynamics relation$${\rm d}U=\delta Q-\delta W$$ This relation shows that the change of energy $\Delta U$ is path-independent (only dependent on end points of integration) while the changes in heat and work $\Delta Q=\int\delta Q$ and $\Delta W\int\delta W$$\Delta W=\int\delta W$ are path-dependent because they are not state functions.