MCPcopy Create free account
hub / github.com/TheAlgorithms/Python / eval_exponential

Function eval_exponential

fractals/julia_sets.py:40–50  ·  view source on GitHub ↗

Evaluate $e^z + c$. >>> float(eval_exponential(0, 0)) 1.0 >>> bool(abs(eval_exponential(1, np.pi*1.j)) < 1e-15) True >>> bool(abs(eval_exponential(1.j, 0)-1-1.j) < 1e-15) True

(c_parameter: complex, z_values: np.ndarray)

Source from the content-addressed store, hash-verified

38
39
40def eval_exponential(c_parameter: complex, z_values: np.ndarray) -> np.ndarray:
41 """
42 Evaluate $e^z + c$.
43 >>> float(eval_exponential(0, 0))
44 1.0
45 >>> bool(abs(eval_exponential(1, np.pi*1.j)) < 1e-15)
46 True
47 >>> bool(abs(eval_exponential(1.j, 0)-1-1.j) < 1e-15)
48 True
49 """
50 return np.exp(z_values) + c_parameter
51
52
53def eval_quadratic_polynomial(c_parameter: complex, z_values: np.ndarray) -> np.ndarray:

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected