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

Provide an option to disable transient model for RF port #410

Closed
1 task
3813127458 opened this issue Dec 26, 2023 · 9 comments
Closed
1 task

Provide an option to disable transient model for RF port #410

3813127458 opened this issue Dec 26, 2023 · 9 comments

Comments

@3813127458
Copy link

3813127458 commented Dec 26, 2023

It is useful to run e.g. transient simulation and S-parameter simulation on the same circuit.
This is done by connection of the S-Parameter port (=ac power source) and a voltage pulse source in series.

Spar.zip
image

Problem:

The ac power source does not represent its impedance Z0 as real resistor.
Therefore the transient simulation gives a wrong result.

TODO list:

  • Provide an option to disable transient model for 50-Ohm port.
@ra3xdh
Copy link
Owner

ra3xdh commented Dec 26, 2023

The result is not wrong. I am representing the S-par port as the sine source. The magnitude is calculated from P parameter. This is needed to simulate both transient and S-par response in one simulation without additional source connection. For example it is useful for linear amplifier analysis. The Qucsator simulation also follows such approach. This representation is needed to provide the backward compatibility between simulators. So, I cannot replace the port by 50-Ohm resistors. It is not subject of change or subject of discussion.

@3813127458
Copy link
Author

3813127458 commented Dec 27, 2023

Unfortunately the result is wrong for simultaneous S-parameter and transient simulation, because the ac source contributes to transient excitation by the ac source default parameters P=0dBm and f=1MHz.

Potential solution: create new S-parameter port, which is consistent regarding source impedance and noise, but does not contribute transient excitation. The existing ac source ensures backward compatibility.

image

@ra3xdh
Copy link
Owner

ra3xdh commented Dec 27, 2023

The simulation result is correct. Port is a sine source for transient. It provides frequency and magnitude defined as port parameters. Qucsator represents the port as the sine source for transient too. I can provide an options to disable the transient model. This will not affect the backward compatibility. The transient model will be enabled by default.

You may define ports manually using the SPICE syntax and generic voltage source that allows full SPICE string. The simulation will work. Refer to section 4.1.11 of the Ngspice manual. Use this device:

image

@ra3xdh ra3xdh added this to the 24.1.0 milestone Dec 27, 2023
@ra3xdh ra3xdh changed the title S-Parameter and Transient Simulation on Same Circuit Give Wrong Transient Results Provide an option to disable transient model for RF port Dec 27, 2023
@ra3xdh
Copy link
Owner

ra3xdh commented Dec 27, 2023

I have added TODO list and changed the issue title.

@ra3xdh ra3xdh closed this as completed in 7df0e3e Dec 27, 2023
@ra3xdh
Copy link
Owner

ra3xdh commented Dec 27, 2023

I have added an EnableTran option for RF port. This option is active by default. It EnableTran=false the transient model for RF port is disabled. The port is represented as dc 0 for transient analysis.

image

@3813127458
Copy link
Author

Excellent! - the final example RTF_N7 works perfect now simultaneous S-par and transient ... thx

RTF_N7.zip
image

@tomhajjar
Copy link

Network for a distributed amp?

@3813127458
Copy link
Author

3813127458 commented Dec 29, 2023

It is a simplified equivalent model of a lossy transmission line.

It can be used as a low pass filter which is matched in the pass band AND stop band simultaneous, which is not the case for classical low pass filters. Other application is pulse shaping in the time domain.

References:

Djordjevic et al., "On a Class of Low-Reflection Transmission-Line Quasi-Gaussian Low-Pass Filters and Their Lumped-Element Approximations" in IEEE Trans. on Microwave Theory and Techniques, vol. 51 of of 7, pp. 18711-877, July 2003.

J. Breitbarth and D. Schmelzer, "Absorptive Near-Gaussian Low Pass Filter Design with Applications in the Time and Frequency Domain", in IEEE Microwave Symposium Digest, MTT-S International, vol. 3, pp. 1303-1306, June 2004.

@tomhajjar
Copy link

tomhajjar commented Dec 29, 2023 via email

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

No branches or pull requests

3 participants