-
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
[WIP] Qucs Wideband Matching tool #555
Conversation
dea3f5e
to
5a84d97
Compare
20e3cd4
to
d9127dd
Compare
.gitignore
Outdated
/qucs-core/src/parse_touchstone.hpp | ||
/qucs-core/src/parse_zvr.hpp | ||
/qucs/ar-lib | ||
/qucs/qucs-wideband-matching/CMakeCache.txt |
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.
I am not sure these CMake files should be ignored as such.
If you do out-of-tree build they should not bother you.
# | ||
# Automake input file. | ||
# | ||
# Copyright (C) 2006 Stefan Jahn <stefan@lkcc.org> |
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.
Really?
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.
lol, I have to update that stuff...
fa7f5d9
to
846e5c5
Compare
I've just rebased and pushed two commits (some UI fixes and permissions stuff) I've realized that this needs some extra work... I mean, it does the job but it may lead to a frustrating user experience... I reckon that it'd be better to leave this PR at the bottom of the list #651 or even discard it for 0.0.20 release (Notice that the milestone here is set to 0.0.21). If possible, I'll try to tweak the code a little bit so as to support 2-port matching... |
Added the two-port matching feature Here's a demo screencast: |
Any chance of this being merged soon? |
It's still WIP. I haven't worked on this for a while... |
The CMakelists file was copied from QucsAttenuator. Some fields were not properly updated, so maybe this could be the reason why Travis fails.
Travis CI cannot find "qucspowercombiningtool.h" header, so this commit is another attempt to solve the problem
-> Removed ifdefs QT_NO_DEBUG. This was initially aimed to use the qt libraries only in the user interface. -> The UI was slightly improved. -> Added a checkbox to let the user skip the local optimizer step... Sometimes the grid search is good enough... -> The GNUplot script is now automatically generated -> The size of the main window is no longer fixed
In this commit, the permissions of the folders were set to 755 whereas they were set to 644 for files
The content of .gitignore was reset to its current in develop branch
In addition to the warnings removal it was deleted a hanging ifdef QT_NO_DEBUG at io.h
It was observed that some components were to close each other so the text was not readable.
In case the user specifies a constant complex impedance, a s1p file is generated at the temp folder in order to allow S-par simulation at qucs
It was noticed that the code didn't check for strange characters at the input QLineedits. This commit solves that problem
… does) The status bar was removed and a label was added to show the status like qucs-filter does
In this commit a check was added to ensure that GNUplot is installed when the "Use GNUplot" combobox is enabled
This commit removes the option which allowed the user to select or customize the types of target network. Observation demonstrates that the "default" network set is good enough. The other options lead to kinda brute force searches and that may take hours
549dc61
to
7b8a1e0
Compare
I'm interested in this tool. Since it is not yet merged, any instructions on how to compile myself? Which repo to fetch and etc? I have to match a wideband (20 MHz wide) FM antenna with impedance varying a few hundred ohms. I guess that this tool may help? |
First you need to fetch this branch: Then, compile Qucs as usual (see qucs README.md if needed): Hope this tool fits your needs. I haven't worked on this since quite some time ago. |
Thank you. I had to do some additional steps. Here is the sequence of commands I used. I had to manually install ADMS first, so:
QUCS, since there was no package octave-epstk for ubuntu 18, I configured it with
Unfortunately the videos from your previous posts are missing. It would be nice if you upload them to youtube. Also the sample s1p files. I just installed QUCS and they will be of great help. Thanks! |
The manpages have changed since the last commit
where can i download the tool |
You would need to compile the source code. I didn't work on this again. If you want to design a broadband matching network you'd better use the Smith Chart. Try to make the Q circles as narrow as possible. Then put the network in a simulator and tune/optimize it. Check out this tool: |
I made a complete mess with the git command... This time I doing the PR to the develop branch. Sorry for the noise :S
Hello all,
This PR is a tool for designing wideband matching networks between
complex, frequency dependent impedances. It is based on the grid search
algorithm described in [1], however the implementation differs from the
original where it was found convenient.
The workflow is the following:
1 The user enters the source/load impedance data and the frequency
band where a good matching condition is required. Whenever the
impedance depends on the frequency, it must be specified using a s1p
file.
2 Search mode selection: The tool comes with a set of default circuit
candidates for the best matching network, but the user can also specify
custom topologies (L/C/TL) using a text file. The response of the
default topologies was analytically calculated beforehand, so the
execution is faster than when using an arbitrary network.
3 For every candidate topology:
3.1 The program sets a suitable starting point depending on the
impedance of the components at the mean frequency.
3.2 Grid search. A hypercube is build over the current pivot and
then every vertex is evaluated. At the end of each iteration, the
hypercube is moved to the best vertex or, otherwise, it is
shrunk/expanded. When the stop condition is met, a ‘rough’ local optimum
should be achieved.
4 Those topologies which gave a good matching condition (say <10dB)
after the grid search are chosen to refine their results with a local
optimiser. At some point, I have linked Nlopt library and tested a few
derivative free optimizers such as Subplex, Praxis and Nelder-Mead. The
Subplex method claims to outperform NM when the dimension of the problem
is high, but, in general, a matching network should be kept as simple as
possible (so typically, dimension < 6). On the other hand, the Praxis
algorithm, as a variant of the Powell’s method, relies on the assumption
that the objective function follows a quadratic expression... but I am
not pretty sure that the matching network design problem meets this
condition. Finally, the Nelder-Mead algorithm is dead simple to
implement and the results seem to be good enough… so it was the one I
have chosen.
5 At the end of the program, the best matching network is copied to
clipboard in the same way as other Qucs tools do.
In order to verify the tool is working as expected, the user/developer
can execute a command line testbench (qucs-wideband-
matching/testbench/testbench)
For sure there is plenty of room for improvement, so comments are
welcome :)
[1] Broadband direct-coupled and RF matching networks. Thomas R.
Cuthbert, 1999
[2] Convergence properties of the Nelder-Mead simplex method in low
dimensions. J.F. Lagarias, J.A. Reeds. SIAM J. OPTIM, Vol 9, No. 1, pp.
112-147