Hi all, still exploring Qspice!
Made this simple model of an Xtal, simulates realistic in LT spice.
In Qspice exactly the same circuit gives me issues with Q, I use the same gmin=1e-12 as LTspice has, but I get no Q at all.
When I raise gmin setting to 1e-13…1e-14…and higher, suddenly I get the right pictures with high Q.
What is going on here? The gmin value acts almost like a switch for Q.
A value of 1e-12 should give realistic results, Im shure.
Add the attribute Rpar=0 to the inductance. I encountered this problem almost immediately after Qspice appeared. This happens because a shunt resistor is connected to each inductance. Its value is inversely proportional to inductance. At large inductance values, the resistor is small and the quality factor is low. I tried to convince the Author to correct the formula for calculating the shunt resistor, but he did not agree. So I started applying Rpar=0 and it turns off the shunt resistor!
In addition to @bordodynov, in Qspice HELP, Rpar in default equal Inductance/(1591*gmin)
The trick that Rpar=0 can force its to infinite is not mentioned in HELP but only in this forum from one of Mike’s reply.
I did try to set Gmin=1e-308 to force multiple inductors Rpar to near infinite (i.e. not need to set Rpar=0 one by one). Not the best way but without non-linear devices I may use this method.
KSKevin. Thank you. I didn’t know that the formula for calculating the shunt resistor was already corrected.
My dream has come true and I can now take spice quartz models without modification.
Be aware this new update, possibly more direct to what you are looking for in past few months.
02/16/2024 Default inductor damping is now user settable with circuit .option LFT.
In addition to this, Rpar formula is changed from
But it offer more with a .option LFT
Currently it is how its work from my testing
- If Rpar is set, Rpar =
- If no .option LFT and without Rpar, Default
Rpar = Inductance/(15.91*gmin)
- If .option LFT is set and without Rpar, Default
Rpar = 2*pi*LFT*Inductance
In short, to globally force Rpar to infinite, you no longer need to play with gmin, but can set .option LFT=1e308. I already ran basic test to verify this, possibly you may want to more test in your application.
In Help of L. Inductor
In Help of .option