|
Q1.
' E8 j V7 Y. t7 T4 K我的疑问是第四章中,用来做进行适应度评估的Function函数
. O5 `+ X$ g3 o; c* o其中,事先给出的工位指数(StationIndex)=sum(cycleTime-stationTime)/(number of Stations) `+ A8 H3 I# f" c: ^
但是在function函数中,书中给出了9 u5 c/ L9 P% p6 O. l6 L
for i:=1 to Stations loop
" M' T! Z& J+ n$ ^mu:=cycletime-procstation[2,i];- -cycletime减去一个工作站中作业任务总时间;5 F% @4 ~( S# q. O, P' G* m
stationIndex:=StationIndex+Mu;--这个也能理解
, ~: c+ M. n/ v0 p+ Isigma:=Mu*Mu;--这个用来求平衡指数的,也能理解
- \1 o* l# J3 \StationIndex:=stationIndex+Mu;--这里就不是很清楚了,为什么又要加上这一句呢?这个不会跟上面那句重复了吗?
, ?# `* e; O9 a% X9 a- S1 XSmoothIndex:=smoothIndex+sigma;7 h/ L; q9 [# A9 p% A3 S- k
next;. U: F0 {; U5 F, O( O
StationIndex:=stationIndex/Stations;
! k" q' S9 \' e4 l1 v! E7 V1 y* ~SmoothIndex:=sqrt(SmoothIndex/Stations);/ f& v& ~# h. c1 a6 M
8 o2 q4 G3 t' k* W$ S) LQ2:$ @9 v- E& ^, ]9 d! j; t M6 \$ m$ ^
同时,本章中由于用的GAoptimization,给出的结果直接就复制到了tablefile中了。。* {1 F: B0 V; c" K7 o
如果我想得到GA算法中一个收敛情况,那该如何来得到呢?
3 @# W+ o5 Z3 r5 D5 E# L' D7 J u: H将每次的子代复制到一个tablefile中,然后导入到Excel中,然后使用Matlab来处理?' `# `% @& b6 z9 P. @4 ]. s0 E
有没有可以直接在plant中显示的方法呢? |
|