Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,13 @@
#
# SPDX-License-Identifier: MIT
# Copyright (c) 2021-present Guillermo Trabes
# ARSLab - Carleton University
# Copyright (c) 2021-present jsoulier
# ARSLab - Carleton University
# Copyright (c) 2021-present Román Cárdenas Rodríguez
# ARSLab - Carleton University
#

cmake_minimum_required(VERSION 3.1)
project(cadmium)
set(CMAKE_CXX_STANDARD 17)
Expand Down
27 changes: 27 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,29 @@
# Contributing to Cadmium 2

We are still working on this.

## License

By contributing to Cadmium 2, you agree that your contributions will be licensed under the MIT License.

All contributions must include appropriate copyright notices and the SPDX license identifier. When adding new files, please include a header comment block like this:

```cpp
/**
* SPDX-License-Identifier: MIT
* Copyright (c) YEAR-present YOUR_NAME
* ARSLab - Carleton University
*/
```

For shell scripts and CMake files, use:

```bash
#
# SPDX-License-Identifier: MIT
# Copyright (c) YEAR-present YOUR_NAME
# ARSLab - Carleton University
#
```

See the [LICENSE](LICENSE) file for the full license text.
6 changes: 6 additions & 0 deletions Doxyfile
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
#
# SPDX-License-Identifier: MIT
# Copyright (c) 2021-present Román Cárdenas Rodríguez
# ARSLab - Carleton University
#

# Doxyfile 1.9.4

# This file describes the settings to be used by the documentation system
Expand Down
706 changes: 32 additions & 674 deletions LICENSE

Large diffs are not rendered by default.

15 changes: 15 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
# Cadmium 2

[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)

Object-Oriented implementation of a PDEVS simulator for C++ 17.
Cadmium 2 is a header-only library for implementing and simulating PDEVS, classic Cell-DEVS, and asymmetric Cell-DEVS models using an object-oriented programming paradigm.

Expand Down Expand Up @@ -29,3 +32,15 @@ The files `example/celldevs_asymm_sir/log.csv` and `example/celldevs_grid_sir/lo

## Building your own Cell-DEVS models
The folder `templates` contains a template project for asymmetric and classic Cell-DEVS models.

## License

Cadmium 2 is licensed under the MIT License. See the [LICENSE](LICENSE) file for details.

Copyright (c) 2021-present Román Cárdenas Rodríguez, Jon Menard, Guillermo Trabes, and jsoulier

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
8 changes: 8 additions & 0 deletions build.sh
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
#
# SPDX-License-Identifier: MIT
# Copyright (c) 2022-present jsoulier
# ARSLab - Carleton University
# Copyright (c) 2022-present Román Cárdenas Rodríguez
# ARSLab - Carleton University
#

echo Downloading all the dependencies...
git submodule update --init --recursive
mkdir build
Expand Down
6 changes: 6 additions & 0 deletions celldevs_examples.sh
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
#
# SPDX-License-Identifier: MIT
# Copyright (c) 2022-present Román Cárdenas Rodríguez
# ARSLab - Carleton University
#

echo Running asymmetric Cell-DEVS example...
cd example/celldevs_sir || exit
../../bin/main_asymm_sir asymm_config.json
Expand Down
8 changes: 8 additions & 0 deletions example/celldevs_benchmark/include/benchmark_grid_cell.hpp
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
/**
* SPDX-License-Identifier: MIT
* Copyright (c) 2022-present Guillermo Trabes
* ARSLab - Carleton University
* Copyright (c) 2022-present Román Cárdenas Rodríguez
* ARSLab - Carleton University
*/

#ifndef CADMIUM_EXAMPLE_CELLDEVS_BENCHMARK_CELL_HPP_
#define CADMIUM_EXAMPLE_CELLDEVS_BENCHMARK_CELL_HPP_

Expand Down
8 changes: 8 additions & 0 deletions example/celldevs_benchmark/include/state.hpp
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
/**
* SPDX-License-Identifier: MIT
* Copyright (c) 2022-present Guillermo Trabes
* ARSLab - Carleton University
* Copyright (c) 2022-present Román Cárdenas Rodríguez
* ARSLab - Carleton University
*/

#ifndef CADMIUM_EXAMPLE_CELLDEVS_BENCHMARK_STATE_HPP_
#define CADMIUM_EXAMPLE_CELLDEVS_BENCHMARK_STATE_HPP_

Expand Down
8 changes: 8 additions & 0 deletions example/celldevs_benchmark/main_grid_benchmark.cpp
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
/**
* SPDX-License-Identifier: MIT
* Copyright (c) 2022-present Guillermo Trabes
* ARSLab - Carleton University
* Copyright (c) 2022-present Román Cárdenas Rodríguez
* ARSLab - Carleton University
*/

#include <cadmium/celldevs/grid/coupled.hpp>
#include <cadmium/core/logger/csv.hpp>
#include <cadmium/core/simulation/root_coordinator.hpp>
Expand Down
6 changes: 6 additions & 0 deletions example/celldevs_sir/include/asymm_sir_cell.hpp
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
/**
* SPDX-License-Identifier: MIT
* Copyright (c) 2022-present Román Cárdenas Rodríguez
* ARSLab - Carleton University
*/

#ifndef CADMIUM_EXAMPLE_CELLDEVS_ASYMM_CELL_HPP_
#define CADMIUM_EXAMPLE_CELLDEVS_ASYMM_CELL_HPP_

Expand Down
6 changes: 6 additions & 0 deletions example/celldevs_sir/include/grid_sir_cell.hpp
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
/**
* SPDX-License-Identifier: MIT
* Copyright (c) 2022-present Román Cárdenas Rodríguez
* ARSLab - Carleton University
*/

#ifndef CADMIUM_EXAMPLE_CELLDEVS_SIR_GRID_CELL_HPP_
#define CADMIUM_EXAMPLE_CELLDEVS_SIR_GRID_CELL_HPP_

Expand Down
6 changes: 6 additions & 0 deletions example/celldevs_sir/include/state.hpp
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
/**
* SPDX-License-Identifier: MIT
* Copyright (c) 2022-present Román Cárdenas Rodríguez
* ARSLab - Carleton University
*/

#ifndef CADMIUM_EXAMPLE_CELLDEVS_SIR_STATE_HPP_
#define CADMIUM_EXAMPLE_CELLDEVS_SIR_STATE_HPP_

Expand Down
6 changes: 6 additions & 0 deletions example/celldevs_sir/main_asymm_sir.cpp
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
/**
* SPDX-License-Identifier: MIT
* Copyright (c) 2022-present Román Cárdenas Rodríguez
* ARSLab - Carleton University
*/

#include <cadmium/celldevs/asymm/coupled.hpp>
#include <cadmium/core/logger/csv.hpp>
#include <cadmium/core/simulation/root_coordinator.hpp>
Expand Down
6 changes: 6 additions & 0 deletions example/celldevs_sir/main_grid_sir.cpp
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
/**
* SPDX-License-Identifier: MIT
* Copyright (c) 2022-present Román Cárdenas Rodríguez
* ARSLab - Carleton University
*/

#include <cadmium/celldevs/grid/coupled.hpp>
#include <cadmium/core/logger/csv.hpp>
#include <cadmium/core/simulation/root_coordinator.hpp>
Expand Down
8 changes: 8 additions & 0 deletions example/celldevs_sir/parallel_main_asymm_sir.cpp
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
/**
* SPDX-License-Identifier: MIT
* Copyright (c) 2022-present Guillermo Trabes
* ARSLab - Carleton University
* Copyright (c) 2022-present Román Cárdenas Rodríguez
* ARSLab - Carleton University
*/

#include <cadmium/celldevs/asymm/coupled.hpp>
#include <cadmium/core/logger/csv.hpp>
#include <cadmium/core/simulation/parallel_root_coordinator.hpp>
Expand Down
8 changes: 8 additions & 0 deletions example/celldevs_sir/parallel_main_grid_sir.cpp
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
/**
* SPDX-License-Identifier: MIT
* Copyright (c) 2022-present Guillermo Trabes
* ARSLab - Carleton University
* Copyright (c) 2022-present Román Cárdenas Rodríguez
* ARSLab - Carleton University
*/

#include <cadmium/celldevs/grid/coupled.hpp>
#include <cadmium/core/logger/csv.hpp>
#include <cadmium/core/simulation/parallel_root_coordinator.hpp>
Expand Down
8 changes: 8 additions & 0 deletions example/devstone/include/devstone.hpp
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
/**
* SPDX-License-Identifier: MIT
* Copyright (c) 2022-present Guillermo Trabes
* ARSLab - Carleton University
* Copyright (c) 2022-present Román Cárdenas Rodríguez
* ARSLab - Carleton University
*/

#ifndef CADMIUM_EXAMPLE_DEVSTONE_HPP_
#define CADMIUM_EXAMPLE_DEVSTONE_HPP_

Expand Down
8 changes: 8 additions & 0 deletions example/devstone/include/devstone_atomic.hpp
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
/**
* SPDX-License-Identifier: MIT
* Copyright (c) 2022-present Guillermo Trabes
* ARSLab - Carleton University
* Copyright (c) 2022-present Román Cárdenas Rodríguez
* ARSLab - Carleton University
*/

#ifndef CADMIUM_EXAMPLE_DEVSTONE_ATOMIC_HPP_
#define CADMIUM_EXAMPLE_DEVSTONE_ATOMIC_HPP_

Expand Down
8 changes: 8 additions & 0 deletions example/devstone/include/devstone_coupled.hpp
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
/**
* SPDX-License-Identifier: MIT
* Copyright (c) 2022-present Guillermo Trabes
* ARSLab - Carleton University
* Copyright (c) 2022-present Román Cárdenas Rodríguez
* ARSLab - Carleton University
*/

#ifndef CADMIUM_EXAMPLE_DEVSTONE_COUPLED_HPP_
#define CADMIUM_EXAMPLE_DEVSTONE_COUPLED_HPP_

Expand Down
8 changes: 8 additions & 0 deletions example/devstone/include/devstone_coupled_hi.hpp
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
/**
* SPDX-License-Identifier: MIT
* Copyright (c) 2022-present Guillermo Trabes
* ARSLab - Carleton University
* Copyright (c) 2022-present Román Cárdenas Rodríguez
* ARSLab - Carleton University
*/

#ifndef CADMIUM_EXAMPLE_DEVSTONE_COUPLED_HI_HPP_
#define CADMIUM_EXAMPLE_DEVSTONE_COUPLED_HI_HPP_

Expand Down
8 changes: 8 additions & 0 deletions example/devstone/include/devstone_coupled_ho.hpp
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
/**
* SPDX-License-Identifier: MIT
* Copyright (c) 2022-present Guillermo Trabes
* ARSLab - Carleton University
* Copyright (c) 2022-present Román Cárdenas Rodríguez
* ARSLab - Carleton University
*/

#ifndef CADMIUM_EXAMPLE_DEVSTONE_COUPLED_HO_HPP_
#define CADMIUM_EXAMPLE_DEVSTONE_COUPLED_HO_HPP_

Expand Down
8 changes: 8 additions & 0 deletions example/devstone/include/devstone_coupled_homod.hpp
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
/**
* SPDX-License-Identifier: MIT
* Copyright (c) 2022-present Guillermo Trabes
* ARSLab - Carleton University
* Copyright (c) 2022-present Román Cárdenas Rodríguez
* ARSLab - Carleton University
*/

#ifndef CADMIUM_EXAMPLE_DEVSTONE_COUPLED_HOMOD_HPP_
#define CADMIUM_EXAMPLE_DEVSTONE_COUPLED_HOMOD_HPP_

Expand Down
8 changes: 8 additions & 0 deletions example/devstone/include/devstone_coupled_li.hpp
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
/**
* SPDX-License-Identifier: MIT
* Copyright (c) 2022-present Guillermo Trabes
* ARSLab - Carleton University
* Copyright (c) 2022-present Román Cárdenas Rodríguez
* ARSLab - Carleton University
*/

#ifndef CADMIUM_EXAMPLE_DEVSTONE_COUPLED_LI_HPP_
#define CADMIUM_EXAMPLE_DEVSTONE_COUPLED_LI_HPP_

Expand Down
8 changes: 8 additions & 0 deletions example/devstone/include/devstone_generator.hpp
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
/**
* SPDX-License-Identifier: MIT
* Copyright (c) 2022-present Guillermo Trabes
* ARSLab - Carleton University
* Copyright (c) 2022-present Román Cárdenas Rodríguez
* ARSLab - Carleton University
*/

#ifndef CADMIUM_EXAMPLE_DEVSTONE_GENERATOR_HPP_
#define CADMIUM_EXAMPLE_DEVSTONE_GENERATOR_HPP_

Expand Down
8 changes: 8 additions & 0 deletions example/devstone/include/dhrystone.hpp
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
/**
* SPDX-License-Identifier: MIT
* Copyright (c) 2022-present Guillermo Trabes
* ARSLab - Carleton University
* Copyright (c) 2022-present Román Cárdenas Rodríguez
* ARSLab - Carleton University
*/

#ifndef CADMIUM_EXAMPLE_DEVSTONE_DHRYSTONE_HPP_
#define CADMIUM_EXAMPLE_DEVSTONE_DHRYSTONE_HPP_

Expand Down
8 changes: 8 additions & 0 deletions example/devstone/main_devstone.cpp
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
/**
* SPDX-License-Identifier: MIT
* Copyright (c) 2022-present Guillermo Trabes
* ARSLab - Carleton University
* Copyright (c) 2022-present Román Cárdenas Rodríguez
* ARSLab - Carleton University
*/

#include <chrono>
#include <iostream>
#include <string>
Expand Down
8 changes: 8 additions & 0 deletions example/devstone/main_flat_devstone.cpp
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
/**
* SPDX-License-Identifier: MIT
* Copyright (c) 2022-present Guillermo Trabes
* ARSLab - Carleton University
* Copyright (c) 2022-present Román Cárdenas Rodríguez
* ARSLab - Carleton University
*/

#include <chrono>
#include <iostream>
#include <string>
Expand Down
8 changes: 8 additions & 0 deletions example/devstone/parallel_main_devstone.cpp
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
/**
* SPDX-License-Identifier: MIT
* Copyright (c) 2022-present Guillermo Trabes
* ARSLab - Carleton University
* Copyright (c) 2022-present Román Cárdenas Rodríguez
* ARSLab - Carleton University
*/

#include <chrono>
#include <iostream>
#include <string>
Expand Down
8 changes: 8 additions & 0 deletions example/devstone/src/devstone.cpp
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
/**
* SPDX-License-Identifier: MIT
* Copyright (c) 2022-present Guillermo Trabes
* ARSLab - Carleton University
* Copyright (c) 2022-present Román Cárdenas Rodríguez
* ARSLab - Carleton University
*/

#include <string>
#include "devstone.hpp"
#include "devstone_coupled.hpp"
Expand Down
8 changes: 8 additions & 0 deletions example/devstone/src/devstone_atomic.cpp
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
/**
* SPDX-License-Identifier: MIT
* Copyright (c) 2022-present Guillermo Trabes
* ARSLab - Carleton University
* Copyright (c) 2022-present Román Cárdenas Rodríguez
* ARSLab - Carleton University
*/

#include <iostream>
#include <limits>
#include "devstone_atomic.hpp"
Expand Down
8 changes: 8 additions & 0 deletions example/devstone/src/devstone_coupled.cpp
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
/**
* SPDX-License-Identifier: MIT
* Copyright (c) 2022-present Guillermo Trabes
* ARSLab - Carleton University
* Copyright (c) 2022-present Román Cárdenas Rodríguez
* ARSLab - Carleton University
*/

#include <string>
#include "devstone_atomic.hpp"
#include "devstone_coupled.hpp"
Expand Down
Loading
Loading