Why does my function handle change to a vector when I pass it to another function?
Mostra commenti meno recenti
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?
Risposta accettata
Più risposte (0)
Categorie
Scopri di più su Creating and Concatenating Matrices in Centro assistenza e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!




