-
Notifications
You must be signed in to change notification settings - Fork 213
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
New features added to Qucs-filter tool #415
Conversation
uhm, your branch has a strange history; commits
should not actually be here. Commit |
2af188e
to
81ca78b
Compare
Ok, I've just removed the "parasitic" commit and squashed the other commits. |
@andresmmera , I have tested this PR and found no problems. It's only need to add QtSvg module to CMake build system. I am planning to merge it soon. Should I rebase it for you, if you are time-constrained? |
Two bandpass filter topologies were added: the side coupled ring resonator and the capacitively coupled shunt resonators topology. In addition to this, some improvements were made concering the user interface. Specifically, it is included a preview window so as to let the user to have a quick image of how the filter will look like. Moreover, the topology combobox was shortened by including a new checkbox which allows to enable/disable the microstrip implementation. This halves the size of the aforementioned combobox. References: [1] Quarter Wavelength Side-Coupled Ring Resonator for Bandpass filters. Mohd Khairul Mohd Salleh. IEEE TRANSACTIONS ON MICROWAVE THEORY AND TECHNIQUES. VOL. 56, NO. 1, JANUARY 2008 [2] Microwave engineering. David M Pozar. John Wiley and Sons. 4th Edition. Pages 443-448 Quarter wavelength ring resonator filter It was added a Quarter wavelength ring resonator filter to the Qucs filter synthesis tool. References: [1] Quarter Wavelength Side-Coupled Ring Resonator for Bandpass filters. Mohd Khairul Mohd Salleh. IEEE TRANSACTIONS ON MICROWAVE THEORY AND TECHNIQUES. VOL. 56, NO. 1, JANUARY 2008 New filter topology + improvements 1) It was added the capacitively coupled shunt resonators synthesis 2) The Qucs-Filter interface was restructured in the sense of that every gui component is placed into a (vertical/horizontal) layout box. Moreover, it was a added a display to visualize the layout of the filter. New layout images added The aspect radio of most svg images was modified 1) It was a problem with the visualization of several images. The solution was found by changing the aspect ratio. Fixed wrong connection It was found a bug in the schematic generated by Qucs-Filter when using LC notch filters (Tee topology). The last horizontal wire on the right of the schematic was being placed wrongly when the order of the filter was an odd number. Added combobox for microstrip implementation The number of available filters is growing and the 'Realization' combobox seems to be quite saturated. In this sense, it was added a checkbox to indicate microstrip implementation. This new feature halves the number of entries... Added some comments... Updated images Disabled microstrip implementation for the new filters
*The length of the lines is converted to human-readable format using num2str() *The stubs are 90deg wrt the tranmission lines
81ca78b
to
009fc4f
Compare
Hello @ra3xdh I've just rebased this against 'develop' and I've also made some cosmetic fixes in the quarter-wave BP filter code. In this sense, I simply converted the lengths to human-readable format using num2str() and put the stub perpendicular to the transmission lines. I'm aware this should have been done already, but it was a while since the last time I've taken a look to this code. On the other hand, how can I add the QtSvg module to the cmake? |
By the way, thank you for offering yourself to do the rebase :-) |
Thank you. I will look at the newly added code tomorrow.
Add the following line:
right after the:
in |
As suggested by ra3xdh, the QtSVG is added to CMakeLists.txt In addition to this, it was found that somehow 'qw_coupled_ring_filter.h' was missing in Makefile.am
QString* QW_Coupled_Ring_Filter::createSchematic(tFilter *Filter, tSubstrate *Substrate, bool isMicrostrip) | ||
{ | ||
// Design equations | ||
double f0 = Filter->Frequency+0.5*(Filter->Frequency2-Filter->Frequency);//Central frequency |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The Frequency2
is stop frequency.
@@ -65,6 +67,7 @@ noinst_HEADERS = \ | |||
qf_filter.h \ | |||
qf_cauer.h \ | |||
quarterwave_filter.h \ | |||
qw_coupled_ring_filter.h \ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Here should be ccoupled_shunt_resonators.h
too
qucs/qucs-filter/qucsfilter.cpp
Outdated
ComboType->setEnabled(false); | ||
EditOrder->setEnabled(false); | ||
LabelStart->setText("1st transmission zero frequency:"); | ||
LabelStop->setText("Central frequency:"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should it be "Stop frequency"?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Almost right, it should be "2nd transmission zero frequency:"
I had a more detailed look in the code and noticed the following problems:
|
I also found the following undefined behavior. The steps to reproduce are following:
I think, it's need to provide some unified behavior. Sometimes the "Microstrip substrate" controls are enabled, but sometimes they are disabled. It may mislead user. |
Fully agree. Working on that |
* Added ccoupled_shunt_resonators.h to Makefile.am as suggested by ra3xdh * ccoupled_shunt_resonators.cpp, qw_coupled_ring_filter.cpp: Double format lengths converted to string using num2str() * lc_filter.cpp: The last component of a LCL filter (even order only) was not connected * qf_filter.cpp: It was the 'dBS11' and 'dBS21' variables were renamed so as to be in line with the other filter implementations *qucsfilter.cpp: As suggested by ra3xdh, the behaviour of the labels in the quarter wave side coupled resonator bandpass filter was fixed. Moreover, it was added an icon for the RFEDD based filters (which was missing before). On the other hand, the logic of the microstrip panel was fixed in order to avoid the undefined behaviour described by ra3xdh at the Github thread. Last but not least, QucsFilter::calculateFilter() was modified so as to avoid redundant error messages when even order Chebyshev filters are selected. In addition to this, the error message was changed, so far it said "Even order Chebyshev can't be realized with passive filters." Actually, it is possible to implement passive filters of even order having RS != RL
I've just pushed a commit in order to fix the issues described by @ra3xdh
@ra3xdh, sincere thanks your time and effort |
@andresmmera , Yes, I saw that you fixed QucsFilter. I will try to test your new code today and tomorrow. I am planning to merge it on Monday, if all will operate correctly. |
qucs/qucs-filter/qucsfilter.cpp
Outdated
LabelStart->setText("1st transmission zero frequency:"); | ||
LabelStop->setText("Central frequency:"); | ||
LabelStop->setText("2nd transmission zero frequency::"); | ||
} | ||
else | ||
{ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This block of code may be never reached at some conditions, because there is an another return
around line 690.
qucs/qucs-filter/qucsfilter.cpp
Outdated
LabelStart->setText("1st transmission zero frequency:"); | ||
LabelStop->setText("Central frequency:"); | ||
LabelStop->setText("2nd transmission zero frequency::"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Here is a typo. Colon is duplicated.
@andresmmera , Look at andresmmera#4 |
Improved GUI fix
@ra3xdh Thank you for the fix, I couldn't work on it... |
No further problems found. Merging this as planned. |
Some warnings remained after merging Qucs#415. In this commit, two unused variables are removed at qw_coupled_ring_filter.cpp. Moreover, the substrate parameters for the capacitively coupled shunt resonators are removed since there's no microstrip synthesis available
Hello all,
I've added two bandpass filter topologies to the Qucs filter synthesis tool: the quarter wave side coupled ring filter [1] and the capacitive coupled shunt resonators bandpass filter [2].
Unfortunately, as discussed here #394, it was not possible to automate the microstrip implementation of these filters. I'll try to work on this in the future.
Additionally, some work has been done concerning the UI. Specifically, it was added a preview window and the "Realization" combobox was shortened by adding a checkbox to enable the microstrip synthesis feature.
Regards
[1] Quarter Wavelength Side-Coupled Ring Resonator for Bandpass filters. Mohd Khairul Mohd Salleh, Gaëtan Prigent, Olivier Pigaglio, and Raymond Crampagne. IEEE TRANSACTIONS ON MICROWAVE THEORY AND TECHNIQUES. VOL. 56, NO. 1, JANUARY 2008
[2] Microwave engineering. David M Pozar. John Wiley and Sons. 4th Edition. Pages 443-448