【正文】
。s antiracism taskforce, is in London for the Football Association39。t charge you more than 35% of your pensation if you win the case. If you are thinking about signing up for a damagesbased agreement, you should make sure you39。t agree with the disciplinary action your employer has taken against you ? your employer dismisses you and you think that you have been dismissed unfairly. For more information about dismissal and unfair dismissal, see Dismissal. You can make a claim to an employment tribunal, even if you haven39。 end mychange=sum(new_scale1,2)。 new_scale1=new_scale。 else mut_scale(i,a)=0。 if a=0 a=1。 mut_scale=new_scale。 cross_scale(i+1,:)=[new_scale(i+1,1:a),new_scale(i,a+1:end)]。 for i=1:2:sx1 if randpc a=round(rand*sy)。 end end end end end %子函數(shù):按概率交叉 function cross_scale=my_cross(new_scale,pc) [sx,sy]=size(new_scale)。accum(i+1)=a next_scale(j,:)=new_scale(i+1,:)。 else if accum(i)aamp。 while j=sx a=rand。 [sx,sy]=size(new_scale)。 accum=my_fit/sum_of_f。 end end my_fit=my_fit39。 for i=1:length(my_f) if my_f(i)+f_min=0 my_fit(i)=0。 my_f=change_x*sin(10π *change_x)+2。 [sx,sy]=size(new_scale)。) grid on %子函數(shù):產(chǎn)生初始種群 function initscale=produscale(my_scale,gen_len) initscale=round(rand(my_scale,gen_len))。 ylabel(39。迭代次數(shù) (1)wxb39。[best_fit,best_f,best_x]=39。 best_x=best_x1(loca)。 end [best_fit,loca]=max(fitfit)。 best_x1=[best_x1,best_x]。 fitfit=[fitfit,best_fit]。 best_x=2+best_x.*4./(2^sy1)。 best_f=my_f(j)。 [sx,sy]=size(new_scale)。 %按概率交叉 mut_scale=my_mutat(cross_scale,pm)。 %計算適應(yīng)度值 next_scale=my_sellect(new_scale,my_fit)。 for i=1:M my_f=cal_my_f(new_scale)。 best_f1=[]。 %產(chǎn)生初始種群 fitfit=[]。 %交叉概率 pm=。 %基因長度 M=100。 參考文獻(xiàn): ( 1)蔡自興,徐光祐《人工智能及其應(yīng)用》 ( 2)馬永,賈俊芳 .遺傳算法研究綜述 .第 23卷 .第三期 .2021 年 12 月; 附錄: 主函數(shù) : clear clc my_scale=50。 對于任何一個具體的優(yōu)化問題,調(diào)節(jié)遺傳算法的參數(shù)可能會有利于更好的更快的收斂,這些參數(shù)包括個體數(shù)目、交叉律和變異律 。 遺傳算法在適應(yīng)度函數(shù)選擇不當(dāng)?shù)那闆r下有可能收斂于局部最優(yōu),而不能達(dá)到全局最優(yōu)。 產(chǎn)生初始種群 產(chǎn)生的方式:隨機 產(chǎn)生的結(jié)果:長度為 22 的二進(jìn)制串 產(chǎn)生的數(shù)量:種群的大?。ㄒ?guī)模),如 30, 50,… 1111010011100001011000 1100110011101010101110 1010100011110010000100 1011110010011100111001 0001100101001100000011 0000011010010000000000 ... 計算適應(yīng)度 直接用目標(biāo)函數(shù)作為適應(yīng)度函數(shù) ①解碼:將個體 s 轉(zhuǎn)化為 [1,2]區(qū)間的實數(shù): s=1000101110110101000111 → x=