About sub function............
7 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
How ı can write a function and sub function.
Can you give me an example ?
0 Kommentare
Antworten (2)
David Hill
am 6 Jun. 2020
function out=showMe(in)
n=1;
out=executeSub();
function o=executeSub()%I assume you are talking about a nested function
o=5*n;
end
end
Look at matlab help: Nested Functions
1 Kommentar
David Hill
am 6 Jun. 2020
function Soru6
aci=input('Lütfen açıyı giriniz : ');
F=input('Lütfen kuvveti giriniz : ');
mesnet
function mesnet
y=aci*F
fprintf('%g',y);
end
end
Works just fine but you still need to execute it.
Soru6;
4 Kommentare
Siehe auch
Kategorien
Mehr zu Environment and Settings finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!