se-lib

From Wikipedia, the free encyclopedia
se-lib
Original author(s)Ray Madachy
Developer(s)Ryan Longshore
Initial releaseNovember 30, 2022 (2022-11-30)
Stable release
0.27.4 / October 19, 2023; 6 months ago (2023-10-19)
Written inPython
Operating systemCross-platform
TypeSystems Modeling
LicenseMIT
Websitese-lib.org

The Systems Engineering Library (se-lib) is a free and open-source library written in Python. Current capabilities for systems modeling include SysML and UML textual notation and diagrams, other modeling diagram types, time-based simulation including discrete-event simulation and continuous systems modeling with system dynamics, system reliability modeling, system cost modeling, and systems engineering process and project management. It is interoperable with other modeling tools.

Overview[edit]

The goals of se-lib are to [1]:

  • Lower access barrier to system modeling with open source tool environment.
  • Provide integrated capabilities for systems modeling, analysis, and documentation
  • Be digital engineering compliant.
  • Compatibility with other modeling tools and libraries
  • Compatibility of everything on desktop and cloud platforms

se-lib development has been supported by the Naval Postgraduate School Foundation for critical technologies and education programs [2]. As a seed project it was funded for "adoption of engineers across disciplines in support of digital engineering practice, teaching and research in the DOD".

It has been used in graduate courses for modeling and simulation, capability engineering, and systems software engineering at Naval Postgraduate School. se-lib has also been used for masters's capstone projects and research deliverables. It has been the subject of professional training venues for systems engineers with the International Council on Systems Engineering [3].

The Boehm Center for Systems and Software Engineering is a cooperating organization [4]. The se-lib system cost models in particular have been featured and transitioned through the Center.

se-lib was originally called the Python Modeling Library (PyML), and was renamed to be more specific for systems engineering applications [5].

Examples[edit]

SysML and UML[edit]

The following generates a use case model diagram:

import selib as se

# system model
system_name = "Course Portal"
actors = ['Student', 'Instructor']
use_cases = ['Post Discussion', 'Take Quiz', 'Create Quiz']
interactions = [('Student', 'Post Discussion'), ('Instructor', 'Post Discussion'), ('Student', 'Take Quiz'), ('Instructor', 'Create Quiz')]
use_case_relationships = []

# create diagram
se.use_case_diagram(system_name, actors, use_cases, interactions, use_case_relationships, filename=system_name+'use case diagram.pdf')
Se-lib course portal use case diagram

Discrete Event Simulation[edit]

Online discrete event modeling examples are available in playground mode at [6].

A discrete event model for electric car charging is:

# electric car charging simulation
init_de_model()

add_source('incoming_cars',
           entity_name="Car",
           num_entities = 50,
           connections={'charger': .7, 'impatient_cars': .3},
           interarrival_time='np.random.exponential(5)')

add_server(name='charger',
           connections={'payment': 1},
           service_time='np.random.uniform(0, 16)',
           capacity = 1)

add_delay(name='payment',
           delay_time = 'np.random.uniform(1, 3)',
           connections={'served_cars': 1},)

add_terminate('served_cars')
add_terminate('impatient_cars')

draw_model_diagram()

model_data, entity_data = run_model()
plot_histogram(model_data['charger']['waiting_times'], xlabel="Charger Waiting Time")
Se-lib electric car model diagram from discrete event simulation
Se-lib electric car model output

References[edit]

  1. ^ Madachy, Raymond (2024-04-17). "Keynote: Open Source Systems Modeling and Convergence with AI". Boehm Center for Systems and Software Engineering 2024 Annual Research Review.
  2. ^ "Naval Postgraduate School Foundation invests $145K in defense research of critical technologies and education programs". Naval Postgraduate School Foundation. November 8, 2022. Retrieved May 4, 2024.
  3. ^ "Tutorial: Open Source Systems Modeling". INCOSE San Diego. May 8, 2023. Retrieved May 4, 2024.
  4. ^ "Boehm CSSE - Center for Systems and Software Engineering". Boehm Center for Systems and Software Engineering. May 8, 2023. Retrieved May 7, 2024.
  5. ^ Madachy, Raymond (2022-12-03). "Introduction to PyML" (PDF). San Diego INCOSE Mini-Conference. San Diego, CA.
  6. ^ "Discrete Event Modeling Demonstrations with se-lib". se-lib development team. November 30, 2023. Retrieved May 4, 2024.

External links[edit]