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
|
{
"cells": [
{
"cell_type": "markdown",
"metadata": {},
"source": [
"# Chapter 1 Passive Circuits"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Example 1.2.2, Pg.no.5"
]
},
{
"cell_type": "code",
"execution_count": 4,
"metadata": {
"collapsed": false
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"The value of resistance R is 16.61 ohm\n",
"The value of resistance R3 is 66.82 ohm\n"
]
}
],
"source": [
"import math\n",
"#given\n",
"Ro=50.0\n",
"ILdB=6.0 #T−type attenuator provide 6−dB insertion loss \n",
"#calculation\n",
"IL=10**-(ILdB/20) #Determination of R\n",
"R=Ro*(1-IL)/(1+IL)\n",
"R=round(R,2)\n",
"print 'The value of resistance R is',R,'ohm' \n",
"#Determination of R3\n",
"R3=(2*Ro*IL)/(1-(0.5)**2)\n",
"R3=round(R3,2)\n",
"print 'The value of resistance R3 is',R3,'ohm'"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Example 1.2.3,Pg.no.7"
]
},
{
"cell_type": "code",
"execution_count": 5,
"metadata": {
"collapsed": false
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"The value of resistance RA and RB is 150.5 ohm\n",
"The value of resistance RC is 37.35 ohm\n"
]
}
],
"source": [
"import math\n",
"#given\n",
"Ro=50.0\n",
"ILdB=6.0\n",
"IL=10**-(ILdB/20) #Determination of RA and RB\n",
"RA=Ro*(1+IL)/(1-IL)\n",
"RA=round(RA,1)\n",
"print 'The value of resistance RA and RB is',RA,'ohm'\n",
"#Determination of RC\n",
"RC=Ro*(1-(IL)**2)/(2*IL)\n",
"RC=round(RC,2)\n",
"print 'The value of resistance RC is',RC,'ohm'"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Example 1.2.4,Pg.no.9"
]
},
{
"cell_type": "code",
"execution_count": 7,
"metadata": {
"collapsed": false
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"The value of resistance R1 is 1.0 ohm\n",
"The value of resistance R3 is 5624.0 ohm\n",
"The value of insertion loss is 0.12 decibels\n"
]
}
],
"source": [
"import math\n",
"from math import log10\n",
"#given\n",
"Rs=75.0 #resistance\n",
"Rl=50.0 \n",
"#Determination of R1\n",
"R1=(Rs*(Rs-Rl))**(1/2)\n",
"R1=round(R1,2)\n",
"print 'The value of resistance R1 is',R1,'ohm'\n",
"#Determination of R3\n",
"R3=((Rs**2)-(R1**2))/R1\n",
"R3=round(R3,2)\n",
"print 'The value of resistance R3 is',R3,'ohm'\n",
"#Determination of insertion loss\n",
"IL=(R3*(Rs+R1))/((Rs+R1+R3)*(R3+R1)-(R3)**2)\n",
"ILdB=-20*log10(IL) #convertion of power in decibels\n",
"ILdB=round(ILdB,2)\n",
"print 'The value of insertion loss is',ILdB,'decibels'"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Example 1.2.5,Pg.no.10"
]
},
{
"cell_type": "code",
"execution_count": 8,
"metadata": {
"collapsed": false
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"The value of resistance R2 is 1.0 ohm\n",
"The value of resistance R3 is 2499.0 ohm\n",
"The value of insertion loss is 0.2 decibels\n"
]
}
],
"source": [
"from math import log10\n",
"Rs=10.0\n",
"Rl=50.0 #Determination of R2\n",
"R2=(Rl*(Rl-Rs))**(1/2)\n",
"R2=round(R2,2)\n",
"print 'The value of resistance R2 is',R2,'ohm'\n",
"#Determination of R3\n",
"R3=((Rl**2)-(R2**2))/R2\n",
"R3=round(R3,2)\n",
"print 'The value of resistance R3 is',R3,'ohm'\n",
"#Determination of insertion loss\n",
"IL=(R3*(Rs+Rl))/((Rs+R3)*(R3+R2+Rl)-(R3)**2)\n",
"ILdB=-20*log10(IL) #convertion of power in decibels\n",
"ILdB=round(ILdB,1)\n",
"print 'The value of insertion loss is',ILdB,'decibels'"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Example 1.5.1,Pg.no.21"
]
},
{
"cell_type": "code",
"execution_count": 13,
"metadata": {
"collapsed": false
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"The value of self resonant freq is 60.2 MHz\n",
"The value of Q−factor is 31.4\n",
"The value of effective inductance is -5.79846400003e-12 uH\n",
"The value of effective Q−factor is -5.41522720497e+12\n"
]
}
],
"source": [
"import math\n",
"C=7*10**-12\n",
"R=5.0\n",
"L=10**-6\n",
"f=25*10**6 \n",
"#Determination of self resonant freq of coil denoted as Fsr\n",
"Fsr=1/(2*3.14*(L*C)**0.5)\n",
"Fsr=Fsr/(10**6)\n",
"Fsr=round(Fsr,1)\n",
"print 'The value of self resonant freq is',Fsr,'MHz'\n",
"#Determination of Q−factor of coil , excluding self − capacitive effects\n",
"Q=(2*3.14*f*L)/R\n",
"print 'The value of Q−factor is',Q\n",
"#Determination of effective inductance\n",
"Leff=L/(1-(f/Fsr)**2)\n",
"Leff=Leff*(10**6)\n",
"#Leff=round(Leff,0)\n",
"print 'The value of effective inductance is',Leff,'uH'\n",
"#Determination of effective Q−factor\n",
"Qeff=Q*(1-(f/Fsr)**2)\n",
"Qeff=round(Qeff,0)\n",
"print 'The value of effective Q−factor is',Qeff"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Example 1.8.1,Pg.no.26"
]
},
{
"cell_type": "code",
"execution_count": 8,
"metadata": {
"collapsed": false
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"The value of common resonant freq is 1e-06 Mrad/sec\n",
"The transfer impedance is -6.83732235918e-05 ohm\n"
]
}
],
"source": [
"import cmath\n",
"#given\n",
"Lp=150*10**-6 #inductance\n",
"Ls=150*10**-6\n",
"Cp=470*10**-12 #capacitance\n",
"Cs=470*10**-12 #Lp=Ls=150 uH,Cp=Cs=470 pF\n",
"Q=85.0 #Q−factor for each ckt is 85\n",
"c=0.01 #Coeff of coupling is 0.01\n",
"Rl=5000.0 #Load resistance Rl=5000 ohm\n",
"r=75000.0 #Constant current source with internal resistance r=75 kohm\n",
"#calculations\n",
"#Determination of common resonant frequency\n",
"wo=1/((Lp*Cp)**(1/2))\n",
"wo=wo/(10**6)\n",
"print 'The value of common resonant freq is',wo,'Mrad/sec'\n",
"p=3.77*10**6\n",
"Z2=complex(62.9004,557.266) #Formula=Rl/(1+(p*j*Cs*Rl))\n",
"Z1=complex(4.2465,564.33) #Formula=r/(1+(p*j*Cp*r)) ;At resonance Zs=Zp=Z\n",
"z=complex(0,1)\n",
"Z=wo*Ls*(1/Q +z)\n",
"Zm=complex(0,p*c*Lp) #Determination of denominator\n",
"Dr=((Z+Z1)*(Z+Z2))-(Zm**2) \n",
"#Hence transfer impedance is given as\n",
"Zr= (Z1*Z2*Zm)/Dr\n",
"Z=Zr.real\n",
"#Z=round(Z,2)\n",
"#Zr.imag=round(Zr.imag,2)\n",
"print 'The transfer impedance is',Z,'ohm'"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Example 1.10.1,Pg.no.34"
]
},
{
"cell_type": "code",
"execution_count": 10,
"metadata": {
"collapsed": false
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"The value of common resonant freq is 169.56 Mrad/ sec\n",
"The value of Gl is 5.0 mSec\n",
"The value of alpha is 3.14\n",
"The value of effective load is 1.97 kohm\n",
"The value of tuning capacitance is 47.73 pF\n",
"The value of Rd is 1.85343097504e-05 kohm\n",
"The value of −3dB BW is 1.69 MHz\n"
]
}
],
"source": [
"import math\n",
"C1=70*10**-12\n",
"C2=150*10**-12\n",
"Rl=200.0\n",
"Q=150.0\n",
"f=27*10**6\n",
"r=40000.0\n",
"#Determination of common resonant freq\n",
"wo=2*3.14*f\n",
"wo=wo/(10**6)\n",
"print 'The value of common resonant freq is',wo,'Mrad/ sec'\n",
"#Determination of Gl\n",
"Gl=1/Rl\n",
"G1=Gl*(10**3) \n",
"print'The value of Gl is',G1,'mSec'\n",
"#Checking the approxiamtion in denominator\n",
"ap=((wo*(C1+C2))/(Gl))**2\n",
"alpha=(C1+C2)/C1\n",
"alpha=round(alpha,2)\n",
"print 'The value of alpha is',alpha\n",
"#Determination of effective load\n",
"Reff=((alpha)**2)*Rl\n",
"Reff=Reff/(10**3)\n",
"Reff=round(Reff,2)\n",
"print 'The value of effective load is',Reff,'kohm' \n",
"#If effective load is much less than internal resistance hence tuning capacitance then\n",
"Cs=C1*C2/(C1+C2)\n",
"Cs=Cs*(10**12)\n",
"Cs=round(Cs,2)\n",
"print 'The value of tuning capacitance is',Cs,'pF'\n",
"#Determination of Rd\n",
"Rd=Q/(wo*Cs)\n",
"Rd=Rd/(10**3)\n",
"print 'The value of Rd is',Rd,'kohm'\n",
"#If Rd is much greater than Reff then −3dB bandwidth is given by\n",
"B=1/(2*3.14*C2*alpha*Rl)\n",
"B=B/(10**6)\n",
"B=round(B,2)\n",
"print 'The value of −3dB BW is',B,'MHz'"
]
}
],
"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.10"
}
},
"nbformat": 4,
"nbformat_minor": 0
}
|