Nested ordinal RECD: Φ1–Φ3 conjunction levels and λ-weighted Discrete Extramental Clock
Project description
nested-recd
Nested ordinal RECD — pure-NumPy implementation of nested ordinal conjunction levels (Φ₁, Φ₂, Φ₃) and λ-weighted Discrete Extramental Clock (RECD) accumulation.
This is the standalone library behind the nested-time structure used in the CCTP/SDDB cardiac pilot and the experimental design in Conversación de la naturaleza del tiempo.
Install
pip install nested-recd
From source:
pip install git+https://github.com/johelpadilla/nested-recd.git
Quick start
import numpy as np
from nested_recd import compute_recd_from_conjunctions, compute_weighted_contributions
# Multivariate series: shape (T, N)
rng = np.random.default_rng(0)
X = rng.normal(size=(800, 3)).cumsum(axis=0)
out = compute_recd_from_conjunctions(X, m=3, d=4, theta3=0.10)
print("mean Φ1:", float(np.nanmean(out["phi1"])))
print("mean Φ2:", float(np.nanmean(out["phi2"])))
print("Φ3 active fraction:", float(np.nanmean(out["phi3"] > 0)))
print("final T_recd:", float(out["T_recd"][-1]))
w = compute_weighted_contributions(out)
print("frac level-3 contribution:", w["frac_contrib3"])
Optional: supply a Systemic Tau series tau_s (aligned in time) so that λ is derived empirically:
out = compute_recd_from_conjunctions(X, tau_s=tau_s)
Or fix the regime weight with a scalar / array override:
out = compute_recd_from_conjunctions(X, lam_override=0.5)
What it computes
| Symbol | Meaning |
|---|---|
| Φ₁ | Co-occurrence of identical ordinal symbols across variable pairs |
| Φ₂ | Persistence of pairwise ordinal relations over lag d |
| Φ₃ | Higher-order synergy proxy (total-correlation excess + joint surprise) |
| λ | Chaos / reorganization intensity (from τ_s or lam_override) |
| α(λ) | Level weights: α₁ decays with λ; α₂, α₃ grow with λ |
| ΔRECD | α₁Φ₁ + α₂Φ₂ + α₃Φ₃ |
| T_recd | Cumulative sum of ΔRECD (nested-time clock) |
Ordinal symbols use Bandt–Pompe patterns (m=3 by default).
Surrogates
from nested_recd import phase_shuffle_independent, random_permutation_independent
X_null = phase_shuffle_independent(X, seed=42) # IAAFT per column
X_perm = random_permutation_independent(X, seed=42)
API surface
from nested_recd import (
compute_recd_from_conjunctions,
compute_phi1, compute_phi2, compute_phi3,
compute_lambda, alpha_weights, regime_lambda_proxy,
compute_weighted_contributions, high_level3_rate,
generate_multivariate_symbols,
phase_shuffle_independent, generate_surrogate_ensemble,
)
Relation to other projects
| Project | Role |
|---|---|
systemictau |
Full Systemic Tau library (τ_s, platform, studio) |
cctp-sddb-systemic-tau |
Cardiac VF pilot using this nested RECD pipeline |
| This package | Lightweight, installable nested-time / ordinal RECD core |
Citation
If you use this software, please cite the CCTP/SDDB pilot archive:
Padilla-Villanueva, J. (2026). CCTP/SDDB: Systemic Tau and ordinal RECD before spontaneous ventricular fibrillation (v1.0.1). Zenodo. https://doi.org/10.5281/zenodo.21270699
And the theoretical nested-time / RECD framework as appropriate for your venue.
@software{padilla_nested_recd_2026,
author = {Padilla-Villanueva, Johel},
title = {nested-recd: Nested ordinal RECD levels},
year = {2026},
url = {https://github.com/johelpadilla/nested-recd},
version = {0.1.0}
}
License
MIT © 2026 Johel Padilla-Villanueva
ORCID: 0000-0002-5797-6931
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file nested_recd-0.1.0.tar.gz.
File metadata
- Download URL: nested_recd-0.1.0.tar.gz
- Upload date:
- Size: 15.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
da7eda9ae69957468c7668e1c376eb807dfa0cffbd2fa26989b15f8d2200c3af
|
|
| MD5 |
31dc829fd9cf062f5698ba847f36b45d
|
|
| BLAKE2b-256 |
d5850a07597572c328d35cf6c04ab5e03a0f82ceaf2d39d0846c3d5bec21b7bc
|
File details
Details for the file nested_recd-0.1.0-py3-none-any.whl.
File metadata
- Download URL: nested_recd-0.1.0-py3-none-any.whl
- Upload date:
- Size: 14.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
862cc48dd85a0048e6138a37c481f67ba72f588fdbfee07fff3fe873ccf91cf9
|
|
| MD5 |
de74dd28fc3bb87f7bdc8bbc4be9d6b0
|
|
| BLAKE2b-256 |
ed93ac69ae9d7901e25f62a9007c893cb7262b856d65a8052e6f6cf97c60081f
|