Реферат: Имитационная модель интеллектуального агента в условиях конкуренции
FUNCTION strategy
MOBILE SUBCOMPONENT OF CLASS query
LOCAL DEFINITIONS
DECLARATION OF SUBFUNCTION
form(ARRAY [n]REAL:PP-->ARRAY[n]REAL)
DECLARATION OF ELEMENTS
INPUT PARAMETERS
past_buy2(INTEGER), #j=2 l=3 n=9
Stock(LOCATION FOR query),
ARRAY[l] LOST_c(LOGICAL),
ARRAY[l] bal(REAL),
ff1(INTEGER),
I(INTEGER), #номерфирмы
g(INTEGER),
ARRAY [n]param1(REAL),
cash(INTEGER),
ARRAY [l]dem(REAL)
OUTPUT PARAMETERS
ARRAY[n] par(REAL),
past_buy(INTEGER)
LOCAL VARIABLES
average_price(REAL):=0,
cash1(INTEGER):=0
BEGIN
(ARRAY par):=form(ARRAY param1);
#Событие 1
FOR J FROM 1 TO g
REPEAT
average_price:=average_price+Stock:query[J].QB[1];