EveryCircuit
Contact
Reviews
Home
jason9
modified 3 years ago

MOSFET equations

18
12
631
04:49:49
I’ve always wanted to reverse engineer the formulas that EC uses to simulate MOSFETs but I never did manage to do it until now. So, I’m posting my results here in this save which contains all the equations that EC uses to simulate a MOSFET. Also note that all the explanations and equations below are for N-type MOSFETs. P-type MOSFETs are exactly the same except all the voltages and currents are reversed, so N- and P-type MOSFETs have the same relationship to each other as NPN and PNP bipolar transistors (BJTs). First, some terminology. MOSFETs have a drain, gate, and source, which roughly correspond to the collector, base, and emitter of a bipolar transistor. However, unlike a bipolar transistor, EC MOSFETs are symmetrical. That is to say, EC makes no distinction between drain and source. The drain is simply whichever of the two terminals is at a higher voltage and the source is the other terminal. This means that you can flip all the MOSFETs on every circuit you have ever made and EC will simulate them identically. This is not how they work in real life and doing so on real circuits will cause the circuits to fail because of the internal body diode that EC doesn’t simulate. This body diode is a consequence of how the MOSFETs are constructed and is effectively a diode between the source and drain and allows current to flow from the source to the drain if the source is at a higher voltage than the drain (although as per usual for a diode it does need at least 0.7V or so to start conducting). Now it’s time for some math. First I need to define the variables. The voltages at the drain, gate, and source are D, G, and S respectively. Length, Width, KP, VTO, and Lambda are the parameters of the MOSFET. These are the variables I’ll be using in the equations: V = D - S (this is the drain to source voltage. Also note that because of the way drain and source are defined this number is never negative) Vg = G - S - VTO (this is how many volts the gate is above the activation voltage) K = Width / Length * KP / 2 (I call this the transconductance) L = Lambda Now for the equations. When V < Vg the current is defined by this equation: -K*L*(V^3) + K*(2*L*Vg - 1)*(V^2) + 2*K*Vg*V And when V > Vg the current is defined by this equation: K*(Vg^2)*(L*V + 1) When V = Vg then both equations give the same result. When Lambda is zero and V > Vg then the current is simply: K*(Vg^2) In this case the current does not depend on V. In reality the current does in fact depend on V even when V > Vg so no real MOSFET has a Lambda of 0. When V << Vg (V is much less than Vg) then the MOSFET can be treated like a resistor. The resistance is determined by this formula: 1/(2*K*Vg) So if the K is 295μA/V^2 (assuming a width of 1μm, a length of 200nm, and a KP of 118μA/V^2) and Vg is 1V (which would correspond to a gate to drain voltage of 1.43V assuming a VTO of 430mV) then the effective resistance for very small values of V would be about 1.7kΩ (actually 1.695kΩ to be a bit more precise). A Desmos graph of these equations can be found here: https://www.desmos.com/calculator/4nk4x8fllg
published 3 years ago
zorgrian
3 years ago
Awesome thanks. This is both clear and free from pesky city insects
zorgrian
3 years ago
Over the years, several rather large buzzing hives of Twin City insects have grown themselves into overinflated tiresome incorrect piffle
zorgrian
3 years ago
So far as I have calculated, your buzz free clear formulae are indeed correct and have no assumptions nor school master overtone series. Speaking of which, the model does look more useful as a switch (square wave odd harmonic) than a linear device. I feel there is a parameter missing within the model. Certainly, jfets do not work properly as normally the gate must be negative and this does not compute in EC
jason9
3 years ago
Well, my model only covers EC MOSFETs. Depletion mode MOSFETs, JFETs, etc. aren’t included in the model. My model is strictly a reverse engineering of the EC MOSFET, so any quirks and incorrect behaviors that the EC MOSFET has have been carried through into my model.
zorgrian
3 years ago
It was no criticism of you. The main thing is it's clear 🙂 and 🐝 buzzing piles of city crapped out clapped out stench are nowhere near your EC MOSFET calculated model.
zorgrian
3 years ago
What I meant was that EC needs at least another parameter to make a functional jfet. And that the annoying twin buzzing around, is reduced to a distant memory
jason9
3 years ago
I see
zorgrian
3 years ago
I'm surprised that the buzz free equations have not yet drawn massive attention from the twin hive urban professor
zorgrian
3 years ago
J9 do you still maintain your age to be 9 ish?
jason9
3 years ago
What, no lol of course not. I was born in 2005, so I was probably around 9 when I first got the app but it’s 2022 now so I’m almost 17. I just put a 9 at the end of my username since that’s one of the strategies I used to use for making my username unique (just add 9’s until it’s no longer taken). It had no relationship to my age.
jason9
3 years ago
Also why comment on this circuit and not one of my more recent ones? Your lucky I scrolled down here at all. Usually a comment like this would go unnoticed for months or years.
Redstone_guy
3 months ago
For the Desmos graph, a nice tip I have is axis labeling. For example, am I correct in assuming the x-axis represents the voltage?

EveryCircuit is an easy to use, highly interactive circuit simulator and schematic capture tool. Real-time circuit simulation, interactivity, and dynamic visualization make it a must have application for professionals and academia. EveryCircuit user community has collaboratively created the largest searchable library of circuit designs. EveryCircuit app runs online in popular browsers and on mobile phones and tablets, enabling you to capture design ideas and learn electronics on the go.

Copyright © 2025 by MuseMaze, Inc.     Terms of use     Privacy policy