code: def test_newton_does_not_modify_x0(self):
      # https://github.com/scipy/scipy/issues/9964
      x0 = np.array([0.1, 3])
      x0_copy = x0.copy()  # Copy to test for equality.
      newton(np.sin, x0, np.cos)
      assert_array_equal(x0, x0_copy)
  
imports: from __future__ import division, print_function, absolute_import
  import pytest
  from math import sqrt, exp, sin, cos
  from numpy.testing import assert_warns, assert_, assert_allclose, assert_equal, assert_array_equal
  import numpy
  from numpy import finfo, power, nan, isclose
  from scipy.optimize import zeros, newton, root_scalar
  from scipy._lib._util import getargspec_no_self
  from scipy.optimize._tstutils import get_tests, functions, fstrings
  from scipy._lib._numpy_compat import suppress_warnings
label_desc: Use image node_id 31 for calling the TestBasic obj's underlying member method code with example usage: obj.test_newton_does_not_modify_x0() without return types