Assignment title: Information
Carleton University DoE Instructor: Professor Michel Nakhla
ELEC5508 / ELG6358
Computer Methods for Analysis and Design of VLSI Circuits
Fall-2016
Assignment-2
Date: Thur., Nov. 03rd, 2016
• For each question, attach Matlab code and (H-)spice netlist that you used (if any).
• For questions marked with the symbol:
::::
, you should include the simulation results (such as graphs,...) in your report, 2
::::
- , you should provide a written answer. It must be typed. A scan of handwriting is not accepted.
Question 1:
(A) Write a computer program to formulate the frequency domain MNA sparse equations in the form
(G + sC) X = b according to the following specifications.
Specifications:
INPUT: Your program should be able to input netlist-data. This netlist can
be either in a SPICE-like format (e.g. 'R1 1 2 10000') or equivalent
(e.g. 'res(1 2 10000);').
Components: Your program should be able to stamp all these components:
(1) Resistors (res),
(2) Capacitors (cap),
(3) Inductors (ind),
(4) Voltage sources (vol),
(5) Current sources (cur),
(6) Voltage-controlled voltage sources (vcvs),
(7) Voltage-controlled current sources (vccs).
OUTPUT: Frequency response (magnitude and phase)
(B) Verify manually the correctness of your formulation using simple circuits. You can use any
simple circuit(s) of your choice for this purpose. Include these circuits and associated code in
your report. ::::2 :::: - (Type!)
(C) Use the program in part A and the sparse commands in MATLAB to develop a program to
compute the frequency response of a general linear circuit.
(D) Find the frequency responses of the sample circuits in step B, for the adequate frequency ranges
of your interest. ::::2
(E) Verify your results using HSPICE (or equivalent). ::::2ELEC5508-2016F Assignment-2 2 / 4
Question 2:
(A) For the circuit in Figure-1, use your program to plot the frequency response of the circuit in the
frequency range 1Hz ≤ f ≤ 20MHz, using log-log scale for the magnitude plot. ::::2
(B) Plot the magnitude of the input impedance of the circuit in Figure-1, in the frequency range
0Hz ≤ f ≤ 30MHz. ::::2
(C) For the circuit in Figure-2, plot the frequency response of the circuits in the frequency range
1Hz ≤ f ≤ 4kHz, using log-log scale for the magnitude plot. Use the Voltage-Controlled
Voltage Source (VCVS) model for the OpAmps as shown in Figure-3. ::::2
(D) Verify your results for the above items (A, B, and C) using HSPICE (or equivalent). ::::2
(E) For the both circuits in Figure-1 and Figure-2,
(I) Plot the sparsity pattern of the MNA matrix A = (G + j C) before the LU decomposition.
Find the sparsity (%) of A. ::::2
(II) Plot the sparsity pattern of the the LU factors of the MNA matrix after the LU decomposition.
Find the sparsity (%) of the LU factorization (L + U). ::::2
Rs L
Vin C
R
C
R L
C
R L
C
R L
C RL
R L
C RL
Vout
R L
C
R L
C RL
All capacitor values: 1 ,
All inductor values : 1 ,
All internal resistor values: 1 ,
All source/load resistor values: 50 ,
Voltage Source : 1 .
= =
= Ω
= = Ω
C L =
R
R R
S L
V
in
nF
H
V
µ
Figure 1: RLC Ladder Network.ELEC5508-2016F Assignment-2 3 / 4
- +
R3
R2
C1
C2
R1
Vin
~
- +
R4
R5
C3
- +
R7
C4
- +
R8
R9
R6
Vout
A1
A2
A3
A4
Capacitors: 94.9 , 20.5 , 15
1 2 3 4
Resistors: 9,606 , 23,280 , 6.8 , 9,304 ,
1 2 3 4
52,107 , 9,304 , 20
5 7 6 8 9
Gain of Op-Amps: 50,000
1 2 3 4
Voltage Source : 1
= = = =
= Ω = Ω = Ω = Ω
= Ω = = Ω = = Ω
= = = =
=
A A A A
C nF C nF C C nF
R R R k R
R R R R R k
V V
in
Figure 2: OpAmp-Ladder.
+_
+ V _
in
Avin
Figure 3: OpAmp VCVS Model.
Question 3:
(A) Using the op-amp model defined as the sub-circuit shown in Figure-5, plot the frequency response
of the active-filter circuit in Figure-4, in the frequency range 1Hz ≤ f ≤ 25KHz. Use the
linear scale for the magnitude plot. ::::2
(B) Verify your results using HSPICE (or equivalent). ::::2
(C) For this circuit,
(I) Plot the sparsity pattern of the MNA matrix before the LU decomposition and find the sparsity
(%) of A.
::::
2
(II) Plot the sparsity pattern of the the LU factors of the MNA matrix after the LU decomposition
and find the sparsity (%) of the LU factorization. ::::2ELEC5508-2016F Assignment-2 4 / 4
A1
+ _
C1=2.43nF R2=10k
R1=10k R3=10k R4=10k
R7= C3=1.6nF
10k
R9=10k R8=10k
R5=
14k
C2=2.43nF
R11=10k
R12=10k
Vi=1V _ +
A2
_ +
A3
R6=10k
_ +
A4
A5
+ _
R10=55.6k C4=
1.6nF
_ +
A6
C5=5.5nF
A7
_ +
+ v _
out
Figure 4: Chebyshev active filter.
R
p
C
p
Ro
+_
+_
Rin
+ _
Avin
+ _
Vin +
_
v
p Kvp
10
1 1 591 100 000
75 1
= Ω
= Ω = µ =
= Ω =
in
p P
o
R M ,
R k , C . F, A ,
R , K
Subcircuit: OpAmp
Figure 5: OpAmp Model.