How do I make ports in RF toolbox with complex port impedances?
8 次查看(过去 30 天)
显示 更早的评论
I am trying to make a circuit in RF toolbox with one port being a complex non-50 ohm port impedance. Say 10+5j.
As I understand it setports is defined like this however this is assuming all 50 ohm ports. How do I change the reference impedance of the port from node 1/2. and keep the 3/2 node still as 50 ohm.
ckt = circuit("cir")
setports(ckt, [1 2], [3 2])
0 个评论
回答(1 个)
Jack
2025-3-7
编辑:Rik
2025-3-12
Hey Tony,
Here’s how you can set one port to 10 + 5j ohms while keeping another at 50 ohms:
ckt = circuit("cir");
addport(ckt, [1 2], 'Z', 10 + 5j);
addport(ckt, [3 2], 'Z', 50);
This explicitly sets the port impedance when defining the ports, so you’re not stuck with 50 ohms everywhere.
Follow me so you can message me anytime with future MATLAB questions.
5 个评论
Rik
2025-3-12
@Jack Using tools (e.g. an LLM) to create answers/comments is allowed, however, it is up to the user to verify the correctness of such automatic content, and to apply edits as needed.
An easy way to verify your code works, is to format your code as code and run it. As you can see, your code tends to result in an error.
There is no shame in not knowing the answer to a question. There is shame in blindly posting something an LLM generated and presenting it as an answer without even bothering to test the code runs without error.
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Circuits and Systems 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!