GENERATION OF EPC BASED SIMULATION MODELS. EURO 2012 Vilnius, Lithuania



Similar documents
An open source software approach to combine simulation and optimization of business processes

Design Pattern for the Adaptive Scheduling of Real-Time Tasks with Multiple Versions in RTSJ

Cohort: BCA/07B/PT - BCA/06/PT - BCNS/06/FT - BCNS/05/FT - BIS/06/FT - BIS/05/FT - BSE/05/FT - BSE/04/PT-BSE/06/FT

Sample CSE8A midterm Multiple Choice (circle one)

Classes and Objects in Java Constructors. In creating objects of the type Fraction, we have used statements similar to the following:

Introduction to Java

Translating to Java. Translation. Input. Many Level Translations. read, get, input, ask, request. Requirements Design Algorithm Java Machine Language

Threads 1. When writing games you need to do more than one thing at once.

J a v a Quiz (Unit 3, Test 0 Practice)

STORM. Simulation TOol for Real-time Multiprocessor scheduling. Designer Guide V3.3.1 September 2009

Realizing Enterprise Integration Patterns in WebSphere

Problem 1. CS 61b Summer 2005 Homework #2 Due July 5th at the beginning of class

Embedded Programming in C/C++: Lesson-1: Programming Elements and Programming in C

TUTORIAL FOR INITIALIZING BLUETOOTH COMMUNICATION BETWEEN ANDROID AND ARDUINO

CS 111 Classes I 1. Software Organization View to this point:

Monitors, Java, Threads and Processes

Part I. Multiple Choice Questions (2 points each):

Licensed for viewing only. Printing is prohibited. For hard copies, please purchase from

Mobile App Design Project #1 Java Boot Camp: Design Model for Chutes and Ladders Board Game

AP COMPUTER SCIENCE A 2007 SCORING GUIDELINES

CS 141: Introduction to (Java) Programming: Exam 1 Jenny Orr Willamette University Fall 2013

COSC 111: Computer Programming I. Dr. Bowen Hui University of Bri>sh Columbia Okanagan

Java Classes. GEEN163 Introduction to Computer Programming

Building a Multi-Threaded Web Server

Java Interview Questions and Answers

JAVA.UTIL.SCANNER CLASS

1. Use the class definition above to circle and identify the parts of code from the list given in parts a j.

Object-Oriented Design Lecture 4 CSU 370 Fall 2007 (Pucella) Tuesday, Sep 18, 2007

Chapter 2 Introduction to Java programming

JAVA - QUICK GUIDE. Java SE is freely available from the link Download Java. So you download a version based on your operating system.

Vim, Emacs, and JUnit Testing. Audience: Students in CS 331 Written by: Kathleen Lockhart, CS Tutor

Tutorial 1: M/M/n Service System Simulation Tutorial 2: M/M/n Simulation using Excel input file Tutorial 3: A Production/Inventory System Simulation

1. What are Data Structures? Introduction to Data Structures. 2. What will we Study? CITS2200 Data Structures and Algorithms

Explain the relationship between a class and an object. Which is general and which is specific?

Creating a Simple, Multithreaded Chat System with Java

e ag u g an L g ter lvin v E ram Neal G g ro va P Ja

Outline of this lecture G52CON: Concepts of Concurrency

Official Android Coding Style Conventions

First Java Programs. V. Paúl Pauca. CSC 111D Fall, Department of Computer Science Wake Forest University. Introduction to Computer Science

Sharpen Solutions. 1 Part One. Sometimes there s more than one right answer. And sometimes the

UIL Computer Science for Dummies by Jake Warren and works from Mr. Fleming

The C Programming Language course syllabus associate level

Creating a 2D Game Engine for Android OS. Introduction

Algorithms and Data Structures Written Exam Proposed SOLUTION

Randy Hyde s Win32 Assembly Language Tutorials (Featuring HOWL) #4: Radio Buttons

Object Oriented Software Design

A Pattern-Based Comparison of OpenACC & OpenMP for Accelerators

The Interface Concept

Chapter 6: Programming Languages

CmpSci 187: Programming with Data Structures Spring 2015

Object Oriented Software Design

AP Computer Science A 2004 Free-Response Questions

Software Engineering Techniques

Affdex SDK for Android. Developer Guide For SDK version 1.0

An Incomplete C++ Primer. University of Wyoming MA 5310

An Overview of Java. overview-1

Textbook: T. Issariyakul and E. Hossain, Introduction to Network Simulator NS2, Springer

Stack vs. Heap. Introduction to Programming. How the Stack Works. Primitive vs. Reference Types. Stack

MULTIPLE CHOICE. Choose the one alternative that best completes the statement or answers the question.

JAVA - MULTITHREADING

Building Java Programs

Scanner. It takes input and splits it into a sequence of tokens. A token is a group of characters which form some unit.

Classes and Objects. Agenda. Quiz 7/1/2008. The Background of the Object-Oriented Approach. Class. Object. Package and import

ID TECH UniMag Android SDK User Manual

AP Computer Science Java Subset

MIDTERM 1 REVIEW WRITING CODE POSSIBLE SOLUTION

How to develop your own app

Mobile Solutions for Data Collection. Sarah Croft and Laura Pierik

Pemrograman Dasar. Basic Elements Of Java

Masters programmes in Computer Science and Information Systems. Object-Oriented Design and Programming. Sample module entry test xxth December 2013

08 BPMN/1. Software Technology 2. MSc in Communication Sciences Program in Technologies for Human Communication Davide Eynard

Using NetBeans IDE to Build Quick UI s Ray Hylock, GISo Tutorial 3/8/2011

Contents. 9-1 Copyright (c) N. Afshartous

Facebook Twitter YouTube Google Plus Website

Crash Course in Java


Course: Programming II - Abstract Data Types. The ADT Queue. (Bobby, Joe, Sue, Ellen) Add(Ellen) Delete( ) The ADT Queues Slide Number 1

Author: Sascha Wolski Sebastian Hennebrueder Tutorials for Struts, EJB, xdoclet and eclipse.

java Features Version April 19, 2013 by Thorsten Kracht

Example of a Java program

Reading Input From A File

Java Memory Model: Content

Moving from CS 61A Scheme to CS 61B Java

Arrays. Atul Prakash Readings: Chapter 10, Downey Sun s Java tutorial on Arrays:

Outline. Computer Science 331. Stack ADT. Definition of a Stack ADT. Stacks. Parenthesis Matching. Mike Jacobson

Modeling Kahn Process Networks in the Dynamic Dataflow Formalism

Deadlock Victim. dimanche 6 mai 12

Evolutionary SAT Solver (ESS)

You are to simulate the process by making a record of the balls chosen, in the sequence in which they are chosen. Typical output for a run would be:

Advanced Multiprocessor Programming

CMSC 202H. ArrayList, Multidimensional Arrays

Programming Without a Call Stack: Event-driven Architectures

Hoare-Style Monitors for Java

It has a parameter list Account(String n, double b) in the creation of an instance of this class.

CS170 Lab 11 Abstract Data Types & Objects

Transcription:

GENERATION OF EPC BASED SIMULATION MODELS Prof. Dr. Christian Müller Department of Management and Business Computing Technical University of Applied Sciences Wildau Bahnhofstrasse, D-15745 Wildau, Germany christian.mueller@th-wildau.de EURO 2012 Vilnius, Lithuania 8-11 July 2012 Generation Of Epc Based Simulation Models - 1 -

Introduction Simulation of Business Processes Business Process Model generate Discrete Event Simulation Model Tools: EPC: BPMN: bflow Activity Open Source Agenda Concept Describing Simulation Models with Epc Model Extensions Fazit Tools: Desmo-J, Ptolemy, Omnet++, C++SIM,... Generation Of Epc Based Simulation Models - 2 -

Concept Generation Of Epc Based Simulation Models - 3 -

Simulation Process Model /ECMS/Demo/Model.epc /ECMS/Demo/Customer.epc Generation Of Epc Based Simulation Models - 4 -

Generate Desmo-J Simulation Generation Of Epc Based Simulation Models - 5 -

Run Desmo-J Simulation Generation Of Epc Based Simulation Models - 6 -

Model Epc /ECMS/Demo/Model.epc /ECMS/Demo/Customer.epc Generation Of Epc Based Simulation Models - 7 -

Epc Basic Generation Of Epc Based Simulation Models - 8 -

XOR Decisions Generation Of Epc Based Simulation Models - 9 -

Loops Generation Of Epc Based Simulation Models - 10 -

Parallel Processing I Generation Of Epc Based Simulation Models - 11 -

Parallel Processing II clone split split split interrupt wait join join synchronize join synchronize Split Join (normal) Join (interrupted) Generation Of Epc Based Simulation Models - 12 -

Model Extensions Customer: Shopping list Supermarket: Inventory management Generation Of Epc Based Simulation Models - 13 -

The generated simulation model must be extended generated Manual extensions model.demo Model.java x Inventory list Master_customer.java x Shopping list Slave_cashier.java x Rule_cashier.java x Logic_Customer.java x Epc_Customer.java x Product choosing function model.demo.myextensions ArticleShop.java Article in inventory list ArticleCustomer.java Article in shopping list Generation Of Epc Based Simulation Models - 14 -

@Generated(value = { "RememberCode", "yes" ) public class Model extends ModelAnimation { //@@_begin of declaration individual code public Map<Long, ArticleShop> myext_inventorylist = null; //@@_end of declaration individual code public Model(String name, CmdGeneration cmdgen, boolean showinreport, boolean showintrace, boolean showinanimation) { //some generated constructor code //@@_begin of constructor individual code // initialize inventory list this.myext_inventorylist = new HashMap<Long, ArtikelShop>(); for(long i=0; i<1000; i++){ ArticleShop article = new ArticleShop(); article.name = "Article_"+i; article.nr = i; article.inventory = 100.0; this.myext_inventorylist.put(i, article); //@@_end of constructor individual code //some other generated methods public class ArticleShop { public long nr; public String name; public double inventory; Generation Of Epc Based Simulation Models - 15 -

@Generated(value = { "RememberCode", "yes" ) public class Master_customer extends EpcProcess { //@@_begin of declaration individual code public Map<Long, ArtikelCustomer> myext_shoppinglist = null; //@@_end of declaration individual code public Master_customer(Model model, String name, EpcProcess parent, EPC_interface epc){ //@@_begin of constructor individual code // initialize shopping list this.myext_shoppinglist = new HashMap<Long, ArticleCustomer>(); int countarticle = model.myext_inventorylist.size(); DiscreteDistUniform randomarticle = new DiscreteDistUniform(model,...); for(int i=0; i<10; i++){ long articlenr = randomarticle.sample(); String articlename = model.myext_inventorylist.get(articlenr).name; if(this.myext_shoppinglist.containskey(articlenr)){ this.myext_shoppinglist.get(articlenr).demand += 1.0; else{ ArticleCustomer article = new ArticleCustomer(); article.nr = articlenr; article.name = articlename; article.demand = 1.0; this.myext_shoppinglist.put(articlenr, article); //@@_end of constructor individual code public class ArticleCustomer { public long nr; public String name; public double demand; Generation Of Epc Based Simulation Models - 16 -

@Generated(value = { "RememberCode", "yes" ) public class Epc_Customer extends Logic_Customer{ /** * Type: epc:function * Name: product_choosing * Resources: * Id: _id_16_function_product_choosing * EpcFile: /ECMS/Demo1/Customer.epc */ protected void _id_16_function_product_choosing(epcprocess proc, List<EpcResource> resources){ String Duration_TimeUnit = "MINUTES", String Duration_Distribution = "TRIA"; String Duration_Tria_Peak = "30", Duration_Tria_Lower = "5", Duration_Tria_Upper = "60"; //@@_begin of individual code for this method // product_choosing Master_customer customer = (Master_customer) proc; for(long key: customer.myext_shoppinglist.keyset()){ double demand = customer.myext_shoppinglist.get(key).demand; if(model.myext_inventorylist.get(key).inventory >= demand){ model.myext_inventorylist.get(key).inventory -= demand; else{ model.myext_inventorylist.get(key).inventory = 0.0; //@@_end of individual code for this method Generation Of Epc Based Simulation Models - 17 -

Model improvement Choose each article separately Generation Of Epc Based Simulation Models - 18 -

@Generated(value = { "RememberCode", "yes" ) public class Master_customer extends EpcProcess { //@@_begin of declaration individual code public Map<Long, ArtikelCustomer> myext_shoppinglist = null; public Iterator<ArticleCustomer> myext_iterator_shoppinglist; //@@_end of declaration individual code public Master_customer(Model model, String name, EpcProcess parent, EPC_interface epc){ //@@_begin of constructor individual code // initialize shopping list this.myext_shoppinglist = new HashMap<Long, ArticleCustomer>(); int countarticle = model.myext_inventorylist.size(); DiscreteDistUniform randomarticle = new DiscreteDistUniform(model,...); for(int i=0; i<10; i++){ //... this.myext_iterator_shoppinglist = this.myext_shoppinglist.values().iterator(); //@@_end of constructor individual code Generation Of Epc Based Simulation Models - 19 -

@Generated(value = { "RememberCode", "yes" ) public class Epc_Customer extends Logic_Customer{ protected boolean _id_29_event_article choosing_is finished(epcprocess proc){ String Condition = "generate"; boolean out = true; //@@_begin of individual code for this method // check shoppinglist is finnished Master_customer customer = (Master_customer) proc; out =! customer.myext_iterator_shoppinglist.hasnext(); //@@_end of individual code for this method return out; protected boolean _id_30_event_article_choosing_isn_t_finished(epcprocess proc){ String Condition = "generate"; boolean out = false; //@@_begin of individual code for this method // check shoppinglist isn't finnished Master_customer customer = (Master_customer) proc; out = customer.myext_iterator_shoppinglist.hasnext(); //@@_end of individual code for this method return out; Generation Of Epc Based Simulation Models - 20 -

protected void _id_27_function_choose_a article(epcprocess proc, List<EpcResource> resources){ String Duration_TimeUnit = "MINUTES"; String Duration_Distribution = "UNIFORM"; String Duration_Uniform_Lower = "1"; String Duration_Uniform_Upper = "3"; //@@_begin of individual code for this method // choose next article in shopping list Master_customer customer = (Master_customer) proc; ArticleCustomer article = customer.myext_iterator_shoppinglist.next(); double demand = article.demand; if(model.myext_inventorylist.get(article.nr).inventory >= demand){ model.myext_inventorylist.get(article.nr).inventory -= demand; else{ model.myext_inventorylist.get(article.nr).inventory = 0.0; //@@_end of individual code for this method Generation Of Epc Based Simulation Models - 21 -

Fazit A generator build from a EPC model a simulation model. The simulation model is a Java application, based on DesmoJ framework. The simulation model can be manually extended. With this extensions the simulation model isn't restricted by the EPC modeling language Further developments Language extensions Statistical analysis, controlled by EPC attributes Tutorial writing Generation of BPMN based simulation models. See also: http://www.scs-europe.net/conf/ecms2012/ecms2012%20accepted%20papers/ibs_ecms_0028.pdf Generation Of Epc Based Simulation Models - 22 -