Лабораторная работа: Imitating modelling of a cattle-breeding complex on basis Cedar Bog
CHANGING
Weight^:= ves_1;
Age^:= 1;
END
END
END
# MilkYield
IF (MilkCows:Animal[Index].Kol_voOtelov >= 1)
AND ((MilkCows:Animal[Index].Stelnost < 250) OR
(MilkCows:Animal[Index].Stelnost >280)) DO
NADOI^:= NADOI + 20;
END
# MilkCows are slaughtered
IF MilkCows:Animal[Index].Kol_voOtelov > 5 DO
VesTyw^:= VesTyw + MilkCows:Animal[Index].Weight/2;
MilkCows^: REMOVE Animal[Index];
UBOI^:= UBOI + 1;
END
END
WHENEVER (Stage = 7) AND (Index > NUMBER(MilkCows)) DO
Stage^:=8;
Index^:=1;
END
# F ecundation of MilkCows
WHENEVER (Stage = 8) AND (Index <= NUMBER(MilkCows)) DO
Index^:= Index + 1;
IF (MilkCows:Animal[Index].Status = FALSE) AND
(MilkCows:Animal[Index].Stelnost > (340)) DO
IF Rand < 0.98 DO