The lambdify() sympy function returns a Python function that can be used to evaluate a set of expressions numerically. The arguments to lambdify() are described as follows:
- The first argument, (r, theta), is a tuple containing the symbols appearing in the expressions. These will map to the input arguments of the polar_to_rectangular() function.
- The second argument, (x,y), specifies the expressions used to define the function. These must be sympy expressions that contain only the symbols given in the first argument, namely r and theta in this example.
- The modules='numpy' argument specifies that we want to use NumPy for numerical computations.
We can now use the polar_to_rectangular() function to convert arrays containing ...