⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 errfun.m

📁 GDDEMO runs a little demonstration of gradient descent in Matlab. Launch Matlab, and type gddemo to
💻 M
字号:
function y = errfun(w1, w2)% A little error function stolen from Matlab's PEAKS function.  GDDEMO% should work with any ERRFUN that returns values in the interval [0,1].y =  3*(1-w1).^2.*exp(-(w1.^2) - (w2+1).^2) ...    - 10*(w1/5 - w1.^3 - w2.^5).*exp(-w1.^2-w2.^2) ...    - 1/3*exp(-(w1+1).^2 - w2.^2);% scale output to [0,1]y = (y + 10) / 20;

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -