code: def riccati_jn(n, x):
      r"""Compute Ricatti-Bessel function of the first kind and its derivative.
  
      The Ricatti-Bessel function of the first kind is defined as :math:`x
      j_n(x)`, where :math:`j_n` is the spherical Bessel function of the first
      kind of order :math:`n`.
  
      This function computes the value and first derivative of the
      Ricatti-Bessel function for all orders up to and including `n`.
  
      Parameters
      ----------
      n : int
          Maximum order of function to compute
      x : float
          Argument at which to evaluate
  
      Returns
      -------
      jn : ndarray
          Value of j0(x), ..., jn(x)
      jnp : ndarray
          First derivative j0'(x), ..., jn'(x)
  
      Notes
      -----
      The computation is carried out via backward recurrence, using the
      relation DLMF 10.51.1 [2]_.
  
      Wrapper for a Fortran routine created by Shanjie Zhang and Jianming
      Jin [1]_.
  
      References
      ----------
      .. [1] Zhang, Shanjie and Jin, Jianming. "Computation of Special
             Functions", John Wiley and Sons, 1996.
             https://people.sc.fsu.edu/~jburkardt/f_src/special_functions/special_functions.html
      .. [2] NIST Digital Library of Mathematical Functions.
             https://dlmf.nist.gov/10.51.E1
  
      """
      if not (isscalar(n) and isscalar(x)):
          raise ValueError("arguments must be scalars.")
      n = _nonneg_int_or_fail(n, "n", strict=False)
      if n == 0:
          n1 = 1
      else:
          n1 = n
      nm, jn, jnp = specfun.rctj(n1, x)
      return jn[: (n + 1)], jnp[: (n + 1)]
  
imports: import operator
  import numpy
  import math
  from numpy import pi, asarray, floor, isscalar, iscomplex, real, imag, sqrt, where, mgrid, sin, place, issubdtype, extract, inexact, nan, zeros, sinc
  from .None import _ufuncs
  from ._ufuncs import mathieu_a, mathieu_b, iv, jv, gamma, psi, hankel1, hankel2, yv, kv, ndtri, poch, binom, hyp0f1
  from .None import specfun
  from .None import orthogonal
  from ._comb import _comb_int
label_desc: Use image node_id 19 for calling a global function with example usage: riccati_jn(n, x) and returns: jn,  jnp