Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Qucs Triangle Wave Example won't work Qucs-S #1050

Closed
tomhajjar opened this issue Nov 8, 2024 · 5 comments · Fixed by #1059
Closed

Qucs Triangle Wave Example won't work Qucs-S #1050

tomhajjar opened this issue Nov 8, 2024 · 5 comments · Fixed by #1059

Comments

@tomhajjar
Copy link

tomhajjar commented Nov 8, 2024

I have been having issues making I/V Triangle sub-circuits that work in ngspice and qucsator-rf.

  1. netlist created for "Triangle_i_tran.sch" has an extraneous "-1" that causes ngspice errors. I flipped polarity of I1 and "-1" is still there. Send netlist to DuSpice after deleting -1 and simulation runs but data is garbage. This may effect Waveform/Source Library #1046

  2. I went back to Qucs 0.0.20 and "Triangle_Wave_Generator.sch" works. Try Triangle_Wave_Generator.sch in Qucs-S, qucsator-rf and it has multiple errors. Ideal Rectangular Current Sources doesn't work in qucsator-rf

2024-11-08_124509
2024-11-08_124342
2024-11-08_124135

Waveforms_prj.zip

@ra3xdh ra3xdh linked a pull request Nov 12, 2024 that will close this issue
@ra3xdh
Copy link
Owner

ra3xdh commented Nov 12, 2024

The irect simulation error fixed by #1059. The triangle wave simulation example works on my machine.
image

@tomhajjar
Copy link
Author

Have you updated the "nightly"? The latest from 35min ago hasn't fixed issues...

@ra3xdh
Copy link
Owner

ra3xdh commented Nov 12, 2024

Everything should be updated automatically. The latest build from current branch works as expected.

@ra3xdh
Copy link
Owner

ra3xdh commented Nov 12, 2024

Use the continuous release from 18:18UTC

@tomhajjar
Copy link
Author

tomhajjar commented Nov 12, 2024

There is still 2 issues.

I created two projects, Waveforms_prj for ngspice and Waveforms_qucs_prj for qucsator-rf.

The Qucs Ideal Rectangular Current Source and Ideal Rectangular Voltage are treated differently by Qucs-S when used in ngspice versus qucsator-rf. The "re-mapping" of the Qucs source parameters to work in ngspice is VERY different BUT the mapping is logical.

However the Qucs Ideal Rectangular V/I Source parameters are misleading. The Qucs Ideal Rectangular Sources are "unique" in that TH includes Tr and TL includes Tf. In Qucs to make a Triangle, TH=Tr and TL=Tf. That is not the case when these parameters are "re-mapped" by Qucs-S to work in ngspice.

Qucsator wants TH=Tr=1ms and TL=Tf =1ms for a 2ms Triangle

ngspice wants TH=TL =1ps Tr=Tr=1ms for a 2ms Triangle

So basically old Qucs schematics using Ideal Rectangular Sources MAY need their source parameters changed when ported over to ngspice.

The last issue is sub-circuits made using the Qucs Ideal Rectangular Current Source don't work in ngspice but sub-circuits made using the Qucs Ideal Rectangular Voltage Source DO work in ngspice. Maybe it's the parameters I used in the sub-circuit or there is a bug. See "Triangle_i_sub_tran.sch". The file "Triangle_i_tran.sch" which is the same analysis without using a sub-circuit works...

As stated above, there is an "-" in the source entry 2nd position in the netlist, (V2 pulse value). What is it's purpose?

2024-11-12_195328
2024-11-12_195349

Waveforms.zip

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants