pn junction

basic function for pn junction


Parameters

Intrinsic concentration
`n_i` \(cm^{-3}\)
P doping concentrations
`N_A` \(cm^{-3}\)
N doping concentrations
`N_D` \(cm^{-3}\)
Temperature
T \(K\)
External voltage
`V_A` \(V\)
Relative dielectric
`epsilon_r` \(1\)
Cross section area
A \(cm^2\)

Output

Thermal potential  `V_T`

`V_T={kT}/q`

Barrier voltage `V_{d}`

`V_d=V_T ln({N_A N_D}/n_i^2)`

P space charge length `d_p`

`d_p=sqrt{{2epsilonV_d}/q N_D/N_A 1/{N_A+N_D}}`

N space charge length `d_n`

`d_n*N_D=d_p*N_A`

space charge length `d_s`

`d_s=d_p+d_n`

Capacitor C

`C={epsilon A}/d_s`