summaryrefslogtreecommitdiff
path: root/Grob's_Basic_Electronics_by_M._E._Schultz/Chapter19.ipynb
blob: 5e3f99299af02ea34cf30e3c7b2701322a06196e (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
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
{
 "cells": [
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# Chapter 19 : Inductance"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example No. 19_1 Page No.  580"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 1,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The di/dt Rate of Current change = 4 A/s\n"
     ]
    }
   ],
   "source": [
    "# The current in an inductor changes from 12 to 16 A in 1s. How much is the di/\u0002dt rate of current change in amperes per second?\n",
    "\n",
    "# Given data\n",
    "\n",
    "di = 4#     # Differential current=16-12=4 Amps\n",
    "dt = 1#     # Differential time=1 sec\n",
    "\n",
    "A = di/dt#\n",
    "print 'The di/dt Rate of Current change = %0.f A/s'%A"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example No. 19_2 Page No.  580"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 2,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The di/dt Rate of Current change = 2.50e+04 A/s\n"
     ]
    }
   ],
   "source": [
    "# The current in an inductor changes by 50 mA in 2 us. How much is the di/\u0002dt rate of current change in amperes per second?\n",
    "\n",
    "# Given data\n",
    "\n",
    "di = 50.*10**-3#    # Differential current=50 mAmps\n",
    "dt = 2.*10**-6#     # Differential time=2 usec\n",
    "\n",
    "A = di/dt#\n",
    "print 'The di/dt Rate of Current change = %0.2e A/s'%A"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example No. 19_3 Page No.  581"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 3,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The Value of Inductance = 10 Henry\n"
     ]
    }
   ],
   "source": [
    "# How much is the inductance of a coil that induces 40 V when its current changes at the rate of 4 A/\u0002s?\n",
    "\n",
    "# Given data\n",
    "\n",
    "Vl = 40#    # Induced voltage=40 Volts\n",
    "R = 4       # Current changing rate=di/dt=4 A/s\n",
    "\n",
    "L = Vl/R#\n",
    "print 'The Value of Inductance = %0.f Henry'%L"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example No. 19_4 Page No.  582"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 6,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The Value of Inductance = 4.00e-02 Henry\n",
      "OR 40 mH\n"
     ]
    }
   ],
   "source": [
    "# How much is the inductance of a coil that induces 1000 V when its current changes at the rate of 50 mA in 2\u0002us?\n",
    "\n",
    "# Given data\n",
    "\n",
    "Vl = 1000#      # Induced voltage=1000 Volts\n",
    "di = 50*10**-3#  # differential current=50 mAmps\n",
    "dt = 2*10**-6#   # differential time=2 usec\n",
    "\n",
    "A = di/dt#\n",
    "\n",
    "L = Vl/A#\n",
    "print 'The Value of Inductance = %0.2e Henry'%L\n",
    "print 'OR 40 mH'"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example No. 19_5 Page No.  582"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 7,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The Value of Self-Induced Voltage = 48 Volts\n"
     ]
    }
   ],
   "source": [
    "# How much is the self-induced voltage across a 4-H inductance produced by a current change of 12 A/\u0002s?\n",
    "\n",
    "# Given data\n",
    "\n",
    "L = 4#    # Inductor=4 H\n",
    "R = 12#   # current change=di/dt=12 A/s\n",
    "\n",
    "Vl = L*R#\n",
    "print 'The Value of Self-Induced Voltage = %0.f Volts'%Vl"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example No. 19_6 Page No.  583"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 8,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The Value of Self-Induced Voltage = 1.00e+04 Volts\n",
      "OR 10 kVolts\n"
     ]
    }
   ],
   "source": [
    "# The current through a 200-mH L changes from 0 to 100 mA in 2 u\u0002s. How much is Vl ?\n",
    "\n",
    "# Given data\n",
    "\n",
    "L = 200*10**-3#      # Inductor=200 mH\n",
    "di = 100*10**-3#     # differential current=100 mAmps\n",
    "dt = 2*10**-6#       # differectial time=2 usec\n",
    "\n",
    "A = di/dt#\n",
    "\n",
    "Vl = L*A#\n",
    "print 'The Value of Self-Induced Voltage = %0.2e Volts'%Vl\n",
    "print 'OR 10 kVolts'"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example No. 19_7 Page No.  583"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 10,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The Coefficient of Coupling k between Coil L1 and Coil L2 = 0.75\n"
     ]
    }
   ],
   "source": [
    "# A coil L1 produces 80 u\u0002Wb of magnetic flux. Of this total flux, 60 u\u0002Wb arelinked with L2. How much is k between L1 and L2?\n",
    "\n",
    "# Given data\n",
    "\n",
    "lf1 = 80.*10**-6# # Magnetic flux of coil L1=80 uWb\n",
    "lf2 = 60.*10**-6# # Magnetic flux of coil L2=60 uWb\n",
    "\n",
    "k = lf2/lf1#\n",
    "print 'The Coefficient of Coupling k between Coil L1 and Coil L2 = %0.2f'%k"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example No. 19_8 Page No.  584"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 11,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The Coefficient of Coupling k between Coil L1 and Coil L2 = 1\n"
     ]
    }
   ],
   "source": [
    "# A 10-H inductance L1 on an iron core produces 4 Wb of magnetic flux. Another coil L2 is on the same core. How much is k between L1 and L2?\n",
    "\n",
    "# Given data\n",
    "\n",
    "lf1 = 4# # Magnetic flux of coil L1=4 Wb\n",
    "lf2 = 4# # Magnetic flux of coil L2=4 Wb\n",
    "\n",
    "k = lf2/lf1#\n",
    "print 'The Coefficient of Coupling k between Coil L1 and Coil L2 = %0.f'%k"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example No. 19_9 Page No.  585"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 13,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The mutual inductance = 0.08 Henry\n",
      "i.e 80*10**-3 H OR 80 mH\n"
     ]
    }
   ],
   "source": [
    "\n",
    "from math import sqrt\n",
    "# Two 400-mH coils L1 and L2 have a coefficient of coupling k equal to 0.2. Calculate Lm.\n",
    "\n",
    "# Given data\n",
    "\n",
    "L1 = 400*10**-3# # L1=400 mH\n",
    "L2 = 400*10**-3# # L2=400 mH\n",
    "k = 0.2#        # Coupling coefficient=0.2\n",
    "\n",
    "Lm = k*sqrt(L1*L2)#\n",
    "print 'The mutual inductance = %0.2f Henry'%Lm\n",
    "print 'i.e 80*10**-3 H OR 80 mH'"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example No. 19_10 Page No.  586"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 15,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The Coupling Coefficient k = 0.10\n"
     ]
    }
   ],
   "source": [
    "from math import sqrt\n",
    "# If the two coils had a mutual inductance LM of 40 mH, how much would k be?\n",
    "\n",
    "# Given data\n",
    "\n",
    "L1 = 400.*10**-3# # Coil Inductance 1=400 mH\n",
    "L2 = 400.*10**-3# # Coil Inductance 2=400 mH\n",
    "Lm = 40.*10**-3#  # Mutual inductance=40 mH\n",
    "\n",
    "lt = sqrt(L1*L2)#\n",
    "\n",
    "k = Lm/lt#\n",
    "print'The Coupling Coefficient k = %0.2f'% k"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example No. 19_11 Page No.  590"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 21,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The Turns Ratio = 0.1667\n",
      "OR 1:6\n",
      "The Secondary Voltage = 720.00 Volts\n"
     ]
    }
   ],
   "source": [
    "# A power transformer has 100 turns for Np and 600 turns for Ns. What is the turns ratio? How much is the secondary voltage Vs if the primary voltage Vp is 120 V?\n",
    "\n",
    "# Given data\n",
    "\n",
    "np = 100.#       # Turns in primary coil=100\n",
    "ns = 600.#       # Turns in secondary coil=600\n",
    "vp = 120.#       # Primary voltage=120 Volts\n",
    "\n",
    "Tr = np/ns#\n",
    "print 'The Turns Ratio = %0.4f'%Tr\n",
    "print 'OR 1:6'\n",
    "\n",
    "vs = vp*(ns/np)#\n",
    "print 'The Secondary Voltage = %0.2f Volts'%vs"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example No. 19_12 Page No.  590"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 23,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The Turns Ratio 20:1 or 20.00\n",
      "The Secondary Voltage = 6.00 Volts\n"
     ]
    }
   ],
   "source": [
    "# A power transformer has 100 turns for Np and 5 turns for Ns. What is the turns ratio? How much is the secondary voltage Vs with a primary voltage of 120 V?\n",
    "\n",
    "# Given data\n",
    "\n",
    "np = 100.#       # Turns in primary coil=100\n",
    "ns = 5.#         # Turns in secondary coil=5\n",
    "vp = 120.#       # Primary voltage=120 Volts\n",
    "\n",
    "Tr = np/ns#\n",
    "print 'The Turns Ratio 20:1 or %0.2f'%Tr\n",
    "\n",
    "vs = vp*(ns/np)#\n",
    "print 'The Secondary Voltage = %0.2f Volts'%vs"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example No. 19_13 Page No.  591"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 24,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The Secondary Current = 0.10 Amps\n",
      "The Primary Current = 0.60 Amps\n"
     ]
    }
   ],
   "source": [
    "# A transformer with a 1:6 turns ratio has 720 V across 7200 Ohms\u0006 in the secondary. (a) How much is Is? (b) Calculate the value of Ip.\n",
    "\n",
    "# Given data\n",
    "\n",
    "vs = 720.#       # Secondary voltage=720 Volts\n",
    "Rl = 7200.#      # Secondary load=7200 Ohms\n",
    "tr = 1./6#       # Turns ratio=1:6\n",
    "\n",
    "Is = vs/Rl#\n",
    "print 'The Secondary Current = %0.2f Amps'%Is\n",
    "\n",
    "Ip = Is/tr#\n",
    "print 'The Primary Current = %0.2f Amps'%Ip"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example No. 19_14 Page No.  591"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 25,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The Secondary Current = 10.00 Amps\n",
      "The Primary Current = 0.50 Amps\n"
     ]
    }
   ],
   "source": [
    "# A transformer with a 20:1 voltage step-down ratio has 6 V across 0.6 \u0006 in the secondary. (a) How much is Is? (b) How much is Ip?\n",
    "\n",
    "# Given data\n",
    "\n",
    "vs = 6.#         # Secondary voltage=6 Volts\n",
    "Rl = 0.6#       # Secondary load=0.6 Ohms\n",
    "tr = 20./1#      # Turns ratio=20:1\n",
    "\n",
    "Is = vs/Rl#\n",
    "print 'The Secondary Current = %0.2f Amps'%Is\n",
    "\n",
    "Ip = Is/tr#\n",
    "print 'The Primary Current = %0.2f Amps'%Ip"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example No. 19_15 Page No.  593"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 26,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The Primary current = 0.42 Amps\n",
      "OR 420 mAmps\n"
     ]
    }
   ],
   "source": [
    "# Calculate the primary current I P if the secondary current Is equals its rated value of 2 A.\n",
    "\n",
    "# Given data\n",
    "\n",
    "vs = 25.2#      # Secondary voltage=25.2 Volts\n",
    "vp = 120.#       # Primary voltage=120 Volts\n",
    "Is = 2.#         # Secondary current=2 Amps\n",
    "\n",
    "Ip = Is*(vs/vp)#\n",
    "print 'The Primary current = %0.2f Amps'%Ip\n",
    "print 'OR 420 mAmps'"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example No. 19_16 Page No.  593"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 27,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Primary Impedence = 128.00 Ohms by Method 1\n",
      "Primary Impedence = 128.00 Ohms by Method 2\n"
     ]
    }
   ],
   "source": [
    "# Determine the Primary Impedence Zo\n",
    "\n",
    "# Method 1\n",
    "# Given data\n",
    "\n",
    "Vp = 32.#    # Primary Voltage = 32 Volts\n",
    "Rl = 8.#     # Load Resistance = 8 Ohms\n",
    "TR = 4.#     # Turns Ratio Np/Ns = 4/1\n",
    "\n",
    "Vs = Vp/TR#\n",
    "\n",
    "Is = Vs/Rl#\n",
    "\n",
    "Ip = ((Vs/Vp)*Is)#\n",
    "\n",
    "Zp = Vp/Ip#\n",
    "print 'Primary Impedence = %0.2f Ohms by Method 1'%Zp\n",
    "\n",
    "# Method 2\n",
    "\n",
    "Zp = TR*TR*Rl#\n",
    "print 'Primary Impedence = %0.2f Ohms by Method 2'%Zp"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example No. 19_17 Page No.  594"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 29,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The Turns ratio Np/Ns = 0.50\n",
      "OR 1/2\n",
      "The Turns ratio Np/Ns is 1.414/1 or 1.41\n"
     ]
    }
   ],
   "source": [
    "from math import sqrt\n",
    "# Calculate the turns ratio Np/Ns that will produce a reflected primary impedance Zp of (a) 75 Ohms# (b) 600 Ohms.\n",
    "\n",
    "# Given data\n",
    "\n",
    "Zs = 300.#   # Secondary impedence=300 Ohms\n",
    "Zp1 = 75.#   # Primary impedence=75 Ohms\n",
    "Zp2 = 600.#  # Primary impedence=600 Ohms\n",
    "\n",
    "tra = sqrt (Zp1/Zs)#\n",
    "print 'The Turns ratio Np/Ns = %0.2f'%tra\n",
    "print 'OR 1/2'\n",
    "\n",
    "trb = sqrt (Zp2/Zs)#\n",
    "print 'The Turns ratio Np/Ns is 1.414/1 or %0.2f'%trb"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example No. 19_18 Page No.  595"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 32,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The Total Inductance = 1.50e-02 Henry\n",
      "i.e 15 mH\n"
     ]
    }
   ],
   "source": [
    "# Inductance L1 is 5 mH and L2 is 10 mH. How much is Lt?\n",
    "\n",
    "# Given data\n",
    "\n",
    "l1 = 5*10**-3#   # Inductor 1=5 mH\n",
    "l2 = 10*10**-3#  # Inductor 2=10 mH\n",
    "\n",
    "Lt = l1+l2#\n",
    "print 'The Total Inductance = %0.2e Henry'%Lt\n",
    "print 'i.e 15 mH'"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example No. 19_19 Page No.  597"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 33,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The Equivalent Inductance = 0.04 Henry\n",
      "i.e 4 mH\n"
     ]
    }
   ],
   "source": [
    "# Inductances L1 and L2 are each 8 mH. How much is Leq?\n",
    "\n",
    "# Given data\n",
    "\n",
    "l1 = 8*10**-3#   # Inductor 1=8 mH\n",
    "l2 = 8*10**-3#   # Inductor 2=8 mH\n",
    "\n",
    "a = 1./l1#\n",
    "b = 1./l2#\n",
    "\n",
    "Leq = 10/(a+b)#\n",
    "print 'The Equivalent Inductance = %0.2f Henry'%Leq\n",
    "print 'i.e 4 mH'"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example No. 19_20 Page No.  598"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 35,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The Mutual Inductance = 2.50e-05 Henry\n",
      "i.e 25 uH\n",
      "The Coupling coefficient k = 0.10\n"
     ]
    }
   ],
   "source": [
    "from math import sqrt\n",
    "# Two series coils, each with an L of 250 u\u0002H, have a total inductance of 550 u\u0002H connected series-aiding and 450 uH series-opposing. (a) How much is the mutual inductance Lm between the two coils? (b) How much is the coupling coefficient k?\n",
    "\n",
    "# Given data\n",
    "\n",
    "l1 = 250*10**-6#     # Coil Inductance 1=250 uH\n",
    "l2 = 250*10**-6#     # Coil Inductance 2=250 uH\n",
    "Lts = 550*10**-6#    # Inductance series-aiding=550 uH\n",
    "Lto = 450*10**-6#    # Inductance series-opposing=450 uH\n",
    "\n",
    "Lm = (Lts-Lto)/4.\n",
    "print 'The Mutual Inductance = %0.2e Henry'%Lm\n",
    "print 'i.e 25 uH'\n",
    "\n",
    "lt = sqrt(l1*l2)#\n",
    "\n",
    "k = Lm/lt#\n",
    "print 'The Coupling coefficient k = %0.2f'%k"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Example No. 19_21 Page No.  608"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 36,
   "metadata": {
    "collapsed": false
   },
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "The Energy Stored in the Magnetic Field = 0.29 Joules\n"
     ]
    }
   ],
   "source": [
    "# A current of 1.2 A flows in a coil with an inductance of 0.4 H. How much energy is stored in the magnetic field?\n",
    "\n",
    "# Given data\n",
    "\n",
    "l1 = 0.4#     # Coil Inductance 1=0.4 H\n",
    "I = 1.2#      # Current=1.2 Amps\n",
    "\n",
    "E = (l1*I*I)/2#\n",
    "print 'The Energy Stored in the Magnetic Field = %0.2f Joules'%E"
   ]
  }
 ],
 "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.9"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 0
}