# read table data
from pygmid import Lookup as lk
import numpy as np
= lk('sg13_lv_nmos.mat')
lv_nmos = lk('sg13_lv_pmos.mat')
lv_pmos # list of parameters: VGS, VDS, VSB, L, W, NFING, ID, VT, GM, GMB, GDS, CGG, CGB, CGD, CGS, CDD, CSS, STH, SFL
# if not specified, minimum L, VDS=max(vgs)/2=0.9 and VSB=0 are used
Copyright 2024 Harald Pretl
Licensed under the Apache License, Version 2.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
In [1]:
In [2]:
# define the given values
= 20e-6
id_spec = 10
gm_id_spec = 0.13 L_spec
In [3]:
# we can calculate the gm directly
= gm_id_spec * id_spec
gm print('gm =', round(gm/1e-3, 3), 'mS')
gm = 0.2 mS
In [4]:
= lv_nmos.look_upVGS(GM_ID=gm_id_spec, L=L_spec, VDS=0.75, VSB=0.0)
vgs = lv_nmos.look_upVGS(GM_ID=gm_id_spec, L=L_spec, VDS=vgs, VSB=0.0) vgs
In [5]:
# the gm_gds we look up and calculate gds from it
= lv_nmos.lookup('GM_GDS', GM_ID=gm_id_spec, L=L_spec, VDS=vgs, VSB=0)
gm_gds = gm / gm_gds
gds print('gds =', round(gds/1e-6, 2), 'uS')
gds = 10.88 uS
In [6]:
# find f_T (which is not stored directly, but we can find the gm to gate capacitance ratio)
= lv_nmos.lookup('GM_CGG', GM_ID=gm_id_spec, L=L_spec, VDS=vgs, VSB=0)
gm_cgg = gm_cgg / (2*np.pi)
f_T print('Cgg =', round(gm/gm_cgg/1e-15, 1), 'fF')
print('f_T =', round(f_T/1e9, 1), 'GHz')
Cgg = 1.4 fF
f_T = 23.0 GHz
In [7]:
# find the W of the diode transistor
= lv_nmos.lookup('ID_W', GM_ID=gm_id_spec, L=L_spec, VDS=vgs, VSB=0)
id_w = id_spec / id_w
w print('W =', round(w, 2), 'um, rounded W =', round(w*2)/2, 'um')
W = 0.86 um, rounded W = 1.0 um
In [8]:
# let's now find the other interesting values
# lookup normalized noise power spectral densisties and denormalize with the gm from above
= lv_nmos.lookup('STH_GM', VGS=vgs, L=L_spec, VDS=vgs, VSB=0)*gm
sth = lv_nmos.lookup('SFL_GM', VGS=vgs, L=L_spec, VDS=vgs, VSB=0)*gm
sfl
= sth/(4*1.38e-23*300*gm)
gamma
= sfl/sth
f_co print('V_GS =', round(float(vgs), 3), 'V')
print('gamma =', round(gamma, 2))
print('f_co =', round(f_co/1e6, 2), 'MHz')
V_GS = 0.591 V
gamma = 0.81
f_co = 15.84 MHz