Supprocom.MathBlocks
0.5.2
dotnet add package Supprocom.MathBlocks --version 0.5.2
NuGet\Install-Package Supprocom.MathBlocks -Version 0.5.2
<PackageReference Include="Supprocom.MathBlocks" Version="0.5.2" />
<PackageVersion Include="Supprocom.MathBlocks" Version="0.5.2" />
<PackageReference Include="Supprocom.MathBlocks" />
paket add Supprocom.MathBlocks --version 0.5.2
#r "nuget: Supprocom.MathBlocks, 0.5.2"
#:package Supprocom.MathBlocks@0.5.2
#addin nuget:?package=Supprocom.MathBlocks&version=0.5.2
#tool nuget:?package=Supprocom.MathBlocks&version=0.5.2
MathBlocks
MathBlocks is a .NET 10 library for immutable, typed computation graphs with deterministic CPU and CUDA execution. Its standard catalog contains 337 versioned mathematical operations, and every operation can be exchanged through both OpenMath 2.0 and Strict Content MathML 3.0.
Install
Install the Supprocom.MathBlocks package from NuGet.org; CUDA execution also
requires the platform dependencies described in the
development guide.
dotnet add package Supprocom.MathBlocks --version 0.5.2
Build a program
Use MathBlockProgramBuilder to create a type-checked directed acyclic graph,
then evaluate it with named inputs; the
programming model explains contracts, versions,
values, execution, and ownership boundaries.
using Supprocom.MathBlocks;
var builder = new MathBlockProgramBuilder(MathBlockCatalog.Standard);
var width = builder.Input("width", MathBlockType.Scalar());
var height = builder.Input("height", MathBlockType.Scalar());
var area = builder.Apply("scalar.multiply", inputs: [width, height]);
var program = builder.Output("area", area).Build();
var result = program.Evaluate(new Dictionary<string, MathBlockValue>
{
["width"] = MathBlockValue.Scalar(6d),
["height"] = MathBlockValue.Scalar(4d)
});
Console.WriteLine(result["area"].AsScalar());
Exchange formulas
MathBlockOpenMath preserves a complete typed program, while
MathBlockFormulaInterchange projects one selected output as conventional
OpenMath or Content MathML with an exact semantic annotation; all 337 standard
operations have direct mappings.
var mathMl = MathBlockFormulaInterchange.Export(
program,
"area",
MathBlockFormulaFormat.ContentMathMl);
var imported = MathBlockFormulaInterchange.Import(
mathMl,
MathBlockFormulaFormat.ContentMathMl);
Choose an API
Each public entry point has one focused responsibility, so consumers can use notation, managed execution, or low-level CUDA composition independently.
| Goal | Entry point | Guide |
|---|---|---|
| Build and evaluate a typed graph | MathBlockProgramBuilder, MathBlockProgram |
Programming model |
| Preserve a complete typed program | MathBlockOpenMath |
OpenMath API |
| Exchange one standard formula | MathBlockFormulaInterchange |
Formula interchange API |
| Compose or run CUDA work | MathBlockCudaDeviceModule, MathBlocksCUDAWorker |
CUDA integration |
Documentation
The README is intentionally brief; detailed contracts, limits, dependencies, security rules, performance targets, and contributor commands live in the guides below.
| Topic | Document |
|---|---|
| Operations, values, programs, and CPU execution | Programming model |
| Canonical full-program OpenMath | OpenMath API |
| OpenMath and Content MathML formula exchange | Formula interchange API |
| Device dispatch, managed CUDA, ABI, and performance | CUDA integration |
| Prerequisites, dependencies, build, test, and packaging | Development guide |
Build from source
Install the .NET 10 SDK before restoring the repository; CUDA tests additionally require a compatible NVIDIA driver and CUDA toolkit, as detailed in the development guide.
dotnet restore Supprocom.MathBlocks.Tests/Supprocom.MathBlocks.Tests.csproj
dotnet build Supprocom.MathBlocks.Tests/Supprocom.MathBlocks.Tests.csproj --configuration Release
dotnet test Supprocom.MathBlocks.Tests/Supprocom.MathBlocks.Tests.csproj --configuration Release
License
MathBlocks is licensed under AGPL-3.0-only. The NOTICE file contains the project notice and source offer. Dependency notices and separate license terms are in THIRD-PARTY-NOTICES.md.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net10.0 is compatible. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net10.0
- libtorch-cuda-12.8-win-x64-part1 (= 2.10.0)
- libtorch-cuda-12.8-win-x64-part8 (= 2.10.0)
- TorchSharp-cuda-linux (= 0.107.0)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 0.5.2 | 0 | 9/29/2026 |
| 0.5.1 | 51 | 9/24/2026 |
| 0.5.0 | 228 | 9/20/2026 |
| 0.4.1 | 124 | 9/4/2026 |
| 0.4.0 | 107 | 9/3/2026 |
| 0.3.2 | 376 | 8/12/2026 |
| 0.3.1 | 129 | 8/9/2026 |
| 0.3.0 | 127 | 8/9/2026 |
| 0.2.4 | 125 | 8/6/2026 |
| 0.2.3 | 111 | 8/6/2026 |
| 0.2.2 | 115 | 8/5/2026 |
| 0.2.1 | 110 | 8/5/2026 |
| 0.2.0 | 115 | 8/4/2026 |
| 0.1.7 | 117 | 8/4/2026 |
| 0.1.6 | 116 | 8/4/2026 |
| 0.1.5 | 134 | 8/4/2026 |
| 0.1.4 | 142 | 8/3/2026 |
| 0.1.3 | 123 | 8/3/2026 |
| 0.1.2 | 124 | 8/3/2026 |
| 0.1.1 | 134 | 8/3/2026 |
Clears enabled SDK and specialist analyzer warnings with a tracked public API baseline, strengthens native loading, and fixes .NET 10 NVRTC UTF-8 option marshaling. The 337-operation OpenMath and Content MathML interchange and CUDA source fingerprint remain unchanged.