code: def waist2rayleigh(w, wavelen, n=1):
      """
      Calculate the rayleigh range from the waist of a gaussian beam.
  
      See Also
      ========
  
      rayleigh2waist, BeamParameter
  
      Examples
      ========
  
      >>> from sympy.physics.optics import waist2rayleigh
      >>> from sympy import symbols
      >>> w, wavelen = symbols('w wavelen')
      >>> waist2rayleigh(w, wavelen)
      pi*w**2/wavelen
      """
      w, wavelen = map(sympify, (w, wavelen))
      return w**2 * n * pi / wavelen
  
imports: from sympy.core.expr import Expr
  from sympy.core.numbers import I, pi
  from sympy.core.sympify import sympify
  from sympy.functions.elementary.complexes import im, re
  from sympy.functions.elementary.miscellaneous import sqrt
  from sympy.functions.elementary.trigonometric import atan2
  from sympy.matrices.dense import Matrix, MutableDenseMatrix
  from sympy.polys.rationaltools import together
  from sympy.utilities.misc import filldedent
label_desc: Use image node_id 1 for calling a global function with example usage: waist2rayleigh(w, wavelen, n) and returns: unknown