命令return只是将控件返回给调用函数。
示例:
function animatebar (t0,tf,x0); disp ('Do you want to see the phase portrait?') ans = input ('Enter 1 if YES, 0 if NO'); if ans==0 % 如果输入为 0,则退出 return else plot (x,......) % 显示相位图 end
祝学习愉快!(内容编辑有误?请选中要编辑内容 -> 右键 -> 修改 -> 提交!)