

itae_min=1e100;
kd=0

for k = 0:10:100,
    for ki = 0:10:250,
        for kd = -0.1:0.2:1,
            [t]=sim('model',[0,10]);
            
            itae=t'*abs(1-y);
            if itae_min >itae
                itae_min=itae;
                k1=k;
                ki1=ki;
                kd1=kd;
            end
        end
    end
end

disp('minimum itae kriteria')
disp(itae_min)
disp(k1)
disp(ki1)
disp(kd1)
