cancel
Showing results for 
Search instead for 
Did you mean: 

Filling buffers using a table in the init method

Pioneer
Pioneer

Hello,

 

I would like to fill my buffers using a table in the init method as the amount of MUs varys.

I got a model that works (see attached file), but it is almost as much work as using "for" multiple times.

 

Is there a simpler solution to my problem?

Thank you,

David

2 REPLIES

Re: Filling buffers using a table in the init method

Phenom
Phenom

all data you need you will find in your table. You can use a nested loop the create the necessary amount of MUs in the buffers:

 

is
	i:integer; 
	k:integer;
	
do
	for i:=1 to tabelle.yDim loop
		for k:=1 to tabelle[2,i] loop
			.BEs.Fördergut.create(tabelle[3,i]);
		next;		
	next;
	
end;

Steffen Bangsow
freelance simulation specialist  
web: www.bangsow.eu
mail: steffen@bangsow.net


Re: Filling buffers using a table in the init method

Pioneer
Pioneer
Thank you very much. I greatly appreciate your constant help.