code: def X_n(n, a, x):
      """
      Returns the wavefunction X_{n} for an infinite 1D box
  
      ``n``
          the "principal" quantum number. Corresponds to the number of nodes in
          the wavefunction.  n >= 0
      ``a``
          width of the well. a > 0
      ``x``
          x coordinate.
      """
      n, a, x = map(S, [n, a, x])
      C = sqrt(2 / a)
      return C * sin(pi * n * x / a)
  
imports: from sympy.core import pi
  from sympy import Integral, var, S
  from sympy.functions import sin, sqrt
label_desc: Use image node_id 1 for calling a global function with example usage: X_n(n, a, x) and returns: unknown