code: def l2_projection(f, basis, lim):
      """
      L2 projects the function f on the basis over the domain lim.
      """
      r = 0
      for b in basis:
          r += l2_inner_product(f, b, lim) * b
      return r
  
file_path: sympy/examples/advanced/gibbs_phenomenon.py
imports: from sympy import var, sqrt, integrate, conjugate, seterr, Abs, pprint, I, pi, sin, cos, sign, lambdify, Integral, S
label_desc: Use image node_id 3 for calling a global function with example usage: l2_projection(f, basis, lim) and returns: r