sympy.ipynb
267 lines
| 36.2 KiB
| text/plain
|
TextLexer
Brian E. Granger
|
r4634 | { | |
"nbformat": 2, | |||
Brian E. Granger
|
r4637 | "metadata": { | |
"name": "sympy" | |||
}, | |||
Brian E. Granger
|
r4634 | "worksheets": [ | |
{ | |||
"cells": [ | |||
{ | |||
"source": "<h1>SymPy: Open Source Symbolic Mathematics</h1>", | |||
"cell_type": "markdown" | |||
}, | |||
{ | |||
"cell_type": "code", | |||
"language": "python", | |||
"outputs": [], | |||
"collapsed": true, | |||
"prompt_number": 1, | |||
"input": "%load_ext sympyprinting" | |||
}, | |||
{ | |||
"cell_type": "code", | |||
"language": "python", | |||
"outputs": [], | |||
"collapsed": true, | |||
"prompt_number": 2, | |||
"input": "from __future__ import division\nfrom sympy import *\nx, y, z = symbols(\"x y z\")\nk, m, n = symbols(\"k m n\", integer=True)\nf, g, h = map(Function, 'fgh')" | |||
}, | |||
{ | |||
"source": "<h2>Elementary operations</h2>", | |||
"cell_type": "markdown" | |||
}, | |||
{ | |||
"cell_type": "code", | |||
"language": "python", | |||
"outputs": [ | |||
{ | |||
"output_type": "pyout", | |||
"latex": "$$\\frac{3}{2} \\pi + \\frac{e^{\\mathbf{\\imath} x}}{x^{2} + y}$$", | |||
"prompt_number": 3, | |||
"png": "iVBORw0KGgoAAAANSUhEUgAAAGkAAAApCAYAAAA22gdWAAAABHNCSVQICAgIfAhkiAAABGRJREFU\neJzt22uIVVUUwPHfOGmOqWmZmZpDMoYpTlohkb2TKCOll/SyLxUR1YcKen3qBUkkQRQFZRj1Iewp\n9SGo7E1PghJ7J4ZBpVlgGWY204d1Lvcacx8zc885d/T84XD2vnPOWevedfbaa6+1h4KWpy1vBYYo\nXTgGT2MiZqEHo/A33mimsH0auGY0FmNC0l+Fbc1UYggyEUvwIrrxGtZiGeblodDrOCFpL8cneSjR\nYkzDg2hP+lPwUNIe1mxhjYykd5VHznu4GWPt3aPpPLyARWIkbcVnmIMd+LaZwtrrX+JN/JK0LxS+\n99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Tf7Gy8dJkgtjcA+eL\nQKwuuezIzJGJYnPJNLFYPUVUhtcK1zMYZogtxttrXLNVJALaRartEeWkc0GLUKo2T8Hvqm/MKciJ\nu8UaDB5XLoDWZW9zd3nSJkbSAvFvMitrX15QUFBQUFBQMAD+A4Qttne0VDZpAAAAAElFTkSuQmCC\n", | |||
"text": "\u2148\u22c5x \n3\u22c5\u03c0 \u212f \n\u2500\u2500\u2500 + \u2500\u2500\u2500\u2500\u2500\u2500\n 2 2 \n x + y" | |||
} | |||
], | |||
"collapsed": false, | |||
"prompt_number": 3, | |||
"input": "Rational(3,2)*pi + exp(I*x) / (x**2 + y)\n" | |||
}, | |||
{ | |||
"cell_type": "code", | |||
"language": "python", | |||
"outputs": [ | |||
{ | |||
"output_type": "pyout", | |||
"latex": "$$-1.0$$", | |||
"prompt_number": 4, | |||
"png": "iVBORw0KGgoAAAANSUhEUgAAACsAAAASCAYAAADCKCelAAAABHNCSVQICAgIfAhkiAAAAV1JREFU\nSInt1b1LHEEYx/HP+VacTdKpKKKFXIqIIBZahBTX2Pk3pIpVIFhoMF26A8FKsLKzCqnTpxILUUjh\nW6FFbIIIuSKceBY7q8uyB9l7CSf4g+Hh+T47z/wYZmd4Qip0oOcX3KCSc14ZyzhBHRfYaq+1R5VE\nButYzTl3GlVMhrwfe/iQ/KinRYOxKlhBrcn5a/iB85DXsBv6jrbsroFK8u/sOG7xMcVfhV7vYtCu\nnW1FM+gVndWkTkN8G4NuMDsU4p8Ur4UxHINuMlvNqFXxIk66wezfEO8yav1J3g1mjxrwAor4FYO+\nRPE1tv37Q3GA9824S+kwxJcpXgxermKQNHuE+TYsnleXuMZYis+F+LDz//sYDGAigx9iMcXK+I2d\nTplZEF3kGw3q30UPwGyKvxH9+VMhH8Qx1jvg0Sfsi+7Kehg/g7mkKjjDSEaPJXzDJr7is+ixeNaz\nkroH5AA9SswlEREAAAAASUVORK5CYII=\n", | |||
"text": "-1.00000000000000" | |||
} | |||
], | |||
"collapsed": false, | |||
"prompt_number": 4, | |||
"input": "exp(I*x).subs(x,pi).evalf()\n" | |||
}, | |||
{ | |||
"cell_type": "code", | |||
"language": "python", | |||
"outputs": [], | |||
"collapsed": true, | |||
"prompt_number": 5, | |||
"input": "e = x + 2*y" | |||
}, | |||
{ | |||
"cell_type": "code", | |||
"language": "python", | |||
"outputs": [ | |||
{ | |||
"output_type": "pyout", | |||
"prompt_number": 6, | |||
"text": "Add(Symbol('x'), Mul(Integer(2), Symbol('y')))" | |||
} | |||
], | |||
"collapsed": false, | |||
"prompt_number": 6, | |||
"input": "srepr(e)" | |||
}, | |||
{ | |||
"cell_type": "code", | |||
"language": "python", | |||
"outputs": [ | |||
{ | |||
"output_type": "pyout", | |||
"latex": "$$262537412640768743.99999999999925007259719818568888$$", | |||
"prompt_number": 7, | |||
"png": "iVBORw0KGgoAAAANSUhEUgAAAfwAAAASCAYAAAC+a2xVAAAABHNCSVQICAgIfAhkiAAACXtJREFU\neJztnHms3UUVxz99r4/t0bIY34PaFoggUGvThKBIXaJEgbDEVEUCmJZqRGJUlEI0QKyIIEWhZQla\nllytKRYrFGRrJFiCuKFYLKssUoSCKFBIqyjY+seZsXPnzvx+Z353Xq6XzDe5ee/OnN85Z86cc35z\nZ4OCgoKCgoKCNzzGed+nARcA2wA7Ab8Evg68FHh2CnA28B/gZWAjsBDY1IDfemAFsAx4HjgW+IT5\nPOzQ7QvMB14H9jO05wL3OTSHA1cAa4wu/wI2O/X3AJcF2oPhPQScF6mfDKwG9o7U57afVr/JRu6z\nhtcQcBHwgkOTaheNfrsAXwEGTXsHga8Bf+lCrqa9Gj8IYQg4HdjN6PAq4nP+c4WuP+kgf87RxJaW\nLiUWcrZDa78msVqVE1P6TZNLtHJT+Gn9APLlxF7S/Q/7Ar8ApjoM1prPJI92BPgzcLD5vivwCPCl\nhvy2eJ9NwNEezT7AKmCC+T4OWA68Akx36E4N8HM/hwdbD3sYuQsCdcPAh4E/GR4h5LafVr9B4DHg\nM07ZOYitBpyyFLto9Ns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mebZDzn170V237o3fxW6/qSzyJVzQB9buWMQ8rUj1X5a\n/SxahHNiitzUXFIlN4Wf1g9y58Re0bXhg8DfgR96nx8j5/tcrECOJ9i1i3nICMg1iJbfNMRo9oKG\nAWS0vIz2DRX26ISVOYJcCPEU4bOapyEdd1KswR5mGPoLK2huNDQjgbrc9tPqtwtyzeTnnbIlwK8j\nfDR20eh3lCnbzymbjPyicYM8Ra6LWHu1fnAAsrv2NvN9ErKj/z3m+yhyMcocj3+h6086yJ9ztLGV\nOwZztiPFflr9XMRyYorc1FxSJTeFn9YPIG9O7BVd22aSl4jfJORPLe2E3Gq2P3LW9HlkDeuphvwO\nRK5i3B54Dbmj+CJk6tbFEchuRJCdq39Edq6G1skORUbDhxHecGExEVnLeQcy8tyMjJjOR34xjiCB\nNomtRzA2IMc5LkYCEfLbT6sfyCUWZyE7SUGmeb6IjKZ9aOyi1W8Gcoxu0HxeA74N/K6hXNC1V+MH\nU5FLNa4BzjBlc5ANfhOR/vwOnVOxha5/6cYi52hjK2cM5m6H1n5a/bQ5MUWuJpdo5Wr5gd4PcufE\nXtEVFBQUFBQUFBQUFBQUFBQUFBQUFBQUFPz/4789HTCrMn+NQgAAAABJRU5ErkJggg==\n", | |||
"text": "262537412640768743.99999999999925007259719818568888" | |||
} | |||
], | |||
"collapsed": false, | |||
"prompt_number": 7, | |||
"input": "exp(pi * sqrt(163)).evalf(50)" | |||
}, | |||
{ | |||
"source": "<h2>Algebra<h2>", | |||
"cell_type": "markdown" | |||
}, | |||
{ | |||
"cell_type": "code", | |||
"language": "python", | |||
"outputs": [ | |||
{ | |||
"output_type": "pyout", | |||
"latex": "$$x^{3} + 2 x^{2} y + x^{2} + x y^{2} + 2 x y + y^{2}$$", | |||
"prompt_number": 8, | |||
"png": "iVBORw0KGgoAAAANSUhEUgAAAQ0AAAAbCAYAAABm6to6AAAABHNCSVQICAgIfAhkiAAABXNJREFU\neJztnF2MXVMUx3/TMS2tVKMzhIQMM1E0SFuMqZiWeCBIU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0xh2y7t4xqndS41ZJ7lLPpbDN2Zo51J3cU1jTcKn3uA+cDdjsG40JP7\nm2jxdR7w9ATH9yBrJ5MxAnwJXAPsK52LoeezfLsKyd1rhXNDyNx3W6mMle52aR/XOH1yqaFV+5uv\nbgs9Jjmf7KGNs5HV4qyRAwW/ICPvRKIXMPGovHeCYzVuys9fx/gi1SJkAaqMtZ7lwBZkcavGEPAx\nMtctYq0b2qN9wC1OTS41tHp/0+q21GOW84XIZQt5ADsL5zqAhzTOlGRK+0uRUb+jdLyYuJh6diBv\nAtaYhrzEd5vST6awbZf20cZplUsNmdI+Rn+z1J0p7YPqro1ag8iIuQKYC1wCfF+wW0G8lWwtg8iK\n9BbgcmBl/rcW+LlgE1PPLsbf8gVZFZ+dxxSDdmkfnzibnUstsfpblbqD6q5NT3YhI+M+5BHZJcjq\n6mrgGCQ5m2ziDeIwZO7Yg9wDL3Nlvo2t5z7km2MM+a2BNcCfyMt7MWiX9vGJs9m51BCzv1Wp26zu\nbmQFtTaQdAKn0pwfPMkc7Q4BLqzzN7dgG1tPN/INU/vNgVc9fGTK+lq9fcAvTotcasgc7WL3Nyvd\nmUeZZufcnNGqA1CwErizsH8msjC20MNXu+iOFadlLjVUnXdr3Ro9VeXcnP6qA1CwG/gg/zwDuQW3\nwdNXu+iOFadlLjVUnXdr3Ro9wXWXV4MTjXkEmaP+hNy6eovwnwaYqkzVXFape6rmvHJORt5wTINu\nOFM1l1Xqnqo5TyQSiUQikUgkEv8v/gNI9gkr+UdTSgAAAABJRU5ErkJggg==\n", | |||
"text": "3 2 2 2 2\nx + 2\u22c5x \u22c5y + x + x\u22c5y + 2\u22c5x\u22c5y + y" | |||
} | |||
], | |||
"collapsed": false, | |||
"prompt_number": 8, | |||
"input": "((x+y)**2 * (x+1)).expand()" | |||
}, | |||
{ | |||
"cell_type": "code", | |||
"language": "python", | |||
"outputs": [ | |||
{ | |||
"output_type": "display_data", | |||
"latex": "$$\\frac{x \\operatorname{sin}\\left(x\\right) -1}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erY7bpwm68PIXtTXd7IE5j1ibp1e0KVpQx\n/X1qk2Xa2iN9zHZVnFAMYUeJmsqkb3tUYZ/6JB4WR3kXxRcUl8RXFddL1FUWtT1qampqamoqwv8Y\noZik/6S2SgAAAABJRU5ErkJggg==\n", | |||
"text": "x\u22c5sin(x) - 1 1\n\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 + \u2500\n x x" | |||
}, | |||
{ | |||
"output_type": "pyout", | |||
"latex": "$$\\operatorname{sin}\\left(x\\right)$$", | |||
"prompt_number": 9, | |||
"png": "iVBORw0KGgoAAAANSUhEUgAAADAAAAASCAYAAAAdZl26AAAABHNCSVQICAgIfAhkiAAAAnVJREFU\nSInt1klo11cQB/BPjKlbRaqigtFK0kQwitiIQlxA0iWCIopKL0LdwAVBiBseFA8iaA9igrbioZce\nhNBLC/WgYKHQqlFRXNBaqBsqVnDDhWj1MC/ty5+/HiSQg/lefjPz/c97M/Nmhj/vKT7HDVR1dSA9\n3tFvGM7heifG0o1udAVKitg+wjY8wBO04ZvEfYZZqMYi3Mv8GjEdt7ACMzFRzEsVluo4M4NQieNi\nFjekuyvwLR5iGUrRit/wHH++LaEeuIixSa/EPymw0dic7GewJvMbkxIYgFfYh4aM/xn7C+5anMnb\n0xlQJwpzQBT4KC4kbkOxgHPUYST+Tvp97MAJrMQeUdGxOlZzPlpQnvRLOJTxJRiS6QPwb5JrcDsL\n8gMMxPeiGD9ideJOobYwiRxjktNfaMK0jKtI3024g7KMq0zfVXiG3gXnXseWTK/HpCQPRZ+MWy/a\nt7RIfB+LQr4Vy3EtJfKqwKEEV7DzDb4t+LXA9mk6py6zLfR/yxTiF9FyxVCKrW8KvBA1otdbM1t9\nCqZavMCIjCvBXbEAcuwUSRNt9CG+wJdF7izDI6zLbH1F20r35VyHGfgOpzP9PA6KoW7H12IbXMZX\nGJ5x4zBYDF2ORfghyRvxUvTyJ8lWj7VJnpoSPJn5N6JXkqvEPBZNoEYMTDuGYDZ2ZbZyHEF/TMAf\nGTdDrLnfM1tfsRoPi5a5i6dis/UTr9aMOSmWJWIDvUj+teLFryZ9oijgf8gH5ZgYkgZMwXjsxtns\nN7ewAKMS9zjj5ort1ZLZ2lIw88R2aRIvQMzZJPGa/USxmvGTWNGT0RN7k8843BR/IrvRjc7Ca5nO\nfj0LzBdrAAAAAElFTkSuQmCC\n", | |||
"text": "sin(x)" | |||
} | |||
], | |||
"collapsed": false, | |||
"prompt_number": 9, | |||
"input": "a = 1/x + (x*sin(x) - 1)/x\ndisplay(a)\nsimplify(a)" | |||
}, | |||
{ | |||
"cell_type": "code", | |||
"language": "python", | |||
"outputs": [ | |||
{ | |||
"output_type": "pyout", | |||
"prompt_number": 10, | |||
"text": "[-2\u22c5\u2148, 2\u22c5\u2148, -2]" | |||
} | |||
], | |||
"collapsed": false, | |||
"prompt_number": 10, | |||
"input": "solve(Eq(x**3 + 2*x**2 + 4*x + 8, 0), x)" | |||
}, | |||
{ | |||
"cell_type": "code", | |||
"language": "python", | |||
"outputs": [ | |||
{ | |||
"output_type": "pyout", | |||
"latex": "$$\\sum_{n=a}^{b} \\left(2^{n} + 6 n^{2}\\right)$$", | |||
"prompt_number": 11, | |||
"png": "iVBORw0KGgoAAAANSUhEUgAAAHgAAAA5CAYAAAD9YO8bAAAABHNCSVQICAgIfAhkiAAAB5NJREFU\neJzt3HuwVXUVwPEP9wUIBghpkKXySIQIzMmgqGywxwRUNuNgQzVI00RPpbSwml6WvSxrxoiisdIa\nzXAaKpssSCIzJ3tKphWBlWERpWU+QemPtY9n3+05556z9z7AdfZ3Zs/d+3d+j3X3+j3Wb/3WOVQ8\npuktUHYWjsG9uL8ccSrKpqdA2SdjE55YkiwVhxhPwF8PthAVrSkyRZ+Gh7AFo/BAGQJVlEsRBZ+D\n/diFc5O0PxSWqOKQ4XYcndwvxeaDKEtFE/IaWU/FbqFkmIn7SpGoolTyKngmfpF6fik2Fhenomzy\nKvhG7E3uF+FBXFKKRBWlMqJA2dMw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+ynJZ8eK\n2KU9jQpWdIf0ceEig39vcjk+Jdxn1wvFzjO0gm8Xa/nxwlv1l1T91wqF3ykc7BUHkE1CCTV2i9Ok\nvKcbPWLt7RPT/dV4q+Z+6Ious1r9JIf4HswZmbROmSJmgmnCX3qWzpz4FRUVFRUVFRXDkv8DxIWR\nCnsQh3MAAAAASUVORK5CYII=\n", | |||
"text": "b \n ___ \n \\ ` \n \\ \u239b n 2\u239e\n / \u239d2 + 6\u22c5n \u23a0\n /__, \nn = a" | |||
} | |||
], | |||
"collapsed": false, | |||
"prompt_number": 11, | |||
"input": "a, b = symbols('a b')\nSum(6*n**2 + 2**n, (n, a, b))" | |||
}, | |||
{ | |||
"source": "<h2>Calculus</h2>", | |||
"cell_type": "markdown" | |||
}, | |||
{ | |||
"cell_type": "code", | |||
"language": "python", | |||
"outputs": [ | |||
{ | |||
"output_type": "pyout", | |||
"latex": "$$- \\frac{1}{6}$$", | |||
"prompt_number": 12, | |||
"png": "iVBORw0KGgoAAAANSUhEUgAAACYAAAAiCAYAAAAzrKu4AAAABHNCSVQICAgIfAhkiAAAASpJREFU\nWIXt178rRlEYwPEPXikZLH4NShTKoAyymw3KPyJlsBssVqvBYDIwCcl/gHpXr8liEYWN4bx0k3Ku\nzsmr937rDGd47vPtuc+5zz20OYN/LfCVUWxjp2xgLb3LJzOYxxCeygbnFKs31xT6ywZ3JtdJRCVW\nlrYW62iuUnRlEPlgHOtYwLBwOu9wnzFnRetRuim/4S3BM/4PxYpNYlV8FRvYSm7UpCjRg2nxYg+4\nTS1U8VtSnMqfmBP6tw97eI0Jyj0rNzGCfQxgLXO+KBZxUNgvC3Mzipyvchc3uMYYrnCeMV80dZyi\nVyjAMVZig3P2WDcu8SyMrRNsxAbnFGvgsbB/Ef7LosgpdoiJwn4YFxnzRVPDEZaEi++ZcPltGWaF\nz0TLXnwq2pN3yugjnSzSytcAAAAASUVORK5CYII=\n", | |||
"text": "-1/6" | |||
} | |||
], | |||
"collapsed": false, | |||
"prompt_number": 12, | |||
"input": "limit((sin(x)-x)/x**3, x, 0)" | |||
}, | |||
{ | |||
"cell_type": "code", | |||
"language": "python", | |||
"outputs": [ | |||
{ | |||
"output_type": "pyout", | |||
"latex": "$$1 + \\frac{1}{2} x^{2} + \\frac{5}{24} x^{4} + \\operatorname{\\mathcal{O}}\\left(x^{6}\\right)$$", | |||
"prompt_number": 13, | |||
"png": "iVBORw0KGgoAAAANSUhEUgAAANoAAAAiCAYAAAA53MevAAAABHNCSVQICAgIfAhkiAAABuNJREFU\neJzt3GusXFUVwPFfe3tbwNYA0ksrhlxrKKi0hUaD1MZQIMY3X2piaVHUooBRBPEBEnwAilHxURJ8\nVL0hxnfwEYM1Ah80YqJGgygqFgSK2iKhPiBtlbZ+WGfs6dyZuTPnOQPnn0xmzjn7nL32mr32Y+29\nDg0NDaUzq24B+mACD9UtRM0chuPxuPjP9uPOWiVqeMIwgXfih3ULMgSsxl+wXejjlHrFaRiUOXUL\n0IWn4xU4GmMV5HciXon5oiL/uII8B+V1uKVmGRZgLb5UsxxZWI1f47GM98/CM3E/9nZJM4lx/Clj\nHrWxUfmV6yRchtnCsO/FeSXnOSircaZogI6oUY7N+HKN+WdlFa7Icf/bcDZeJBqZ8S7pZuMrOLLT\nhSc75+Kp2IcdmMIlNcrTjXU4Aa/BJ2rI/+X4Vw355mUhLseHM96/FocLA7oDZ2FRl7T7xH/zTW3G\n2Bga3xPDgRaP695i1cV9+CBuww1Yg1dVmP/Rojf9VYV5FsWVQmfdhnszsQnfEMa1X/RW23qk/4UY\nOp7Tz8Pn4JMZBSuSKoaOaWbjN3hrhXn2w3Fi/tjiVtX+P+8Rutmg3qHjM/AuHIK5opffhM+JOf3c\ntvSL8HvZvetLhHGdgzNwLa7q476n4WczJRrHV5MM6qZqQ7sSH6kwv365C29MHW/DRRXlvU44AajX\n0NbjR4ksp4p6cQ2+i12ivn627Z7X4/M58jwzee4ZyfFsMb04rY97H8CKTheW4Pu4PUmUx9CK8hSe\nJ1rvKli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m5l\n6lyZOtiAb7WfTA8dFySZHoNXJ+e2iJX41g6NKskTjHlvcs+FYoPnerE3cEy0VjeKxchhpp/yZwnE\nHCXdvEkY2TuEcRDOkZ34lJib7ZrhGXvwUrHgvEH0kmXp4HCxnLChV6JDxQp4p08nz003JuVv0YsI\nxjxRvGejxZEOeLLKZFJ15c8aiDlqujlE7PFcJXvg62JRx1uUoYOFovGbRrpH2yXco3nZL//60LlC\nnvZgzEF2Yv+27fgR/buK81BV+VuBmFkWVUdNN7tFnFce/tZ2XIYO/t7tQhmBn9tEkGIeRiEYsxtV\nlH9UAzGL0E1DSQxrMGZVdCr/sARiNvTJKLzK4AqxjrKpbkFqor3860Sc1b7aJGoYmCpe5ZaH9WLY\ndK2QdRiivqukvfwL8fbk2koRo3e82MpV5K6GhicRRQZjjiKdyl90IGZDRdS9qbgbRQdjjhrdyl90\nIGZDRQzru/dfINZc0twjv4t3VOin/C9z4D0i8LWSZWpoaGhoaGhoaGhoaGhoeELwP6d5rwzGi3BH\nAAAAAElFTkSuQmCC\n", | |||
"text": "2 4 \n x 5\u22c5x \n1 + \u2500\u2500 + \u2500\u2500\u2500\u2500 + O(x**6)\n 2 24" | |||
} | |||
], | |||
"collapsed": false, | |||
"prompt_number": 13, | |||
"input": "(1/cos(x)).series(x, 0, 6)" | |||
}, | |||
{ | |||
"cell_type": "code", | |||
"language": "python", | |||
"outputs": [ | |||
{ | |||
"output_type": "pyout", | |||
"latex": "$$- 4 \\frac{x \\operatorname{sin}\\left(x^{2}\\right) \\operatorname{cos}\\left(x^{2}\\right)}{x + 1} - \\frac{\\operatorname{cos}^{2}\\left(x^{2}\\right)}{\\left(x + 1\\right)^{2}}$$", | |||
"prompt_number": 14, | |||
"png": "iVBORw0KGgoAAAANSUhEUgAAANsAAAArCAYAAADxEf1ZAAAABHNCSVQICAgIfAhkiAAABtFJREFU\neJztnHmIVVUcxz8zo/PUprFyGwfFaFEzTUpJI8NCIzGLMjXNmgqmKGmDsEJanhJhCEW20U6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De0+/mgV85tyf\nSXoeWVf33ksr8E1K5QDW2Cy1xUY0odyL7q79IOTa76B81x7k3t9CsXvvPcRnIZpvtVgySztwVQr5\nlOPej8B//s1iyRTN4UkyXb7FYrFYLBaLxWKxWKrMf2lXwftmEsr+AAAAAElFTkSuQmCC\n", | |||
"text": "2 \n \u239b 2\u239e \u239b 2\u239e \u239b 2\u239e\n 4\u22c5x\u22c5sin\u239dx \u23a0\u22c5cos\u239dx \u23a0 cos \u239dx \u23a0\n- \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 - \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n x + 1 2\n (x + 1)" | |||
} | |||
], | |||
"collapsed": false, | |||
"prompt_number": 14, | |||
"input": "diff(cos(x**2)**2 / (1+x), x)" | |||
}, | |||
{ | |||
"cell_type": "code", | |||
"language": "python", | |||
"outputs": [ | |||
{ | |||
"output_type": "pyout", | |||
"latex": "$$-2 + \\frac{1}{4} \\pi^{2}$$", | |||
"prompt_number": 15, | |||
"png": "iVBORw0KGgoAAAANSUhEUgAAAFgAAAAiCAYAAADbLB6TAAAABHNCSVQICAgIfAhkiAAAA1BJREFU\naIHt2m2oZVMYwPHfNcydmdzrZcQYV15GlDB5nabxhfjE0Agp6ZKR8UWkpPg2EspbUnzwbiRd+SgU\nX5SUuGXS5HUwKC+ZSxru0PHh2bu773Fuzt5n7bOvM+dfq73W2ns/6znPWetZz3rOYUitLGlagRoZ\nw374q2lFBo0DsA7bcVbDuti/aQVqYBP+xESfxz1CeITvip2DaOCXs2u/XMMS3CUMeyQuwVX4jME0\ncL+ZxOd4IWuvxLPYQGwCQ3rjcNxSaH8ofH9y267Dg3gK1wuf1CQ/6d8mN1qoP4y3Uw9wI7ZhbVZe\nwbc4JfVAJeingXPWCHdxQkqhx+ADER7lrMgG+kG1WDtFfP4zzk4gp1sOFhNrTWrBmzEtXESRR9HC\n+goyt+GgivpcjifwvvjAd1aUU4YVuB+HZO3zMEKaKGKZcAub8V6hf2d2XYt3S8ocNX9FlGEqK/1i\nKR7Da7LIAZfK/HAKAz+J3/BmW3++VLYnGKPfnIabsWqB+y3cIybONTg1Kznv5JWRmhRcii/wezbw\nbMn3p7BFbFT9ZhJbxYycwF6xGs/BJ9id9T2CXQ3oh4gLZ3FuxfencNh/PNOqqTxjLoZ9wNyR+0Vz\nPrZRTsYMLutBRjcGroNjxZ6S83qhXsnVFX3wibhV927jS9zX1rdSGOdavNqFjLt19nNn4iGRtCnS\nwr0iBKyDnYX6ehHLE1/2sn893QVFA3+Fx3Vv4N1t7VG8hNuE/4IDsVr4rk48h/EO/ceJpTrT1t/C\nN13q1ys34K2sPoGjhL0ayS+P4Glc1NZ/Pq6sIK8pF5FzqNigV2ftC8WXW/pkmiqbtlVEDmMiVUds\nFJuye/83bhJRUJ7b/SW7nq6BsPMKC+/If2N5BZmpZvAG1fIRn5p/AhzH9yLvW4oUM/gjbFzg3iz2\nJBijCuN4HreLY3MZNmJHof2rSAX8WFaJFAbe0aZMCvIV0Atb8HHFdzt9nq+rCFqsCfc7RDasKhfj\nDfyRRp3qLFYD9xLnrhK/Mkwn0qUnFquBe2FSxNCLgkH748nV4pfd43EGLhAHoL3qO/3tUywX4V1e\npnGdzqfFvjBoLmKPSHHO4Ghh5JPEkb0R6soHN82Y+cf2XQpJ8CFDhgwZsm/wD9hYqaXTKEKLAAAA\nAElFTkSuQmCC\n", | |||
"text": "2\n \u03c0 \n-2 + \u2500\u2500\n 4" | |||
} | |||
], | |||
"collapsed": false, | |||
"prompt_number": 15, | |||
"input": "integrate(x**2 * cos(x), (x, 0, pi/2))" | |||
}, | |||
{ | |||
"cell_type": "code", | |||
"language": "python", | |||
"outputs": [ | |||
{ | |||
"output_type": "display_data", | |||
"latex": "$$9 \\operatorname{f}\\left(x\\right) + \\frac{\\partial^{2}}{\\partial^{2} x} \\operatorname{f}\\left(x\\right) = 1$$", | |||
"png": "iVBOR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3ENM\nkcvpEIqpFGQeldQrZ43IHStRyTXIk2ojSVY6/VgYZdMpj8vMET3nKDE8zhMzio9VjyFNFr7EiuR8\nowpl0grZDLvhuuR8lf9OQqrFirbCZSob2vbJb+X0iNdLiVZJXc9Kp5lRSYCluDs53kAMvQtqtDFZ\nb8+jfgrNDGEsC6v8Xm3UWYYzq/zWLTpEu5CVToeJTOGm+2hpQytN5z9LXZsiJgK31mhjEu5IndeL\n9xwqXmffpq4di2eS43rB4SzJazNKVjqdIGKk/TG0lerHVdchbWhX4moxuylZ7IXigd+sUr9TDNvp\n3rdc9K7SH2UiHsJFSTvH4K1U+X3F2mq6/mCgtBnlLuGzzsTjGdy3U3Y6/VQkDTSdtL/zJD4UQ+MY\nXCMEvrJG/b2T77RSHvbfV9x04agux6Vi7W68eC1Pw3kiOEms7T3bwHM0g075bEZpVZ1uKlYGYGoi\nT9UlsyNxo5jGXqKyE5pmLpZUuD5db3BxhBgpb0raJ5R2i0geTAchD9EY3Q3Wq0Vem1EGi077wxy8\nUuHzsvVcny1FnZ8Xr5a8ubSJbW8nQj7NZrDpNHfm4xvRa77XG/NpB9K7nshuM0o76xSNJfKdL5ZC\nxovXyx21i7cUU4WR3STchi7hRvwqNqN80qT7trNOG6YL14scsMGaH7W+bCImRb/IZjPK/0GnBVV4\nV8TPCgaA3JcmBhEduAAHiLTtHrH2u6JWJTEb3UaEgp7Dzsm12WJELFDsgirR6K6nrYWRPSISRC8S\ngdQxin9pVVCBRnc9bZ4qc6+MouwFrcsDYmWkxHzc1882loosEuoHuv93FD5asBofJcddYoa5Tx/q\nnSB0+KUY2ZaI5IQzZBPkbRny2BA7GPlJrA/uJlYZThWzznqcLjJexog0pnEi4+UhseegoGAdGt31\nlH4rFJOrgoKCgoKCgoKCluFfJCE9lRbmMyMAAAAASUVORK5CYII=\n", | |||
"text": "2 \n d \n9\u22c5f(x) + \u2500\u2500\u2500(f(x)) = 1\n 2 \n dx" | |||
}, | |||
{ | |||
"output_type": "pyout", | |||
"latex": "$$\\operatorname{f}\\left(x\\right) = C_{1} \\operatorname{cos}\\left(3 x\\right) + C_{2} \\operatorname{sin}\\left(3 x\\right) + \\frac{1}{9}$$", | |||
"prompt_number": 16, | |||
"png": "iVBORw0KGgoAAAANSUhEUgAAAREAAAAiCAYAAAB4De05AAAABHNCSVQICAgIfAhkiAAACTtJREFU\neJztnX2QVlUdxz/Lwu7KLqkhiBi4qeSiiMwuBo2KUhZKUTrpmJpGr5htpqirFjOi+YLAaJmg0ss4\nioVmjW85jNoIUVYYNi4WiaEmDRP0bpmK1vbH99x5znOee+9z7/Pcu8/s5Xxmntnn3nvuueee37nn\n/N7us+DxeDwej8eTEZ3A+9OcMCyfdng8niHGkcAi4FFgRpoTh+fSHI/HM9R4AbgO6Ep7op9EPB4P\nwKu1nujNGY/HUxd+EvF4PHWRxJxpBc4HxgO/AH6Qa4uypQ3oAWYC3cAu4A7gGXTvC4AVjWpcDMOB\n/wIDZnsqcDpwALqH1cBva6i32dT5vwzaWCuDLZM2YAlwN/BUnXUVWS658kPgGiTcV4GRjW1OIprQ\nxPcy8G3gTGB/4N1mewES+Nca1cAYRgB9lCb4c4BbgbHmWC8abJ+roe52U3cjaJRMTkAP/ofqrKeo\ncnFZjaI0mXE0miF7UCddmWXlOTEReBzYBhwacnwYCmMNUP/AyoPr0MMV8AJwg7XdBOwEXkGDNy2n\nABfU3DqtmmlptEz2y6COIsrFphV4J7ABuAvJLJPAy1eA16itUxrBvmil24RWiChOA94ERg1Go1Jw\nBOUDsxX4B/AHp9xGtLq+rcbr3IVWv7T0AFenPGeoywSKKReXLuA85zOuzjoBeAh4MouKBonvIyFO\nrlLuMOBn+TcnNcuR9mczgfIVcDjwdzRga2U+Mh/SMhP5F9Iw1GUCxZRLZkSpKyuROnM88E/gYaSK\nrgJ+hwZFwD7AucBBwHrgQeBk4ERgO3ALckA9nX3zy5iPVrPVwJYqZd9Agzsp45C6OQF4Ea0Ybzhl\nRiD7ezbQAdxD5UPxYbRq7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EbNDtxOdGFIlWpHkdhGbdicgZ\n9lYjG7WHswSFVI812+1IU/TkSz/6QaVFyAEe5GDtqHZiUgdXUemiPDwLiuVXy0z05McCKsflgyQY\nzJ5MmQz8Gjlc32xwWzwezxBgFHpDPshM7yPhDx35/zvj8XhA+TiTUcbsJJSDE/aejsfj8USyF0oO\nHF+toMfj8Xg8Ho/H4/F4PB7Pns7/AW58iu5gsm0fAAAAAElFTkSuQmCC\n", | |||
"text": "f(x) = C\u2081\u22c5cos(3\u22c5x) + C\u2082\u22c5sin(3\u22c5x) + 1/9" | |||
} | |||
], | |||
"collapsed": false, | |||
"prompt_number": 16, | |||
"input": "eqn = Eq(Derivative(f(x),x,x) + 9*f(x), 1)\ndisplay(eqn)\ndsolve(eqn, f(x))" | |||
} | |||
] | |||
} | |||
] | |||
} |