pyblock-ffi 0.6.0

Embeds a Python interpreter and calls user-supplied Python functions (start/output, optionally derivative/output_xc) once per resolved block-graph step -- the Python-hosted counterpart to cscript-ffi's dynamically-linked C blocks, kept isolated from every other crate.
Documentation

pyblock-ffi

Embeds a Python interpreter (via PyO3) and calls user-supplied Python functions once per simulation step: stateful blocks (start/output/update) and stateless function blocks.

Requires a Python installation. The runner crate enables it with the python Cargo feature.

Part of general-simulator

This crate is one piece of general-simulator, an open-source Rust simulator for piecewise-linear circuits and mixed circuit/block-diagram systems. Instead of Newton-Raphson with voltage limiting, it resolves which linear segment every device is in as a Linear Complementarity Problem each timestep. Documentation lives in the repository's book/ directory.

License

AGPL-3.0-or-later. See LICENSE.