code: def test_invalid_coordinates():
      # Simple pendulum, but use symbol instead of dynamicsymbol
      l, m, g = symbols("l m g")
      q = symbols("q")  # Generalized coordinate
      N, O = ReferenceFrame("N"), Point("O")
      O.set_vel(N, 0)
      P = Particle("P", Point("P"), m)
      P.point.set_pos(O, l * (sin(q) * N.x - cos(q) * N.y))
      P.potential_energy = m * g * P.point.pos_from(O).dot(N.y)
      L = Lagrangian(N, P)
      raises(ValueError, lambda: LagrangesMethod(L, [q], bodies=P))
  
file_path: sympy/sympy/physics/mechanics/tests/test_lagrange.py
imports: from sympy.physics.mechanics import dynamicsymbols, ReferenceFrame, Point, RigidBody, LagrangesMethod, Particle, inertia, Lagrangian
  from sympy.core.function import Derivative, Function
  from sympy.core.numbers import pi
  from sympy.core.symbol import symbols
  from sympy.functions.elementary.trigonometric import cos, sin, tan
  from sympy.matrices.dense import Matrix
  from sympy.simplify.simplify import simplify
  from sympy.testing.pytest import raises
label_desc: Use image node_id 1 for calling a global function with example usage: test_invalid_coordinates() without return types