summaryrefslogtreecommitdiff
path: root/Engineering_Physics_by_S.L.Gupta,_Sanjeev_Gupta/Chapter11_1.ipynb
blob: a4448268a047e447330579fd24bcfb7ad326c6d5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
{
 "cells": [
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# 11: Magnetic Properties"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example number 11.1, Page number 312"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 1,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "relative permeability is 318.3\n",
      "susceptibility is 317.3\n",
      "answer in the book varies due to rounding off errors\n"
     ]
    }
   ],
   "source": [
    "#importing modules\n",
    "import math\n",
    "from __future__ import division\n",
    "\n",
    "#Variable declaration\n",
    "mew0=4*math.pi*10**-7;\n",
    "B=0.2;     #magnetic induction(web/m**2)\n",
    "H=500;        #magnetic field intensity(amp/m)\n",
    "\n",
    "#Calculation\n",
    "mewr=B/(mew0*H);      #relative permeability\n",
    "chi=mewr-1;       #susceptibility\n",
    "\n",
    "#Result\n",
    "print \"relative permeability is\",round(mewr,1)\n",
    "print \"susceptibility is\",round(chi,1)\n",
    "print \"answer in the book varies due to rounding off errors\""
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example number 11.2, Page number 312"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 2,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "relative permeability is 1.00000000948\n",
      "absolute permeability is 1.257 *10**-6\n"
     ]
    }
   ],
   "source": [
    "#importing modules\n",
    "import math\n",
    "from __future__ import division\n",
    "\n",
    "#Variable declaration\n",
    "mew0=4*math.pi*10**-7;\n",
    "chi=948*10**-11;       #susceptibility\n",
    "\n",
    "#Calculation\n",
    "mewr=1+chi;      #relative permeability\n",
    "mew=mewr*mew0;       #absolute permeability\n",
    "\n",
    "#Result\n",
    "print \"relative permeability is\",mewr\n",
    "print \"absolute permeability is\",round(mew*10**6,3),\"*10**-6\""
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example number 11.3, Page number 312"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 3,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "relative permeability is 2154\n",
      "answer in the book is wrong\n"
     ]
    }
   ],
   "source": [
    "#importing modules\n",
    "import math\n",
    "from __future__ import division\n",
    "\n",
    "#Variable declaration\n",
    "H=6.5*10**-4;      #magnetizing force(amp/m)\n",
    "M=1.4;       #magnetic field(T)\n",
    "\n",
    "#Calculation\n",
    "chi=M/H;    \n",
    "mewr=1+chi;       #relative permeability\n",
    "\n",
    "#Result\n",
    "print \"relative permeability is\",int(mewr)\n",
    "print \"answer in the book is wrong\""
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example number 11.4, Page number 312"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 4,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "relative permeability is 16\n"
     ]
    }
   ],
   "source": [
    "#importing modules\n",
    "import math\n",
    "from __future__ import division\n",
    "\n",
    "#Variable declaration\n",
    "H=220;      #magnetizing force(amp/m)\n",
    "M=3300;       #magnetic field(T)\n",
    "\n",
    "#Calculation\n",
    "chi=(M/H)+1;      #relative permeability\n",
    "\n",
    "#Result\n",
    "print \"relative permeability is\",int(chi)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example number 11.5, Page number 313"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 5,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "permeability of rod is 0.625 *10**-3 weber/amp.m\n"
     ]
    }
   ],
   "source": [
    "#importing modules\n",
    "import math\n",
    "from __future__ import division\n",
    "\n",
    "#Variable declaration\n",
    "H=1600;      #magnetizing force(amp/m)\n",
    "phi=4*10**-4;     #flux(weber)\n",
    "A=4*10**-4;     #area(m**2)\n",
    "\n",
    "#Calculation\n",
    "B=phi/A;\n",
    "mew=B/H;      #permeability of rod(weber/amp.m)\n",
    "\n",
    "#Result\n",
    "print \"permeability of rod is\",mew*10**3,\"*10**-3 weber/amp.m\""
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example number 11.6, Page number 313"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 6,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "magnetisation of material is 1.5 *10**3 A/m\n",
      "flux density is 1.259 T\n",
      "answer in the book varies due to rounding off errors\n"
     ]
    }
   ],
   "source": [
    "#importing modules\n",
    "import math\n",
    "from __future__ import division\n",
    "\n",
    "#Variable declaration\n",
    "H=10**6;      #magnetizing force(amp/m)\n",
    "mew0=4*math.pi*10**-7;\n",
    "chi=1.5*10**-3;       #susceptibility\n",
    "\n",
    "#Calculation\n",
    "M=chi*H;      #magnetisation of material(A/m)\n",
    "B=mew0*(M+H);    #flux density(T)\n",
    "\n",
    "#Result\n",
    "print \"magnetisation of material is\",M/10**3,\"*10**3 A/m\"\n",
    "print \"flux density is\",round(B,3),\"T\"\n",
    "print \"answer in the book varies due to rounding off errors\""
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example number 11.7, Page number 313"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 7,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "flux density is 2.0 *10**-2 weber/metre**2\n",
      "magnetic intensity is 32 amp-turn/metre\n",
      "permeability of ring is 6250.0 *10**-7 weber/amp-metre\n",
      "relative permeability is 497.4\n",
      "magnetic susceptibility is 496\n",
      "answer in the book is wrong\n"
     ]
    }
   ],
   "source": [
    "#importing modules\n",
    "import math\n",
    "from __future__ import division\n",
    "\n",
    "#Variable declaration\n",
    "mew0=4*math.pi*10**-7;\n",
    "phi=2*10**-6;     #flux(weber)\n",
    "A=10**-4;     #area(m**2)\n",
    "N=300;      #number of turns\n",
    "l=30*10**-2;    #length(m)\n",
    "i=0.032;     #current(ampere)\n",
    "\n",
    "#Calculation\n",
    "B=phi/A;       #flux density(weber/metre**2)\n",
    "n=N/l;\n",
    "H=n*i;        #magnetic intensity(amp-turn/metre)\n",
    "mew=B/H;      #permeability of ring(weber/amp-metre)\n",
    "mewr=mew/mew0;      #relative permeability\n",
    "chi=mewr-1;      #magnetic susceptibility\n",
    "\n",
    "#Result\n",
    "print \"flux density is\",B*10**2,\"*10**-2 weber/metre**2\"\n",
    "print \"magnetic intensity is\",int(H),\"amp-turn/metre\"\n",
    "print \"permeability of ring is\",mew*10**7,\"*10**-7 weber/amp-metre\"\n",
    "print \"relative permeability is\",round(mewr,1)\n",
    "print \"magnetic susceptibility is\",int(chi)\n",
    "print \"answer in the book is wrong\""
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example number 11.8, Page number 316"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 9,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "magnetic moment is 9.53 *10**-24 A-m**2\n",
      "answer in the book varies due to rounding off errors\n"
     ]
    }
   ],
   "source": [
    "#importing modules\n",
    "import math\n",
    "from __future__ import division\n",
    "\n",
    "#Variable declaration\n",
    "new=6.5*10**15;        #frequency(Hz)\n",
    "r=0.54*10**-10;        #radius(m)\n",
    "e=1.6*10**-19;     #charge(coulomb)\n",
    "\n",
    "#Calculation\n",
    "mew_m=e*new*math.pi*r**2;      #magnetic moment(A-m**2)\n",
    "\n",
    "#Result\n",
    "print \"magnetic moment is\",round(mew_m*10**24,2),\"*10**-24 A-m**2\"\n",
    "print \"answer in the book varies due to rounding off errors\""
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example number 11.9, Page number 317"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 10,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "bohr's magneton is 9.29 *10**-24 J/T\n"
     ]
    }
   ],
   "source": [
    "#importing modules\n",
    "import math\n",
    "from __future__ import division\n",
    "\n",
    "#Variable declaration\n",
    "e=1.6*10**-19;     #charge(coulomb)\n",
    "m=9.1*10**-31;       #mass(kg)\n",
    "h=6.64*10**-34;    #plank's constant(Js)\n",
    "\n",
    "#Calculation\n",
    "mewb=e*h/(4*math.pi*m);      #bohr's magneton(J/T)\n",
    "\n",
    "#Result\n",
    "print \"bohr's magneton is\",round(mewb*10**24,2),\"*10**-24 J/T\""
   ]
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 2",
   "language": "python",
   "name": "python2"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 2
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython2",
   "version": "2.7.11"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 0
}