SCALAble SimulaTION  ScalaTion
Papers  Scaladoc  Source Code
Welcome to ScalaTion, the Scalabased system for Simulation, Optimization and Analytics.
This system, coded in Scala, supports multiparadigm simulation modeling including 'tableau', 'event', 'process', 'dynamics', 'dynamics_pde', 'activity' and 'state' oriented models.
Scala is a modern objectoriented, functional programming language that is wellsuited for developing simulation engines. It is in the Java family of languages and can call Java code. The inclusion of advanced and functional programming capabilities, makes the code much more concise than Java. ScalaTion also supports optimization and analytics as they nowadays go handinhand with simulation modeling. Some of the algorithms come in both sequential and parallel versions.
The ScalaTion 1.4 version defines multiple .par subpackages that contain parallel versions of sequential algorithms. Future directions include completing the 'scala3d' and 'physics' packages.
As of version 1.4, ScalaTion consists of 4 subprojects: scalation_mathstat, scalation_database, scalation_modeling and scalation_models
Please read the LICENSE file (an MIT style license).
Installation Instructions
Requires:
Scala 2.12.x and
Java 8
Recommended:
sbt
(see Setup.html)
1. Download one of the following two files
scalation_1.4.tar.gz
OR
scalation_1.4.zip
2. Untar or unzip the file
$ tar xvfz scalation_1.4.tar.gz
OR
$ unzip scalation_1.4.zip
3. To compile code or run apps, enter sbt and type compile, runMain or exit
$ cd scalation_1.4
$ cd scalation_models
$ sbt
> compile
> runMain apps.process.Bank
> runMain scalation.analytics.RegressionTest
> exit
ScalaTion 1.4 is set up to use the Simple Build Tool sbt.
ScalaTion 1.4 uses the following build specification files build.sbt, build.sbt and build.sbt. Source packages are in the src/main/scala directory, class files are in the target/scala2.12/classes directory, and documentation files are in the target/scala2.12/api directory. Data file input, output or analytics are stored in subdirectories of data, while database files are stored in store.
To develop using an IDE:
 Download Scala IDE for Eclipse
 Extract the downloaded .zip/.tar.gz file
 Start eclipse by running the eclipse command or clicking eclipse application from the file manager
 Create and run HelloWorld.scala, see tutorial
For more information about the source code, see src/README_src.hmtl.
Papers/Documentation

John A. Miller, Jun Han and Maria Hybinette,
"Using Domain Specific Languages for Modeling and Simulation: ScalaTion as a Case Study,"
Proceedings of the 2010 ACM/IEEE Winter Simulation Conference (WSC'10),
Baltimore, Maryland (December 2010) pp. 741752.

Michael E. Cotterell, John A. Miller, Tom Horton,
"Unicode in DomainSpecific Programming Languages for Modeling & Simulation:
ScalaTion as a Case Study,"
Arxiv preprint arXiv:1112.175
(December 2011) pp. 110.

Michael E. Cotterell, John A. Miller, Jun Han and Tom Horton,
"Extending ScalaTion, a DomainSpecific Language for Modeling & Simulation, for Simulation Optimization,"
Proceedings of the AlaSim International Modeling and Simulation Conference & Exhibition (AlaSim'12),
Huntsville, Alabama (May 2012) pp. 11.

Yung Long Li,
"Evaluation of Parallel Implementations of Dense and Sparse
Matrices for the ScalaTion Library,"
Technical Report,
University of Georgia (December 2012) pp. 160.

John A. Miller, Michael E. Cotterell and Stephen J. Buckley,
"Supporting a Modeling Continuum in ScalaTion: From Predictive Analytics to Simulation Modeling,"
Proceedings of the 2013 ACM/IEEE Winter Simulation Conference (WSC'13),
Washington, DC (December 2013) pp. 11911202.

Matthew Saltz, Ayushi Jain, Abhishek Kothari, Arash Fard, John A. Miller, and Lakshmish Ramaswamy,
"DualIso: An Algorithm for Subgraph Pattern Matching on Very Large Labeled Graphs,"
Proceedings of the 3rd IEEE International Congress on Big Data
(BigData'14),
Anchorage, Alaska (JuneJuly 2014) pp. 498505.
Online supplement
Source Packages (doc)
Package Description MATH AND STAT scalation.plot The `plot` package contains classes, traits and objects for simple plotting of xy data. scalation.scala2d The `scala2d` package contains classes, traits and objects for for simple 2D graphics in scala, based upon `java.swing`, `java.awt` and `java_awt_geom`. scalation.linalgebra The `linalgebra` package contains classes, traits and objects for linear algebra, including vectors and matrices for real and complex numbers.  scalation.linalgebra.mem_mapped The `mem_mapped` package contains classes, traits and objects for outofcore linear algebra, including vectors and matrices for real and complex numbers.   scalation.linalgebra.mem_mapped.bld The `bld` package contains traits and objects for generating source code for outofcore vector classes, matrix traits and matrix classes.  scalation.linalgebra.bld The `bld` package contains traits and objects for generating source code for vector classes, matrix traits and matrix classes.  scalation.linalgebra.gen The `gen` package contains generic classes, traits and objects for linear algebra, including vectors and matrices for types implementing `Numeric`. Tend to run more slowly than the specialized versions in `linalgebra`.  scalation.linalgebra.par The `par` package contains classes, traits and objects for parallel linear algebra, including vectors and matrices for real and complex numbers. scalation.random The `random` package contains classes, traits and objects for the generation of random numbers. scalation.stat The `stat` package contains classes, traits and objects for basic statistical functions and analyses. The package object itself defines an implicit conversion from `scalation.linalgebra.VectorD` to `StatVector`. scalation.par The `par` package contains classes, traits and objects for parallel processing techniques such as MapReduce. scalation.util The `util` package contains classes, traits and objects for basic utility functions.  scalation.util.bld The `bld` package contains traits and objects for generating source code for memory mapped arrays. scalation.math The `math` package contains classes, traits and objects for common mathematical operations. Its package object defines exponentiation, logarithmic, trigonometric, etc. operators and functions. DATABASE scalation.graphalytics The `graphalytics` package contains classes, traits and objects for graph analytics on Trees, 'DAG's and Directed Graphs. It provides an implicit conversion when needed for converting doubles to vectors. scalation.columnar_db The `columar_db` package contains classes, traits and objects for columnar relational algebra, where columns are vectors from the `linalgebra` package. scalation.graph_db The `graph_db` package contains classes, traits and objects for graph analytics on Trees, 'DAG's and Directed Graphs. It provides an implicit conversion when needed for converting doubles to vectors.  scalation.graph_db.graph_algebra The `graph_algebra` package provide graph algebra operators.  scalation.graph_db.pattern_matching The `pattern_matching` package contains classes, traits and objects for graph pattern matching such as graph simulation and subgraph isomorphism.   scalation.graph_db.pattern_matching.test The `test` package contains classes for testing graph pattern matching algorithms. MODELING scalation.physics The `physics` package contains classes, traits and objects for for simulation oriented games. It utilizes ODE and PDE solvers from the scalation package to move objects in either 2D or 3D canvases/scene graphs. @see buildnewgames.com/gamephysics/ scalation.model The `model` package contains a trait giving a template for models to follow. scalation.calculus The `calculus` package contains classes with methods for computing derivatives, gradient vectors, Jacobian matrices, integrals and basic operators in Functional Analysis. scalation.dynamics The `dynamics` package contains classes, traits and objects for system dynamics simulations using Ordinary Differential Equations (ODEs). scalation.event The `event` package contains classes, traits and objects for event oriented simulation models (for example, event scheduling or event graphs). scalation.dynamics_pde The `dynamics_pde` package contains classes, traits and objects for system dynamics simulations using Partial Differential Equations 'PDE's. scalation.minima The `minima` package contains classes, traits and objects for optimization to find minima. scalation.activity The `activity` package contains classes, traits and objects for activityoriented simulation models (for example, Petri Nets). scalation.state The `state` package contains classes, traits and objects for stateoriented simulation models (for example, Markov Chains). scalation.animation The `animation` package contains classes, traits and objects for 2D animation of simulation objects. scalation.analytics The `analytics` package contains classes, traits and objects for analytics including clustering and prediction.  scalation.analytics.classifier The analytics package contains classes, traits and objects for analytics focused on classification.   scalation.analytics.classifier.par The par package contains classes, traits and objects for analytics including classification, clustering and prediction with parallel implementations.  scalation.analytics.clusterer The `clusterer` package contains classes, traits and objects for clustering algorithms.  scalation.analytics.recommender The `recommender` package contains classes, traits and objects of recommendation systems.  scalation.analytics.par The `par` package contains classes, traits and objects for parallel analytics including clustering and prediction.  scalation.analytics.fda The `fda` package contains classes, traits and objects for Functional Data Analysis (FDA). scalation.tableau The `tableau` package contains classes for tableau oriented simulation models (similar to spreadsheet simulations). scalation.queueingnet The `queueingnet` package contains classes, traits and objects for solving simple queueing network problems. scalation.process The `process` package contains classes, traits and objects for processoriented simulation models (for example, processinteraction). scalation.maxima The `maxima` package contains classes, traits and objects for optimization to find maxima. scalation.scala3d The `scala3d` package contains classes, traits and objects for for simple 3D graphics in scala, based upon javafx. Its package object contains type aliases for 'javafx.geometry.Point3D' and all subclasses of 'javafx.scene.shape.Shape3D'. APPLICATIONS apps.simopt The `simopt` package contains example applications for simulation optimization. apps.montecarlo The `montecarlo` package contains example applications for Monte Carlo Simulation. apps.dynamics The `dynamics` package contains example applications for continuous simulation models based on Ordinary Differential Equations 'ODE's or Partial Differential Equations 'PDE's. apps.event The `event` package contains example applications for event oriented simulation models. apps.game The `game` package contains example applications for simulation oriented games. apps.database The `database` package contains applications of databases. apps.optimization The `optimization` package contains example applications for finding solutions (minima or maxima) to optimization problems. apps.activity The `activity` package contains example applications for activity oriented simulation models. apps.state The `state` package contains example applications for state oriented simulation models. apps.analytics The `analytics` package contains example applications for analytics: prediction, classification or clustering. apps.tableau The `tableau` package contains example applications for tableau oriented simulation models. apps.process The `process` package contains example applications for process oriented simulation models.
Source Packages (src)
Package Description MATH AND STAT scalation.plot The `plot` package contains classes, traits and objects for simple plotting of xy data. scalation.scala2d The `scala2d` package contains classes, traits and objects for for simple 2D graphics in scala, based upon `java.swing`, `java.awt` and `java_awt_geom`. scalation.linalgebra The `linalgebra` package contains classes, traits and objects for linear algebra, including vectors and matrices for real and complex numbers.  scalation.linalgebra.mem_mapped The `mem_mapped` package contains classes, traits and objects for outofcore linear algebra, including vectors and matrices for real and complex numbers.   scalation.linalgebra.mem_mapped.bld The `bld` package contains traits and objects for generating source code for outofcore vector classes, matrix traits and matrix classes.  scalation.linalgebra.bld The `bld` package contains traits and objects for generating source code for vector classes, matrix traits and matrix classes.  scalation.linalgebra.gen The `gen` package contains generic classes, traits and objects for linear algebra, including vectors and matrices for types implementing `Numeric`. Tend to run more slowly than the specialized versions in `linalgebra`.  scalation.linalgebra.par The `par` package contains classes, traits and objects for parallel linear algebra, including vectors and matrices for real and complex numbers. scalation.random The `random` package contains classes, traits and objects for the generation of random numbers. scalation.stat The `stat` package contains classes, traits and objects for basic statistical functions and analyses. The package object itself defines an implicit conversion from `scalation.linalgebra.VectorD` to `StatVector`. scalation.par The `par` package contains classes, traits and objects for parallel processing techniques such as MapReduce. scalation.util The `util` package contains classes, traits and objects for basic utility functions.  scalation.util.bld The `bld` package contains traits and objects for generating source code for memory mapped arrays. scalation.math The `math` package contains classes, traits and objects for common mathematical operations. Its package object defines exponentiation, logarithmic, trigonometric, etc. operators and functions. DATABASE scalation.graphalytics The `graphalytics` package contains classes, traits and objects for graph analytics on Trees, 'DAG's and Directed Graphs. It provides an implicit conversion when needed for converting doubles to vectors. scalation.columnar_db The `columar_db` package contains classes, traits and objects for columnar relational algebra, where columns are vectors from the `linalgebra` package. scalation.graph_db The `graph_db` package contains classes, traits and objects for graph analytics on Trees, 'DAG's and Directed Graphs. It provides an implicit conversion when needed for converting doubles to vectors.  scalation.graph_db.graph_algebra The `graph_algebra` package provide graph algebra operators.  scalation.graph_db.pattern_matching The `pattern_matching` package contains classes, traits and objects for graph pattern matching such as graph simulation and subgraph isomorphism.   scalation.graph_db.pattern_matching.test The `test` package contains classes for testing graph pattern matching algorithms. MODELING scalation.physics The `physics` package contains classes, traits and objects for for simulation oriented games. It utilizes ODE and PDE solvers from the scalation package to move objects in either 2D or 3D canvases/scene graphs. @see buildnewgames.com/gamephysics/ scalation.model The `model` package contains a trait giving a template for models to follow. scalation.calculus The `calculus` package contains classes with methods for computing derivatives, gradient vectors, Jacobian matrices, integrals and basic operators in Functional Analysis. scalation.dynamics The `dynamics` package contains classes, traits and objects for system dynamics simulations using Ordinary Differential Equations (ODEs). scalation.event The `event` package contains classes, traits and objects for event oriented simulation models (for example, event scheduling or event graphs). scalation.dynamics_pde The `dynamics_pde` package contains classes, traits and objects for system dynamics simulations using Partial Differential Equations 'PDE's. scalation.minima The `minima` package contains classes, traits and objects for optimization to find minima. scalation.activity The `activity` package contains classes, traits and objects for activityoriented simulation models (for example, Petri Nets). scalation.state The `state` package contains classes, traits and objects for stateoriented simulation models (for example, Markov Chains). scalation.animation The `animation` package contains classes, traits and objects for 2D animation of simulation objects. scalation.analytics The `analytics` package contains classes, traits and objects for analytics including clustering and prediction.  scalation.analytics.classifier The analytics package contains classes, traits and objects for analytics focused on classification.   scalation.analytics.classifier.par The par package contains classes, traits and objects for analytics including classification, clustering and prediction with parallel implementations.  scalation.analytics.clusterer The `clusterer` package contains classes, traits and objects for clustering algorithms.  scalation.analytics.recommender The `recommender` package contains classes, traits and objects of recommendation systems.  scalation.analytics.par The `par` package contains classes, traits and objects for parallel analytics including clustering and prediction.  scalation.analytics.fda The `fda` package contains classes, traits and objects for Functional Data Analysis (FDA). scalation.tableau The `tableau` package contains classes for tableau oriented simulation models (similar to spreadsheet simulations). scalation.queueingnet The `queueingnet` package contains classes, traits and objects for solving simple queueing network problems. scalation.process The `process` package contains classes, traits and objects for processoriented simulation models (for example, processinteraction). scalation.maxima The `maxima` package contains classes, traits and objects for optimization to find maxima. scalation.scala3d The `scala3d` package contains classes, traits and objects for for simple 3D graphics in scala, based upon javafx. Its package object contains type aliases for 'javafx.geometry.Point3D' and all subclasses of 'javafx.scene.shape.Shape3D'. APPLICATIONS apps.simopt The `simopt` package contains example applications for simulation optimization. apps.montecarlo The `montecarlo` package contains example applications for Monte Carlo Simulation. apps.dynamics The `dynamics` package contains example applications for continuous simulation models based on Ordinary Differential Equations 'ODE's or Partial Differential Equations 'PDE's. apps.event The `event` package contains example applications for event oriented simulation models. apps.game The `game` package contains example applications for simulation oriented games. apps.database The `database` package contains applications of databases. apps.optimization The `optimization` package contains example applications for finding solutions (minima or maxima) to optimization problems. apps.activity The `activity` package contains example applications for activity oriented simulation models. apps.state The `state` package contains example applications for state oriented simulation models. apps.analytics The `analytics` package contains example applications for analytics: prediction, classification or clustering. apps.tableau The `tableau` package contains example applications for tableau oriented simulation models. apps.process The `process` package contains example applications for process oriented simulation models. MATH AND STAT UNIT TESTS testing.linalgebra Unit tests for the `linalgebra` package. testing.stat Unit tests for the `stat` package.
Code Release Process
$ cd scalation_1.4
$ cd scalation_mathstat
$ sbt
> compile
> package
> test
> runMain scalation.util.RunSpellCheck 'packagedirectory'
> runMain scalation.GenIndexHtml
> clean
> doc
> exit
Similarly for scalation_modeling and scalation_models. Currently the .jar files need to be copied (copy_jars.sh) into the lib directory of dependent subprojects.
讨论区