Banco

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 11

Banco

Model: Banco
Name Value
General
Java Package Name banco
File Name C:\Documents and
Settings\BEEP\Escritorio\ANYLOGIC\Banco\Banco.alp

Active Object Class: Main


Description: Significado de cada una de las cadenas:
- ATM: Cajero Automático
- service: Que nos atienda un oficinista. Tiene una cola embebida. "tellers" nos indica el número de oficinistas que hay (número de recursos).

Name Value
Advanced
Auto-create Datasets true
Recurrence 1
Dataset Samples To Keep 100
Make Default View Area false

Source: source
Name Value

Page 1 of 11
Banco

Name Value
General
Type Source<T extends Entity>
Generic Parameters Substitute Customer
Java Package Name com.xj.anylogic.libraries.enterprise
Embedded Object Collection Type ARRAY_LIST_BASED

Embedded Object Parameters:


Name Value
Arrivals defined by Source.RATE
Arrival rate 0.67
Interarrival time exponential( 1 )
Entities per arrival 1
Limited number of arrivals false
Maximum number of arrivals Integer.MAX_VALUE
New entity new Customer()
On exit entity.enteredSystem = time();
Entity animation shape customerShape
Unique shape for each entity false
Enable rotation false
Enable vertical rotation true

Sink: sink
Name Value
General
Type Sink<T extends Entity>
Generic Parameters Substitute Customer
Java Package Name com.xj.anylogic.libraries.enterprise
Embedded Object Collection Type ARRAY_LIST_BASED

Embedded Object Parameters:


Name Value
On enter timeInSystemDistr.add(time()-entity.enteredSystem);

Delay: ATM
Name Value
General
Type Delay<T extends Entity>
Generic Parameters Substitute Entity
Java Package Name com.xj.anylogic.libraries.enterprise
Embedded Object Collection Type ARRAY_LIST_BASED

Embedded Object Parameters:


Name Value
Delay time is false
Delay time triangular( 0.8, 1, 1.3 )
Speed 10
Capacity 1
Maximum capacity false

Page 2 of 11
Banco

Embedded Object Parameters:


Name Value
Animation guide shape oval
Animation type Animator.SINGLE
Animation direction true
Enable statistics true

Queue: queue
Name Value
General
Type Queue<T extends Entity>
Generic Parameters Substitute Customer
Java Package Name com.xj.anylogic.libraries.enterprise
Embedded Object Collection Type ARRAY_LIST_BASED

Embedded Object Parameters:


Name Value
Capacity 15
Maximum capacity false
On enter entity.startWaiting = time();
On exit waitTimeDistr.add(time()-entity.startWaiting);
Enable exit on timeout false
Timeout Double.POSITIVE_INFINITY
Enable preemption false
Entity priority 0
Animation guide shape polyline
Animation type Animator.PATH
Animation direction true
Enable statistics true

Service: service
Name Value
General
Type Service<T extends Entity>
Generic Parameters Substitute Customer
Java Package Name com.xj.anylogic.libraries.enterprise
Embedded Object Collection Type ARRAY_LIST_BASED

Embedded Object Parameters:


Name Value
Resource quantity 1
Delay time triangular( 2.5, 6, 11 )
ResourcePool object null
Queue capacity 20
Maximum queue capacity false
Enable exit on timeout false
Timeout Double.POSITIVE_INFINITY
Enable preemption false

Page 3 of 11
Banco

Embedded Object Parameters:


Name Value
Entity priority 0
Animation guide shape (queue) queueBeforeTellers
Animation type (queue) Animator.PATH
Animation direction (queue) true
Animation type (delay) Animator.PATH
Animation direction (delay) true
Enable statistics false

ResourcePool: tellers
Name Value
General
Type ResourcePool<T extends ResourceUnit>
Generic Parameters Substitute ResourceUnit
Java Package Name com.xj.anylogic.libraries.enterprise
Embedded Object Collection Type ARRAY_LIST_BASED

Embedded Object Parameters:


Name Value
Resource units are true
Capacity defined false
Capacity 4
New resource unit new ResourceUnit()
Enable priorities false
Request priority 0
Idle unit animation shape idleTeller
Busy unit animation shape busyTeller
Unique shape for each unit false
Enable rotation true
Enable vertical rotation true
Animation guide shape tellerPlaces
Animation type Animator.SET
Enable statistics false

SelectOutput: selectOutput
Name Value
General
Type SelectOutput<T extends Entity>
Generic Parameters Substitute Entity
Java Package Name com.xj.anylogic.libraries.enterprise
Embedded Object Collection Type ARRAY_LIST_BASED

Embedded Object Parameters:


Name Value
Select True output true
Condition randomTrue( 0.5 )
Probability 0.5

Page 4 of 11
Banco

Bar Chart: chart


Name Value
General
Scale Type AUTO
Analysis Auto Update true
Recurrence 1
Advanced
x 500
y 290
Width 240
Height 190
Appearance
Show Legend true
Legend Place SOUTH
Bars Direction UP
Bars Relative Width 0.8

Chart Items:
Title Color Value
ATM utilization red ATM.statsUtilization.mean()

Bar Chart: chart1


Name Value
General
Scale Type AUTO
Analysis Auto Update true
Recurrence 1
Advanced
x 40
y 180
Width 240
Height 130
Appearance
Show Legend true
Legend Place SOUTH
Bars Direction LEFT
Bars Relative Width 0.8

Chart Items:
Title Color Value
Queue lenght blue queue.statsSize.mean()

Histogram: chart2
Name Value
General
Analysis Auto Update false
Advanced

Page 5 of 11
Banco

Name Value
x 740
y 210
Width 240
Height 190
Appearance
Show Legend true
Legend Place SOUTH
Bars Direction UP
Bars Relative Width 0.8

Histogram Data Items:


Title Dataset PDF Color CDF Color Mean Color Width Low % Color High % Color
Wait Time waitTimeDistr mediumOrchi orange mediumOrchi 1 darkMagenta gold
Distribution d d

Histogram: chart3
Name Value
General
Analysis Auto Update false
Advanced
x 740
y 420
Width 240
Height 190
Appearance
Show Legend true
Legend Place SOUTH
Bars Direction UP
Bars Relative Width 0.8

Histogram Data Items:


Title Dataset PDF Color CDF Color Mean Color Width Low % Color High % Color
Time In System timeInSystemDistr chocolate mediumTurqu goldenRod 1 coral violetRed
Distribution oise

Histogram Data: waitTimeDistr


Name Value
General
Number Of Intervals 50
Data range true
Initial Interval Size 0.01
Analysis Auto Update true
Recurrence 1

Histogram Data: timeInSystemDistr


Name Value
General

Page 6 of 11
Banco

Name Value
Number Of Intervals 50
Data range true
Initial Interval Size 0.01
Analysis Auto Update true
Recurrence 1

Oval: oval
Name Value
Advanced
x 455
y 370
Radius X 35
Radius Y 30

Polyline: polyline
Name Value
Advanced
x 20
y 380

Rectangle: rectangle
Name Value
Advanced
x 320
y 340
Width 40
Height 60
Dynamic
Dynamic: Fill Color ATM.size() > 0 ? red : green

Polyline: queueBeforeTellers
Name Value
Advanced
x 100
y 630

Polyline: tellerPlaces
Name Value
Advanced
x 400
y 650

Image: busyTeller
Name Value

Page 7 of 11
Banco

Name Value
General
Images Busy.png
Original Size true
Advanced
x 540
y 560
Width 40
Height 40

Image: idleTeller
Name Value
General
Images idle.png
Advanced
x 620
y 560
Width 40
Height 40

Group: customerShape
Name Value
Advanced
x 140
y 490

Oval: oval1
Name Value
Advanced
x 2
y -8
Radius X 5
Radius Y 5

Polyline: polyline1
Name Value
Advanced
x 0
y -3

Slider: slider
Name Value
General
Orientation HORIZONTAL
Default Value tellers.capacity

Page 8 of 11
Banco

Name Value
Action tellers.set_capacity( (int)value );
Advanced
x 620
y 240
Width 100
Height 30

Java Class: Customer


Name Value
General
Java Class Type JAVA_CLASS
Text /**
* Customer
*/
public class Customer extends
com.xj.anylogic.libraries.enterprise.Entity implements
java.io.Serializable {

double startWaiting;
double enteredSystem;

/**
* Default constructor
*/
public Customer(){
}

/**
* Constructor initializing the fields
*/
public Customer(double startWaiting){
this.startWaiting = startWaiting;
}

@Override
public String toString() {
return
"startWaiting = " + startWaiting +" ";
}

/**
* This number is here for model snapshot storing purpose<br>
* It needs to be changed when this class gets changed
*/
private static final long serialVersionUID = 1L;

Simulation Experiment: Simulation


Name Value
General
Active Object Class Main
Random Number Generation Type randomSeed
Advanced
Maximum Available Memory 64
Differention Equations Method EULER
Mixed Equations Method RK45_NEWTON
Algebraic Equations Method MODIFIED_NEWTON
Absolute Accuracy 1.0E-5

Page 9 of 11
Banco

Name Value
Time Accuracy 1.0E-5
Relative Accuracy 1.0E-5
Fixed Time Step 0.0010
Presentation Top Group Persistent true
Model Time
Model Time Units Minute
Stop Option Stop at specified time
Initial Time 0.0
Final Time 100.0
Presentation
CPU Time Balance ratio_1_2
Execution Mode realTimeScaled
Real Time Scale SCALE_1
Window
Title Banco : Simulation

Text: text
Name Value
Advanced
x 40
y 30
General
Alignment LEFT
Font Name Serif
Font Size 28
Bold Font Style true
Text Banco
Advanced
x 40
y 30

Text: text1
Name Value
Advanced
x 40
y 63
General
Alignment LEFT

Page 10 of 11
Banco

Name Value
Font Name Serif
Font Size 16
Italic Font Style true
Text Se trata de unas de las simulaciones que viene como ejemplo en el
propio tutorial de Anylogic. Se simula el
funcionamiento de un banco, con un cajero y varias ventanillas.
Los trabajadores de las ventanillas forman
parte de un pozo de recursos.
Advanced
x 40
y 63

Button: button
Name Value
General
Label Text Run the model and switch to Main view
Action if ( getState() == IDLE )
run();
getEngine().getPresentation().setPresentable(
getEngine().getRoot() );
Advanced
Font Name Dialog
Font Size 11
x 40
y 150
Width 330
Height 30
Dynamic
Dynamic: Label getState() == IDLE ?
"Run the model and switch to Main view" :
"Switch to Main view"

Page 11 of 11

You might also like