I've added the built-in library feature. The existing microstrip, stripline, and lumped element components now have compiled versions of themselves. Code seems to be running 30% to 35% faster depending on the run. I still need to tweak the code to make folding the primitive XML files into compiled code easier, but that's on my list. Specifically, the way I generate primitives off of a combination of existing primitives needs to be updated (following the new rules for primitive XMLs) and I need to cut out some of the redundant paths in the network diagram. There is a difference between the built-in (pre-compiled) components and the XML (compiled at run-time into byte code) components. I expected some differences in the outputs due to precision, while the same math is used the numbers are processed differently. The differences are indeed both small and not the result of a bug. The next efficiency to be had is from the port impedance transform for using non-50 ohm ports. This doesn't effect circuits that use only 50-ohm ports, but does take something like 10% to 20% of the run time for non-50 ohm runs. When the transform code was written I was just trying to get it correct and quick, so I suspect I can get it going a lot faster. Again, I don't want to fold in an existing library that makes cross-platform compiling difficult. Writing new primitive files is still fairly simple, just a few constraints have been added to make compilation possible:
|
Project blog >