1 / 43

Web-based Simulation

Web-based Simulation. Course: 60-520 Instructor: Dr. A.K. Aggarwal By Sheng Bai. Agenda. Introduction Client-based Server-based Distributed Summary Reference. What ’ s Simulation. Building a software Based on an algorithmic logic Simulate some phenomenon With some purpose

demi
Download Presentation

Web-based Simulation

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Web-based Simulation Course: 60-520 Instructor: Dr. A.K. Aggarwal By Sheng Bai

  2. Agenda • Introduction • Client-based • Server-based • Distributed • Summary • Reference

  3. What’s Simulation • Building a software • Based on an algorithmic logic • Simulate some phenomenon • With some purpose • Observing systems • Finding analytical solutions • Predicting system behaviors

  4. Types of simulation • Stochastic or deterministic • Continuous or discrete • Local or distributed

  5. Web-based Simulation • A driver of software technologies • A rapidly emerging area • WEBSIM; • Winter Simulation Conference Sessions; • WSC Modeling Methodology Track; • Java

  6. Classification • Client-based • Server-based • Distributed

  7. Client-based • Browser & Server Structure • Download logic to client side • Running and analyzing on client’s side • No communications during the simulation • Implementation: simjava

  8. simjava • A discrete event simulation package • A Java port of a C++ library, HASE++ • HASE++ is based on Jade’s SIM++

  9. A collection of entities: Sim_entity Entities are connected by ports: Sim_port Communication via using event objects: Sim_event Central controller: Sim_system

  10. Process .initialize() Sim_system.add() Sim_system Sim_system.add() Sim_entity Sim_entity Sim_port Source Sink Sim_port out in Sim_system.link_ports ("Sender", "out", "Receiver", "in"); Sim_system.run()

  11. Animation • Package: simanim; • Class: Anim_applet; • Method: Anim_applet.anim_init(); • Driven by trace output of simulation • S traces • P traces

  12. Demonstration

  13. Analyzing simulation results • Package: simdiag • Java Beans: • TimingDiagram • TraceSaver • TraceLoader • GraphDiagram

  14. TimingDiagram • Stat timing window in anim_init() • Attach to a trace saver • A TraceEventObject • Trace line • A command: • TRACE; LAYOUT; RUN; PAUSE; STOP; DISPLAY

  15. Example trace File $types State IDLE BUSY SEND RECV $bars p[0] State p[1] State $events u:p[0] at 1.234: P IDLE u:p[1] at 4.567: P BUSY ...

  16. TimingDiagram

  17. GraphDiagram

  18. GraphDiagram

  19. Problems • Take time to download • Unsteady performance • Can’t run sophisticate simulations

  20. Server side • RMI (Remote Method Invocation) • Distributed simjava • EJB (Enterprise JavaBeans) • JSIM

  21. RMI Architecture

  22. Process Server User Machine RMI Runtime Sim_system.link_ports ("Sender", "out", "Receiver", "in") Source Sink Web Browser Sim_system.add() implements Sim_systemRI Sim_system.add() Client Applet Sim_system Sim_systemRI java.rmi.Remote

  23. EJBs • Independence form messaging middleware, transaction support, naming & directory services… • Delegates difficult tasks to EJB server • Simplify application development

  24. Client-Server Interaction

  25. JSIM Architecture

  26. Simulation process

  27. Distributed system • EJB solution has all the tradition weakness • Reuse • Collaborate

  28. Standardization • High Level Architecture (DoD) • Components based Architecture • Runtime infrastructure (RTI) • Federation management • Declaration management • Object management • Ownership management • Time management • Data distribution management

  29. Solution: Jini & XML + JSIM • Jini: a universal network-computing model • XML: a universal format for data exchange

  30. Jini • Java dynamic networking • Distributed, highly adaptive to change • Open software • Originally created by Sun Microsystems • Contributed to Jini Community in 1999

  31. Jini Architecture

  32. Infrastructure • Distributed security • Integrated into RMI, • extends to world of distributed systems • Discovery/Join protocol • Allows services to discover, advertise • Lookup service • A repository of services

  33. Programming Model • Leasing interface • Allocating and Freeing resources • Event and notification interface • Enabling Event-based communication • Transaction interface • Ensuring properly coordination of state changes.

  34. Services • Builds on top of Infrastructure • Has an interface defining its operations • Both user and program oriented • Examples: • A printing service • A JavaSpaces service • A transaction manager

  35. 1. Discovery

  36. 2. Join

  37. 3. Lookup

  38. Process4: Invoke

  39. XML • Self-descriptive, text-based, universal • Two ways to access XML documents • Element level: standard APIs • Simple APIs for XML (SAX): efficient • Document Object Model (DOM): flexible • Object level: programmatic manipulation • Java XML Data Binding project (Sun) • Dynamic XML (Object Space)

  40. JSIM Federated Simulation with Jini and XML

  41. Summary • Three types • A young discipline • Reuse of existing simulation models • Federated is the most promising one

  42. Reference • [1] Xeuqin Huang and John A. Miller, "Building a Web-Based Federated Simulation System with Jini and XML," Proceedings of the 34th Annual Simulation Symposium (ANSS'01), Seattle, Washington, United States, April 2001 • [2] Z.Y. Du, “LBSim: A Simulation System for Dynamic Load-Balancing Algorithms for Distributed Systems”, Technical Report in University of Windsor, Canada, 2004. • [3] John A. Miller, Andrew F. Seila and Xuewei Xiang, "The JSIM Web-Based Simulation Environment," Future Generation Computer Systems (FGCS), Special Issue on Web-Based Modeling and Simulation, Vol. 17, No. 2 (October 2000) pp. 119-133. Elsevier North-Holland. • [4] Ernest H. Page, Robert L. Moose Jr. and Sean P. Griffn, “Web-based simulation in simjava using remote method invocation”, Proceedings of the 29th conference on Winter simulation Atlanta, Georgia, United States, 1997 • [5] Fred Howell and Ross McNab "simjava: a discrete event simulation package for Java with applications in computer systems modelling", in proc. First International Conference on Web-based Modelling and Simulation, San Diego CA, Society for Computer Simulation, Jan 1998.

  43. Questions?

More Related