How can I differentiate the function below (where $\beta$ and $\gamma$ are constants) with respect to $n$?

D[HermiteH[n, (Sqrt[β] Log[1 + x γ])/γ]/Sqrt[Sqrt[β]/((2^n)*(n!)*Sqrt[Pi])], n]

It seems that Mathematica cannot do it.

  • $\begingroup$ In Hermite[n,x] n is assumed to be a non negative Integer. You can not take the derivative relative to n, only relative to x and then it is: D[ Hermite[n,x],x]= 2n Hermite[n-1,x] $\endgroup$ Commented Jul 31, 2023 at 17:04
  • 1
    $\begingroup$ @DanielHuber Some of the examples in the Help demonstrate HermiteH[1/2, x]. $\endgroup$
    – Ghoster
    Commented Jul 31, 2023 at 17:16
  • $\begingroup$ @Ghoster If n is not an integer, H[n,x] is not a polynomial $\endgroup$ Commented Jul 31, 2023 at 18:30
  • 1
    $\begingroup$ I think the problem might be that you believe, incorrectly, that the derivatives of named functions can always be expressed in terms of elementary functions and special functions that have been given names. Nobody has bothered to name the derivative of $H_n(x)$ with respect to $n$. But it still exists as a legitimate function, and probably has integral representations, series representations, etc. If you try differentiating the Riemann zeta function you’ll see that it doesn't have a “simplified” form either. Mathematica just calls it Zeta’(x). $\endgroup$
    – Ghoster
    Commented Jul 31, 2023 at 23:38
  • 2
    $\begingroup$ Note that Derivative[1, 0][HermiteH][n, x] is evaluated by a numerical procedure when n or x is an approximate number. It can be evaluated to arbitrary precision. It is left unevaluated if n and x are exact numbers or symbolic expressions. Not every derivative is known in terms of other functions. Finally, it seems Mathematica does not have built-in algorithms to evaluate 2nd and higher order derivatives of HermitH[n, x] with respect to n. $\endgroup$
    – Michael E2
    Commented Jul 31, 2023 at 23:43

1 Answer 1


The derivative is an exact expression. To evaluate further, you must provide numeric input.


(* "13.3.0 for Mac OS X ARM (64-bit) (June 3, 2023)" *)


dHn[β_, γ_, n_, x_] = 
 D[HermiteH[n, (Sqrt[β] Log[1 + x γ])/γ]/
    Sqrt[Sqrt[β]/((2^n)*(n!)*Sqrt[Pi])], n] // FullSimplify

enter image description here


dHn @@ RandomInteger[{1, 5}, 4]

enter image description here

% // N

(* -16367.9 *)

dHn @@ RandomReal[1, 4]

(* -0.606802 *)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.