Getting a single solution, but expecting an array

Total newbie, here is my relevant code:
s=0.001:0.10:1.001;
Z_in = (r_s + j*L_ls) + (j*L_m*(r_r./s + j*L_lr))/(j*L_m + r_r./s + j*L_lr)
All variables are entered as single values except for s, which varies as shown. I am only getting a single solution for Z_in, but I'm expecting a range of values. What am I missing here? I deleted the last expression in parentheses just to see what would happen, and I get an array solution. But as shown, Matlab returns just a single value.

 Akzeptierte Antwort

Star Strider
Star Strider am 25 Mär. 2021
Missed one element-wise division:
Z_in = (r_s + j*L_ls) + (j*L_m*(r_r./s + j*L_lr))./(j*L_m + r_r./s + j*L_lr)
↑ ← HERE
.

Weitere Antworten (0)

Tags

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by