The Designer's Guide Community Forum
https://designers-guide.org/forum/YaBB.pl Design Languages >> Verilog-AMS >> Compact model numerical precision https://designers-guide.org/forum/YaBB.pl?num=1152263028 Message started by A_Programmer on Jul 7th, 2006, 2:03am |
Title: Compact model numerical precision Post by A_Programmer on Jul 7th, 2006, 2:03am I have just implemented a compact model in Verilog A. But comparing with the original model implemented in Spice, there are some differences between their simulation results. Provided that I have eliminated all the logical errors. What are the possible sources of error? Can numberical precision harm me in this case? Thanks a lot. |
Title: Re: Compact model numerical precision Post by Geoffrey_Coram on Jul 7th, 2006, 7:23am My first guess would be that your physical constants are off. Spice uses some old values for q (electron charge) and k (Boltzmann's constant), whereas the Verilog-AMS LRM specifies values from NIST. Unfortunately, the NIST values keep changing as those darn physicists get better at measuring these things. Colin McAndrew points out that this is a *terrible* thing for compact modeling; you want to fix a value for q so that the circuit simulator matches the device parameter extraction tool. -Geoffrey |
Title: Re: Compact model numerical precision Post by A_Programmer on Jul 7th, 2006, 11:04pm Thanks a lot Geoffrey. Do you mean that I should add: `define q 1.6e-19 in my verilog code? |
Title: Re: Compact model numerical precision Post by Geoffrey_Coram on Jul 10th, 2006, 4:10am A_Programmer wrote on Jul 7th, 2006, 11:04pm:
Yikes! No, you should have a few digits more. Right now, the AMS LRM says `define P_Q 1.602176462e-19 whereas BSIM3 has hard-coded #define Charge_q 1.60219e-19 You can try that value, or you can try to find the actual value used in Spice, if you have the source code. |
The Designer's Guide Community Forum » Powered by YaBB 2.2.2! YaBB © 2000-2008. All Rights Reserved. |