Why does my function handle change to a vector when I pass it to another function?
显示 更早的评论
I'm new to function handles and am running into an issue. I have a function f_pe(z) that describes the plasma frequency in the ionosphere as a function of height above the earth's surface, which looks like this:
fplot(f_pe, [50e3 400e3])

But, when I pass that function into another function like this:
result = @(z) PhysLib.coldPlasmaNonMagGroupIOR(f_pe(z),3e6)
f_pe turns into a 1x150 double vector, and when I plot it, it looks like this:

Why is it being converted to a 1x150 double, and why doesn't it at least have the same smooth shape as the function passed in?
采纳的回答
更多回答(0 个)
类别
在 帮助中心 和 File Exchange 中查找有关 Creating and Concatenating Matrices 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!




