<jupyter_start><jupyter_text>Standart Derivatives TableThis table contains the fundamental derivatives, which need to be known so that other functions can be derived.| $f(x)$ | $\frac{df}{dx}$ ||--------|-----------------|| $k$ (constant) | $0$ || $x$ | $1$ || $x^k$ | $kx^{k-1}$ || $e^x$ | $e^x$ || $k^x$ | $k^x \ln{k}$ || $\sqrt{x}$ | $\frac{1}{2\sqrt{x}}$ || $\ln{x}$ | $\frac{1}{x}$ || $\log_k{x}$ | $\frac{1}{x\ln{k}}$ || $\sin{x}$ | $\cos{x}$ || $\cos{x}$ | $-\sin{x}$ || $\tan{x}$ | $\sec^2{x}$ || $\arcsin{x}$ | $\frac{1}{\sqrt{1-x^2}}$ || $\arccos{x}$ | $-\frac{1}{\sqrt{1-x^2}}$ || $\arctan{x}$ | $\frac{1}{1+x^2}$ || $\sinh{x}$ | $\cosh{x}$ || $\cosh{x}$ | $\sinh{x}$ || $\tanh{x}$ | $1 - \tanh^2{x}$ || $\text{arsinh}{x}$ | $\frac{1}{\sqrt{x^2+1}}$ || $\text{arcosh}{x}$ | $\frac{1}{\sqrt{x^2-1}}$ || $\text{artanh}{x}$ | $\frac{1}{1- x^2}$ |  Practice with Python Symbolic derivatives with SymPyThis practice consists of generating this same table using the symbolic mathematical package SymPy. The first step is to import the package.<jupyter_code>from sympy import *<jupyter_output><empty_output><jupyter_text>Now, let's define the variables and symbolic constants that we will use, for that we use the Symbol class.<jupyter_code>x = Symbol('x')
k = Symbol('k')<jupyter_output><empty_output><jupyter_text>Now, let's define a list of functions $f(x)$.<jupyter_code>functions = [
    k,
    x,
    x**k,
    exp(x),
    k**x,
    sqrt(x),
    ln(x),
    log(x, k),
    sin(x),
    cos(x),
    tan(x),
    asin(x),
    acos(x),
    atan(x),
    sinh(x),
    cosh(x),
    tanh(x),
    asinh(x),
    acosh(x),
    atanh(x)
]<jupyter_output><empty_output><jupyter_text>Now, let's generate a table of symbolic derivatives. To derive SymPy's symbolic expressions we use **diff**.<jupyter_code>for function in functions:
    derivative = diff(function, x)
    print(f'f(x) = {function} \t df/dx = {derivative}')<jupyter_output>f(x) = k 	 df/dx = 0
f(x) = x 	 df/dx = 1
f(x) = x**k 	 df/dx = k*x**k/x
f(x) = exp(x) 	 df/dx = exp(x)
f(x) = k**x 	 df/dx = k**x*log(k)
f(x) = sqrt(x) 	 df/dx = 1/(2*sqrt(x))
f(x) = log(x) 	 df/dx = 1/x
f(x) = log(x)/log(k) 	 df/dx = 1/(x*log(k))
f(x) = sin(x) 	 df/dx = cos(x)
f(x) = cos(x) 	 df/dx = -sin(x)
f(x) = tan(x) 	 df/dx = tan(x)**2 + 1
f(x) = asin(x) 	 df/dx = 1/sqrt(1 - x**2)
f(x) = acos(x) 	 df/dx = -1/sqrt(1 - x**2)
f(x) = atan(x) 	 df/dx = 1/(x**2 + 1)
f(x) = sinh(x) 	 df/dx = cosh(x)
f(x) = cosh(x) 	 df/dx = sinh(x)
f(x) = tanh(x) 	 df/dx = 1 - tanh(x)**2
f(x) = asinh(x) 	 df/dx = 1/sqrt(x**2 + 1)
f(x) = acosh(x) 	 df/dx = 1/sqrt(x**2 - 1)
f(x) = atanh(x) 	 df/dx = 1/(1 - x**2)
{'fraction_non_alphanumeric': 0.26896813353566007, 'fraction_numerical': 0.021244309559939303, 'mean_word_length': 3.358677685950413, 'pattern_counts': {'":': 0, '<': 16, '<?xml version=': 0, '>': 16, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '4', 'dir': 'jupyter-structured-clean-dedup', 'id': '141510', 'license': 'CC0-1.0', 'n_tokens_mistral': 1264, 'n_tokens_neox': 1201, 'n_words': 260, 'path': 'Derivatives/Std_Derivatives_Table.ipynb', 'repo_name': 'FilipeChagasDev/Calculus-for-Programmers', 'size': '2636'}