function [ sum_insulin ] = create_insulin( dt, lengTime, num, type, Egyseg, insulin_start )

sum_insulin=zeros(1, lengTime);

for i=1:num
insulin=zeros(1, lengTime);
func_insulin = select_insulin( type(i), Egyseg(i), dt );

start=(insulin_start(i)/dt);
insulin( start : (start-1)+(length(func_insulin)) )=func_insulin;

sum_insulin = sum_insulin(1:lengTime) + insulin(1:lengTime);

end


end

