diff options
Diffstat (limited to 'Fundamental_Of_Physics_by_D_Haliday/30-Magnetic_fields_due_to_Current.ipynb')
-rw-r--r-- | Fundamental_Of_Physics_by_D_Haliday/30-Magnetic_fields_due_to_Current.ipynb | 128 |
1 files changed, 128 insertions, 0 deletions
diff --git a/Fundamental_Of_Physics_by_D_Haliday/30-Magnetic_fields_due_to_Current.ipynb b/Fundamental_Of_Physics_by_D_Haliday/30-Magnetic_fields_due_to_Current.ipynb new file mode 100644 index 0000000..ea971f3 --- /dev/null +++ b/Fundamental_Of_Physics_by_D_Haliday/30-Magnetic_fields_due_to_Current.ipynb @@ -0,0 +1,128 @@ +{ +"cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Chapter 30: Magnetic fields due to Current" + ] + }, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 30.2: Sample_Problem_2.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"exec('degree_rad.sci', -1)\n", +"\n", +"//Given that\n", +"i1 = 15 //in A\n", +"i2 = 32 //in A\n", +"d = 5.3*10^-2 //in m\n", +"uo = 4*%pi*10^-7 //in SI unit\n", +"\n", +"//Sample Problem 30-2\n", +"printf('**Sample Problem 30-2**\n')\n", +"R = d/sqrt(2)\n", +"B1 = uo*i1/(2*%pi*R)\n", +"B2 = uo*i2/(2*%pi*R)\n", +"theta = atan(B1/B2)\n", +"B = sqrt(B1^2 + B2^2)\n", +"printf('The magnitude of net magnetic field is %eT\n', B)\n", +"printf('The angle made by the net magnetic field by the positive x-axis is %fdegrees', rtod(theta)+45)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 30.3: Sample_Problem_3.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"//Given that\n", +"a = 2*10^-2 //in meter\n", +"b = 4*10^-2 //in meter\n", +"r = 3*10^-2 //in meter\n", +"c = 3*10^6 //in A/m^4\n", +"uo = 4*%pi*10^-7 //in SI unit \n", +"\n", +"//Sample Problem 30-3\n", +"printf('**Sample Problem 30-3**\n')\n", +"//Using gauss law\n", +"//B*L = uo*I\n", +"Ienc = integrate('c*x^2*2*%pi*x', 'x', a, r)\n", +"L = 2*%pi*r\n", +"B = uo*Ienc/L\n", +"printf('The magnetic field at x=r is %eT', B)" + ] + } +, +{ + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Example 30.4: Sample_Problem_4.sce" + ] + }, + { +"cell_type": "code", + "execution_count": null, + "metadata": { + "collapsed": true + }, + "outputs": [], +"source": [ +"//Given that\n", +"L = 1.23 //in meter\n", +"d = 3.55*10^-2 //in meter\n", +"i = 5.57 //in A\n", +"n = 850*5\n", +"uo = 4*%pi*10^-7 //in SI unit\n", +"\n", +"//Sample Problem 30-4\n", +"printf('**Sample Problem 30-4**\n')\n", +"B = uo*n/L*i\n", +"printf('The magnetic field inside the solenoid is %eT', B)" + ] + } +], +"metadata": { + "kernelspec": { + "display_name": "Scilab", + "language": "scilab", + "name": "scilab" + }, + "language_info": { + "file_extension": ".sce", + "help_links": [ + { + "text": "MetaKernel Magics", + "url": "https://github.com/calysto/metakernel/blob/master/metakernel/magics/README.md" + } + ], + "mimetype": "text/x-octave", + "name": "scilab", + "version": "0.7.1" + } + }, + "nbformat": 4, + "nbformat_minor": 0 +} |