function u=nn_pid(e)

global um r ym s net en1

en=(e-um)/r;
un=sim(net,[en;en1])';
en1=en;
u=ym+un*s;
