Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
The p a
rameters are stable and only change if the operating point changes m a r k
first 80 minutes are due to unrealistic initial states for the grinding
After time 0 it takes about 9 input moves for the optimizer to find the
optimum feed rate of 3.')b tonnes/hour and the optimum mill water addition.
minutes, the optimizer increases the feed rate to increase the fractional
fractional filling of the grinding media interstices and achieve the best
minutes, the optimizer decreases the feed rate to decrease the fractional
*.73
t.mt
l.M
QJ>
CO mill
d water
o a. h g rad ie n t
mill f r a c t i o n a l filling
CL
CO
CD
Ckl
-e.»l
feed
g ra d ie n t
’
ime Un its
Figure 13. Simulation result using aetup file: setup_6
Setup 7
CD
C/0
Cl
o
Q _
CO
CD
Ci£
The adaptive optimizer keeps the autogenous mill very close to its optimum
(defined as the operating point that causes maximum m 1'11 power draft).
new moael par .meters from which gradients are calculated that will drive
setup_6 and setup_7 in appendix J). For this general study the fine tuning
The majority of the ideas and algorithms for improvements to RLS esti
mation are new and still n<*ed to be understood fully. A more systematic
As with the ball mill case study it was found that the covariance reset
ting modification to the RLS estimator gave the best rosults. Its advan
tage is that tho covariance matrix is at its smallest when the gradients
ar«> used.
of the optimizer. The simulation results show that the optimizer performs
reliably and keeps the plant at its optimum in the face of economically
derived from a simple on-line line.ir dynamic model describing the mill
perform.nee, can be used to drive the mill towards and track a shifting
Conr. 1 ns ions 83
study that could then lead to implementation on an experimental autogenous
grinding circuit.
control does have a lot to offer and can address real needs in connection
with the control of grinding mills. The research has shown that further
ysis on the theoretical side, and on the practical side, the need to i >t
pp.223-230.
CEC/MB-PDR/ 12
Hemisphere, 1975.
6. Duckworth, G. A. and Lynch, A. .J. (1982) The effect of some operat ing
variables on autogenous grinding circuits and their iripl icat ions for
C.I.M., 1982, 11 1 -1 - 1 1 1- 1 .2 1 .
References 85
8. Ellis, J. E. and Roberts, P.D. (1985) On the Practical Viability of
Integrated System Opt imisation and Parameter Estimat ion IEE Control
11. Flook, W.R. and Flasket, R.P. (1982) Design and control practice for
14. Goodwin,G.C . and Sir, Kwai Sang (1984) Adaptive Filtering Predicr.ion
15. Goodwin, G, C., Lozano Leal, R., Mayne, D.Q. and Middleton, R.H.
References 8ft
17. Haimes, V. Y. and W i s m e r , D. A. (1972) A computational approach to
18. Herbst, J. A. and Rajamani, K. (1982) The applicat ion of modern c on
19. Hinde, A.L. (1977) Control of milling circuits using simple feedback
loops. Vacation school "Grinding Theory arid Practi ce" - South African
20. Hulbert, D.G. and Barker, I.J. (1985) The control and optimization
24. Lynch, A.J. (1977) Mineral crushing and grinding circuits. Elsevier
Re! eiences 87
26. MacLeod, I. M, (1987) Series of Private Discussions and Notes on
28. Mokkon, A. H. and Viol , F. W. (198t>) Improved automat ion rnd control
31. P auw , 0. C., King, P..P., Garner, K . and van Aswegcn, P. C. (I9ft5)
1 9 M . pp. 190-209.
References 88
35. Saridis, G. N. (197^ Stochsstic methods for identification and con-
trul - <? surrey IEEE Trans. Automatic Control, vol. A C - 19, 1974.
p .7 9 E.
36. Savas , E.S. (196.5) Computer Control of Industrial Processes New York,
rtcGraw-Hill, 196 j.
41. Stanley, G.G. (197**b) Mechanism:; in the autogenous mill and their
42. Stanley, G.G. (1977) The operat ion f autogenous and semi-autogenous
kefercncos 89
43. Sternby, J. (1980) Extremum control systems - an area for adaptive
1980.
References 90
A P P E N D I X A. AN EX AMP LE OF R O B U S T MODEL I D E N T I F I C A T I O N
Consider the SISO case with one measurable disturbance included in the
setpoint or a direct plant input, in fact any input variable that can bi
i i -0
A(q 1) = ao + a ,q + a 2q ~
This is often the case because the DARMA model is an incremental model.
r ( t) = r(t-l) j
n - q * s)r(t) = o
Q(q~ *) = (1 - Eq"*)
Q C q ~ 1) in the model denominator should filter out the dc term from the
For the low pass filter ( 1/1'.(cj" ‘)) we choose a highest frequency o: in
order low pass filter the Laplace variable can be related to the backward
1
(st + l)2
where t
w,dB
is :
whoi-o h = and
e, ■
* 2(h-l)/h2
e, = (hJ - 2h + 1)/h 2
Now we have the pre-filter and u^. and z ( cai. determined for
This appendix gives a simple example of how the steepest descent gradient
From the dynamic model derived in appendix A, and extracting the steady
Noise" on page 2*) then the steady state model will include the iilter
coefficients e.. The only difference between Y^(t) and Y'(t) is that Y ^
has been filtered by 1 / E (q ~ 1). Since all the variables are assumed to
The gradient of the objective wi"h respect to the plant input u^. of this
case, and tin derivative would have lo be evaluated at the operating point
u (t ).
calculation, and therefore also in the model, then the chain rule for
Applying the steepest descent gradient search algorithm the plant moves
AH'
u f (t) = u f(t-l) + u ___f
3Uf
whore w is the step size to ensure convergence and the + sign finds a
maximum and the - sign a minimum. In terms of the model parameters the
relative deadzone < Lection entitled "Coping with Modelling Error within
df := 0.5 ~
dd - (dd (2 ♦ dd)) i df - 0.073
1 * dd
b c* constant for product calc*'lotion
* -1
’ 4 ' 2 normalize the maximum product
1 c
n n ■2
2 2 .■
product :- 1
opt
•
ft 0.5
opt
2
mt :■ c • Tft 1 +0.4 mt *1.4
opt [ opt J opt
97
Optimum operating point if disturbance dd is not zero:
1 + dd
ft ft * 0.525
opt opt
-a 2 2
product :« n ft — c • ft ♦ b c product « 1 .216
opt opt 2 opt . opt
£
mt :» c 1 [ft + dfl ♦ 0.4 ®t » 1.83
opt L opt J opt
ft :« --- scaling of ft
i 200
4
mt c [ft ♦ dfl + 0.4 and in the steady state:
i L i J
It :» mt
i i
Calculation of mill product:
-a 2 2
product :» n — c • ft * b c ft
i 2 i
2 3
dproduct :« n -a c •2 ft + 2 b e ft
i i i
dft
i 2 c ft
98
G ra d ie n t o f product w . r . t r e g u la to r s e tp o in t I t :
gt :■ mt - product
i i i
Gradient w.r.t ft
99
Gradient v . r . t It
100
A P P E N D I X D. B A L L MI LL A D A P T I V E O P T I M I Z E R P A S C A L PR OG RA M
LISTING
const no_par«5i
p i * 3 . 1 4 1Bt
vai
< simulator va ri ab le s >
T :real s {Time)
TST A R T :r e a l i
T S T O P :r e al tS T O P :booleani
DELTsrealj ( Integration .step size for simulat i on >
S A M P L E : integeri < controller sampling rate >
< as a multiple of DELT >
OPT:integen < optimizer update time >
< as a multiple of SAMPLE'OELT )
1 0 6 : integeri < data logging time as a multiple >
{ of SftMPLE'OELT >
p r e v _ t i m e : r e a l j < variable to sto'i time >
< from previous iteration >
< plant c o n s t a n t s I
A:reali < integrator gain >
d t n : l n t e g e n ( mill transpo't delay >
< as a multiple of PELT >
d ts:integer) < separator tronsport delay >
< as a multiple of DELT >
Ki:reali < reg u lator integrator gain >
102
< cnnt.-oller variables >
rx_mag:real•
r t _ m a x :reali
init_rt:reels
s t a r t :i n t e g e r (
size._sp:real;
step_size:reals
cpt_st’ art :real i < optimization start tine >
gradient ,max_grad,mi' g>~nd:real i
•include * p l o t _ v a r . p ’t
<........................ -..................................................
procedure read_setupi
var path:strpathi
f H a l :text i
begin
writeln! ’ O p t i m i z i n g regulator applied to Rail Mill * >i
u r i t e l n < ’Simula t i o n S t u d y ’)|
writeln!’ File to set up simulation: s e t u p ’ll
path:• ’ / u s e r s / b l e l o c h / s l m _ d i r / b a l l _ m i l l _ d i r / s e t _ p l a n t ’i
reset< filet.path)i
r e a d l n < f 1l e i ,T S T A R T )iu r 1teln( ’ Slmulat ion start time ’.TSTftRT:3"2 )I
readl n( f i 1 e 1 .TSTOPli
urlteln(’ Stop time ’,T S T O H :3 :2 >I
readln< f i1e 1 .DELTli
uriteln<’ Plant simulation campling interval ’,DELT:Z:Z>|
readln< f i1e I .dtm ) i
u r iteln < ’ Hi 11 pure delay ’,dtm)i
readln< f llel ,dts ) i w ' i -; eln(’ Separator pure delay ’,dts)i
readln! f i l e l ,A ) i u riteln<’Integrator g a i n ’,R:Z:Z)|
r e a d l n < f i1e 1 ,K i )i u r 1 teln < ’ Regulator integrator gain ’.Ki:2:Z)i
r eadln<flle d lst_m _prod'i
u r i t e l n ( ’X d i s t urbance ’,< r*i st_m_prod» 1 0 0 ): Z :Z ) i
readln< f i l e l ,dis t _t_prod)i
uriteln! ’ Disturbance start time ’,dist_t_prod: 3:Z ) I
r e a d l n f f i l e l ,dist_st_prod)i •
writeln!’ Disturbance stop time ’,d i s t _ s t _ p r o d : 3:Z )i
readln( f 11 e l ,d i s t u r b _ r a t e )I
u r l t e l n < ’T ime uhiie model is changing ’,disturb_rate:Z : 1 ) i
103
readln<filel ,i*ag_noise)iur iteln<’ wag_noise ’,*og_ n o i s e :Z :Z ) i
readln< f l l e l ,bunduidth)iurlteln< 'bandwidth ’,b a n d w i d t h : Z : 3 ) s
c l ose(filet ) s
end i
<.....................................................................
procedure r e a d _ c o n t r o l 1er_setupi
var path:strpatht
f l i e ! :t e x t ;
i ,J :i n t e g e r ,
beg i n
u r i t e l n ( 'F lie c o n t a i n ing controller settings: set_cont')»
p a t h : • '/ usera/ble l o c h / s i m _ d i r / b a l l _ m 11_ d i r / s e t _ c o n t ’s
reset< f 1 1e I ,path >i
readl n( f i 1 e I ,‘ JflMPLE > t
uriteln<’ C o n t r o l ler sampling period ',S A M P L E « O C L T :3:Z )i
readln< f l l e l ,OPT ) i
ur l tel n( 'Opt inizat ion update tine * .QPT»Sr1MPLF. *QEL T : J: Z ) i
r e e d l n(f 1 1e I ,106 ) I
u r i t e l n('Logging interval ’,L 0 6 « S A M P L E*DELT:3:Z )I
readln(flie I ,dead_tine)|
r eadl n< f 11 e I ,f o'^get t ing_factor ) I
readln< f i l e t ,ep>i
resdln( filet ,deadband_t i«e _ c o n s t a n t ) i
r e a d l n ( f i l e t ,beta)i
readln< f i l e t ,i n i t _ P _ « a t )i
readln< f 1 1 * I .covar i a n c e _ r e s e t t i n g )i
readln< f i l e t ,c o n s t a n t _ t r a c e )I
r e a d l n < f i l e t , » t e p _ s i r e >i
readln< filet wan orad?I
readln(filet,*tn_Qrad)t
readln< f i l e t , r t _ « a x )i
reidln( f i l e t ,i n l t _ r t )i
readln( f i let,rt_«ag >I
readln( f i l e t ,siie_sp)i
readln< f i l e t , k 0 > i
readl n< f i l e t ,k I )i
readln< f i l e t ,e»t_onlv)i
r e a d l n ( f i l e t ,est_start_t i w e )i
r e a d l n ( f i l e t ,e s t _ s top_ti«e )i
readln< f i l e t ,o p t _ s t a r t ) i
r e a d l n < f i l e t ,d e b u g )i
close(fllel)i
< initialize storage variables >
for t:-0 to S0 do beg in
s u ( 11:
sv( i1 : > 0 1
endi
syt 0 1 : > 0 i s y l 11:>0isy( Z i :>01
end i
{......................................................................
procedure read_initial_para«etersi
var path:strpaths
filet:tex 1 1
i *i n t e g e r »
begin
pa t h : “’/users/bleloch/si /bal l _ m 11 _dir/init lal_ p a r ^ e t e r s ’i
reset< f i l e t ,path)t
for i: > I to n^_par do r e a d l n<f l l e l . p a r t l l )i
close< f 11e 1>i
endi
{.....................................................................
function sa«ple_tiwe:booleani
begin
if round<T*t0> nod r o u n d < S A H P L E * O E L T * 10 )>0 then sampl e_t -.*e:"true
else sanple^time:> f alsei
endi
104
<........................................................................... >
function o p t _ t l « e :bool earn
beg 1 n
If round'T»10> nod round<OPT»SflW’
L E »OElT»10>-0 then opt_t m e :-true
else opt_tt*e:-false;
end!
{-................................................... ...................... >
function 1o g _ t m e :boolean;
begin
if roun\J< T* 10) nod round< LOG*SflMPtE»OELT» I0 )*0 then log_tine:-true
else 1o g _ t Ine:-false;
end)
<...................................................................... ..... >
f unci Ion dul ay( store_no: integer ; v a n a b l e : r e a l i t l n c : l nteger >: real «
var l:I n t e g e r i
begin
riel a y :" s t o r e I s t o r e _ n o .t m e ] t
for i:-tine downto I do storel s t o r e _ n o ,11:* s t o r e ! s t o r e _ n o ,i - I 1 i
s t o r e I » t o r e _ n o ,0):• var tab l e i
end i
{— ......................................................................... >
f unct ion 1 init< v a r l a b 1e ,w a x , n m : r eal): real;
begin
if ( v a r i a b l e > n a x ) or < varlable<nln) then begin
if variable>nax then linit:-naxi
If v a r l a b l e < n i n then ! l n l t : - n l m
end
else 1 l n l t :-v a r l a b l e ;
end t
<.......... -.............. ................................................ >
function s r a n d 4 8 : l ongreal(external I < Bandllulled bausslan Noise >
function d r a n d 4 8 : l o n g r e a l «external i
f unct ion nolne< n a Q _ n o i s e ,c u t o f f :r e a l ): r e a l i
const signa-0.li
var i:integer;
a c c u n : 1o n g r e a l i
begin
accun: ■0;
t o r : « 1 / ( 2 « p i ‘c u t o f f )i
< convert fron linear distribution to Gaus s i a n d i s t r ibution >
for U " l to 12 do a c cun:-accun ♦ 2»< drand<8-0. S > i
n:-accun/12 1
< llnit b a n d w i d t h >
b n : - b n * e x p < - S f W L E « O E L T / t o r )♦»igna « n « s q r t < I-e x p < -2 » S A M P L E * O E L T / t o r ) )i
n o t s e :- w a p noise*bn;
endi
{........................................................................... >
funct ion disturbance* di sturb_t m e .disturb_stop:reali
d l sturb. lag:r e a l t d i s t u r b _ r a t e : r e a l ): r eal;
begin
if T < d i s t u r b _ t lne then d i s t u r b a n c e _ s t o r e :-0
else if T < d i s t u r b _ s t op then
d i s t u r b a n c e _ s t o r e :-di sturbance_store
♦d i sturb_nag/(round< 2 * d i s t u r b _ r a t e / 0 E L T ))i
if T > < d i s t u r b _ t l n e + d l s t u r b _ r a t e )
then If T<disturb_stop then d i s t u r b a n c e _ s t o r e :-disturb_Mag;
if T>-d i s t u r b _ s t o p then
d i s t u r b a n c e _ s t o r e :-d:sturbance_store
- d isturb_nag/( round< ? * d i s turb_rate/OELT >)t
if T>< d l s t u r b _ s t o p * d i s t u r b _ r a t e I then d i s t u r b a n c e _ s t o r e : «0i
If d i s t u r b a n c e _ s t o r e <0 then d i s t u r b a n c e _ s t o r e :*0;
disturbance:-rilsturbance_store;
end i
<........................... -.............................................. )
procedure r a s e t_P<valu e :real );
var 1,J :Integeri
105
uegin
Vor i:« 1 to no_par do
for j:- I to no_par do
if i m j then P m at 1 i , 1 ):■value
else P_*atl i ,J 1 :•?>(
endi
procedure nodelI
begin
if T > p r ev_ti«e then
dd: -disturbance* dlst_t _prod .di st_st_pr orl,di st_n_prod ,disturb_rat e > i
if T > p r ev_tl»e then f t :-delay< I ,x [ I 1 ,dtw) < nill pure delay >
else f t :“x I 1 1 1
{ d i s c h a r g e c o u p l e d to product d i s t u r b a n c e >
ddf: S - s q r t< 14 d d ~ s q r t < d d « ( Z + d d ) ) i l l •
*t:-4»sqr<ft+ddf)*0.4| { dls .iiarQe function >
< product function >
p r o d u c t : “Z«((-1/Z)*16»ft»ft+16» sqr( ( l + d d ) / Z ‘)»ft*fti
{ classifier und e r f l ow }
g t :“« t - p r o d u c t i
if gt<® thc.t gt:-®!
if T>p r e v _ t i « e then g t :“delay( Z , g t ,d t s )t { separator pure delay >
f e e d _ r a t e : I Z 1»
< nett flow into Mill >
11 :«f e e d _ r a t e + g t i
< Mill d y n amics >
d»I 11:-ft«<lt-nt)i
< solids feedrate regulator dynamics >
Jxl 2 1 :-Kl*(rt-lt >i
prev_tl«e:"T«
end i
<...........................................................................
PROCEDURE Runge_Kutta<
CONST NSTATE-Zi
Vttfl
l: INTEGER'
X s t a r t . K t . KZ, K 3:a r r a y ! 1 ..NSTATE1 of reali
Begin
FOR i s - I to NSTHTE do begin
X s t a r t l 1):■ XIili
K U l l J - dX! i 1 • OEL Ti
XI 11:- XstartI 11 4 Kll ll/Zi
end i
Ts- T 4 O E L T/Z i
Modeli
F O R i:»1 to N S T A T E do begin
KZlll:- dXm»OELTi
XI 1.1 :■ Xstar .111 4 K Z ( t l / Z i
•r.ii
•*iodo I |
FOR i:- I to NUTATE do begin
K 3 1 1 1 d X l 1 1* D E l Ti
X I 1) :• X s t a r t l i 1 4 K 31 1 J i
endi
T: - T 4 D E L T/Zi
m del i
FOR i:• I to NSTATE do
XI 1 1 :« Xstartltl 4 (Xllll ♦ K ZI i 1 • Z 4 K 31 i 1 • ? ♦ dX( 11 »DEL T >/ G .0i
T :«round( T« 1V b >/ 100i
Endi < procedure Runge_Kutta >
<44444444444444444444-
PROCEDURE integrator!
var l:integert
Begin
106
Runge_Kuttai
IF (T >* TSTOP » D£LT) then STOP:- T R U E i
Endi { procedure integrator >
{♦*♦♦♦ +♦♦ +•)♦+♦♦+ +♦♦♦♦♦+ ♦♦♦♦++♦<♦♦♦♦+♦♦♦♦+♦+♦♦♦♦♦♦♦+♦♦♦♦+♦ +♦♦♦+*<♦*•
procedure initialize*
var i ,j :Integer;
begin
S T O P :“FALSEi
atep_no:-lt
for i:-® to ti®0 do
for j •■I to 2 do s t o r e ! j ,i 1:«0i
< lnltiai states >
x ( I ):-«t
x (21:*0i
r t :“init_rti
p r o d u c t :*<9i
bnn:■srand48i { seed random number generator >
r e s e t _ P ( i n i t _ P _ m a t )i < reset c o v a n a n c e matri* >
raad.initial _parametersi { road initial Model parameters >
endi
{........................................................... ........
function stept s t a r t :integer >:integeri
begin
if T>*start then step:*! else steo:-0i
and i
{...................................................................
procedure regression_v®ctor( y ,u, v r e a l >i
var i:integeri
b»gln
r e g l I ]:-sfy( 11 i
rt»g(21:-.fyl21i
r e g l 3 ] :-sfu(1)i
regl 41 .‘ "sful 2 1 1
r « m l S l :-li
107
If i"J then P_mat [ i ,i 1: ■< k ® / t r a c e )»P_mat I 1, 1 1 -*k I
eioe begin
P_met I i ,J ]:■■< k ® / t r a c e > » P _ m a t ( i ,J 1;
If ir1_«f t( 1 ,J J <epa then P_mat I i ,j ):«<9|
tndi
end;
endi
< ..............................................................- ....................................................................................................................... - ..........................................................................
funct i o n m u l t l p l y _ v e c ;r e a l i
var l . j : I n t e g e r »
d u m m y :reali
begin
d u m m y :>0i
for i:- 1 to no_par do d u m m y : " d u m m y t r e g C 11*oar( il i
m u I t 1piy_v e c :"dummyi
endi
{.........................................................................
procedure ettlmaxori
var denom:reali
K ,L:a r r a y M ..n o _ p a r 1 of rea)i
1 ,J : Integerj
................................... >
function norm:reali
var K :arrayt I.. no__parl of real i
i ,J :Integer)
d u m m y '.real i
b e gin
for i:« I to no_par do Kt il:*®i
for J :■ ! to no_par do
for 11*1 to no_par do
K( J ) :aK( J 1+regt il»P_matl 1 .J 1 1
dummy:-®t
for i:» I to no_par do d u m m y :“dummy
+ K I 11* r e g t 1 1 i
norm:"dummyi
endi
<........................................ >
begin
P e a t :- m u ltlply_vect
error:-of y l ® 1 - P o s t i
denom:"forgett ing_f actor + normi
for is- I to no_par do begin
Kill: -P..mat 1 1 , 1 1 *reg( II +P_mat [ 1 , 2 1 «*regt Z1
♦P_matf i 3 1 » r e g l 3 H P _ m a t t i , 4 1 * r e g i 4 )
♦P _ m a t [ i ,51» r eg[5 1 1 (+P_matI 1 ,61*regl61
♦ P _ m « t l 1,71»reg(71+P_mat ( i ,81»reg( 81
+ P _ m a t I 1 .91» reg[9 1 ♦P_mat I i ,1®1»reg( I®) I >
•nc .
for 1:• I to no_par do
L t 1 1:" r e g l 11» P _ m a t [ ) , 1 1♦ regt i 1« P _ m a t ( ? . i 1
♦ r e g t 31» P _ m a t I 3,11*reg(41» P _ m a t [4 , 1 1
♦ r e g t 5 1 «P_matIS,ili<+reg(6)»P_matl6,il
♦regt 7 1 * P_mat17,1 H r eg!8 1 »P_mat t 8 , 1 1
♦regt 9 1 »P_mat t 9 , 1 1 + r egtI#1«P_matt t ® ,i1 1 >
for i:» 1 to no_par do
part 1 1 :-par I i1♦« 1 11•error/denomi
for 1!" 1 to no_par do
for j:* I to no_per do
P_’«at I i ,j 1: •( 1/ forget t ing_f actor )i P_ mat t i ,j 1- K I 1 1»Ll J 1 / denom > |
end,
{ ..................................................... - .................................................................................................. .......................... ...................................................................- .......................................
procedure optimizer'
begl n
rt :"rt +step_.si*e»gradient t
rt :" li m i t < r t , r t _ * a x ,®)t
end!
108
{....................................................... ..............
funct io n dead_band:booleanj
contt cdz0-0.000C1i
cdz I i
c d zZ - 0. 00001 i
c d z 3-0.00001 i
( c dz 4- 0 .2 i
alpha*®.&6i>
begin
If T > SAMPLE•OELT then d z ( 11:»dzt01 else dzll):*0i
<if T<*SAMPLE then b e t a : *sqrt<cdz4 + I/< I - a l p h a ))i >
dz( 0 1 :« de ad b a n d _ t ima_constant*dzl 11
+c d z 0t c d z I*abs( product >
♦cdzZ*abs< feid_rate)
+ cdz3»abs( s i z e )i
e r r o r :-pro du ct - P e o t i
If abs*beta*dzl0 ' >>abs(e r r o r ) then dead_ba->d:-true
else dead_band:-falset
endt
<......................................................................
procedure dumpi
var I S integeri
begln >
wrltelfrt'Tme * ,T:3:Z>|
wrltelnl' R e g r ession vector: ’)|
wr 1 tel ' • >|
for ls»t to no_par do urite(reg( 1(2:3.' 'Jiwritelm
writeln<’ Parameters:
for i s« I to r o u n d ! n o _ p a r / 2 ) do
writelni ' ' ,part2*\ 11 s3:3,par(2*li13 > 3)(
wr 11 e 1n ( ’ P_matl * hwrltc. ' ’>|
for t:«l to no.par do wr i te< P_mat f 1 .11 :fcs 2 , * ' l i w r i t e l m
writelni' Product ' . p r o d u c t 3 1 i
wrtielM ' Mill Power ' .p o w e r :3:3)I
wrlteln<• Estima t i o n error *,e r r o r :2:4 ) i
writelni’ 6 r ad lent ' . g r a d i e n t :I :3)i
endi
{......................................................................
proc e d u r e controlleri
beg i n
If e s t _ o n l y then tf opt time then rt:«rt ♦ rt„magi
rt:-rt+no:se<«ag_nolse,bandwidth)i < add noise >
regresston_rf»otor( product,rt.slim)i
< call estimation procedure >
If T< e s t _ s t o p _ t m e then
if T>est_start_tlme then
If not tiead__band then e s t i m a t o r i
< c a lculate gradient >
If T > e s t _ s t o p _ t )me then P e s t : am u l t l p l y_veci
g r a d i e n t :■<pari 4)fpar I 4 ) )/< 1-Ip a r [ t I+ pa~I 21 )> i
(if absl pari 31 ♦pari 41 K 0 . 0 I then
if at>s( 1 -par ( 11 -par ( 21 )>abs( par I 33 ♦par I 41 > then
g r a d i e n t :*0t >
g r a d i e n t : *1 lmi t igradient ,max_gr ad ,min_grar! 11
If o p t _ t Ime then If debug then dumpi < dump variables t
< call optimization procedure >
if not est_only then
if T>*opt_start then
if opt_tlme then
If ft>0.3 then optimizeri
If c o v a r i a n c e _ r e s e t t i ng then if opt_time then r e s e t _ P < l n l t _ P _ m a t ) i
if constant_trace then tracei
endi
<......................................................................
p r ocedure log_points< curve_no,step_no: integerivalce.Tireal)i
109
begin
datanatr ix_xl c u r ve.no ,a t e p _ n o l :• f i
d a t a « a t r i * _ y [ c u r v a _ n o ,a t e p . n o ) :‘valuei
and)
procedure log_datai
var i : I n t e g e r i
begin
log._prlnta< 1 ,at e p _ n o ,a 1*e ,T ) i
log. o l n t a ( 2 ,a t e p . n o . p r o d u c t ,T )i
loo o o i n t a ( 3,a t e p _ n o , f t ,T )i
l o g _ pointe(4 , a t e p _ n o ,f e e d _ r a t e ,T )i
log_pointa< 5 , atep_.no .gr a d i e n t .T ) s
log_pointa(6 , a t e p . n o . P e a t ,T >i
log_polnta< 7 . a t e p _ n o . r t .T )I
l o g _ p c i n t a < 1®,a t e p . n o ,b n .T )i
log_polnta< 8 , a t e p _ n o , g t .T >i
log.poIntel 9 ,etep_.no , * t .T ) i
log pointa( 1 t,atep_no. I t ,I ) i
at e p . n o : - a t e p _ n o + 1t
endi
(..................................................................
procedure urite.datai
var
p a t h , p a t h i :atrpathi
1 .dummy:integer|
procedure u r t te_f 11 e( n a m e :etrname ic u r v e _ n o .no_of _ p o l n t s : i n t e g e r >i
vflkr d i r e c t o r y :atrpathi
t:Integeri
be g i n
directory:-pathi
strappend(directory,n a m e )i
reurlte<flle_var.directory)i
u r lteln< f 11e v a r ,name >|
urlteln( f 11e _ v a r .no of polnta >i
for 1 i■1 to n o _ o f .polnta do
writeln(f ile_var.riatamatrtx_x[curve_no,1),
datamatrlx_ytcurve_no.1 1) i
cl oae< f 11 e_v«r .'SAVE ’>i
endi
begin
path:■ '/uaera/bleloch/alM_dir/ball_Mlll_dir/’i
urite_f ile< ’f oed.rata' ,4 ,atep.no-1 > i
urit*_file<’aize’.1.atep_no-I)i
urite_f11e('nroduct' ,2 .atep_no-I)i
urlte_flle( ’ V t ’,3,«tep_no-I)|
urite_f ile<’ P e a t ', fi.atep.no-I )i
urit»_fllo( 'mi ’.9.atep.no-I)i
urlte_f lle('gt ’.0.atep_no-1)i
urlte_flle('gradient' ,S.atep_no-1 )i
ur 11«_ f lle< 'noiae' . I®.etep ">o- 1 )i
u r lt e _ f 11e < ’
poner’.7.atep.ru 1 )I
u r 1 1e_f11e( '11 ' ,I 1,atep.no-1 ) i
endi
.......................................* ........ ..................................................... .............
110
Author Bleloch Mark John
Name o f thesis An Adaptive Optimizing Regulator For An Autogenous Mill. 1987
PUBLISHER:
University of the Witwatersrand, Johannesburg
©2013
LEGAL NOTICES:
Copyright Notice: All materials on the U n i v e r s i t y o f t h e W i t w a t e r s r a n d , J o h a n n e s b u r g L i b r a r y website
are protected by South African copyright law and may not be distributed, transmitted, displayed, or otherwise
published in any format, without the prior written permission of the copyright owner.
Disclaimer and Term s o f Use: Provided that you maintain all copyright and other notices contained therein, you
may download material (one machine readable copy and one print copy per page) for your personal and/or
educational non-commercial use only.
The University o f th e W itw a te rs ra n d , J o h a n n e s b u rg , is not responsible for any errors or omissions and excludes any
and all liability for any errors in or omissions from the information on the Lib rary website.