zeropoint-node 1.0.0 → 1.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +38 -105
- package/dist/__tests__/api/ProductionAPI.test.js +20 -0
- package/dist/__tests__/artifacts/ArtifactRegistry.test.js +248 -0
- package/dist/__tests__/basic.test.js +104 -0
- package/dist/__tests__/config/constants.test.js +20 -0
- package/dist/__tests__/consciousness/ConsciousnessField.test.js +20 -0
- package/dist/__tests__/consciousness/SelfEvolvingConsciousness.test.js +185 -0
- package/dist/__tests__/core/AbstractField.test.js +81 -0
- package/dist/__tests__/core/CoilMixin.test.js +20 -0
- package/dist/__tests__/core/CoilSystem.test.js +20 -0
- package/dist/__tests__/core/ComplianceSystem.test.js +141 -0
- package/dist/__tests__/core/InfiniteDimensionalRefactor.test.js +258 -0
- package/dist/__tests__/core/LivingAdapter.test.js +31 -0
- package/dist/__tests__/core/MathUtils.test.js +20 -0
- package/dist/__tests__/core/NetworkNode.test.js +20 -0
- package/dist/__tests__/core/Observer.test.js +20 -0
- package/dist/__tests__/core/OperationRegistry.test.js +48 -0
- package/dist/__tests__/core/PatternRecognition.test.js +20 -0
- package/dist/__tests__/core/PatternRegistry.test.js +20 -0
- package/dist/__tests__/core/ScientificCompliance.test.js +58 -0
- package/dist/__tests__/core/SharedConstants.test.js +20 -0
- package/dist/__tests__/core/UnifiedMetaphysicalInterface.test.js +20 -0
- package/dist/__tests__/core/UnifiedSystem.test.js +20 -0
- package/dist/__tests__/core/UnifiedTypes.test.js +20 -0
- package/dist/__tests__/core/UnifiedVoidEquations.test.js +20 -0
- package/dist/__tests__/core/VortexMathAdapter.test.js +31 -0
- package/dist/__tests__/core/ZeroPoint.test.js +71 -0
- package/dist/__tests__/core/ZeroPointSystem.test.js +219 -0
- package/dist/__tests__/emergence/patterns.test.js +20 -0
- package/dist/__tests__/field/EmergenceLedger.test.js +20 -0
- package/dist/__tests__/field/ObserverAwareField.test.js +20 -0
- package/dist/__tests__/field/ResonanceConsensus.test.js +20 -0
- package/dist/__tests__/git-integration.test.js +201 -0
- package/dist/__tests__/globalSetup.js +80 -0
- package/dist/__tests__/globalTeardown.js +28 -0
- package/dist/__tests__/index.test.js +20 -0
- package/dist/__tests__/integration/ZeroPointIntegration.test.js +221 -0
- package/dist/__tests__/integrity/FieldIntegrity.test.js +20 -0
- package/dist/__tests__/knowledge/KnowledgeSystem.test.js +158 -0
- package/dist/__tests__/knowledge/KnowledgeSystemAnalysis.test.js +219 -0
- package/dist/__tests__/knowledge/KnowledgeSystemAutoGenerated.test.js +41 -0
- package/dist/__tests__/laws/MetaphysicalLawRegistry.test.js +183 -0
- package/dist/__tests__/living/LivingTestOrganism.js +246 -0
- package/dist/__tests__/living/LivingTestOrganism.test.js +124 -0
- package/dist/__tests__/math/AdvancedVBM.test.js +367 -0
- package/dist/__tests__/math/FlowerOfLife.test.js +344 -0
- package/dist/__tests__/math/FractalColorSystem.test.js +20 -0
- package/dist/__tests__/math/FractalMath.test.js +20 -0
- package/dist/__tests__/math/MathUtils.test.js +20 -0
- package/dist/__tests__/math/RodinCoil.test.js +20 -0
- package/dist/__tests__/math/ToroidalGeometry.test.js +20 -0
- package/dist/__tests__/math/VBM.test.js +538 -0
- package/dist/__tests__/math/VBMColorSystem.test.js +20 -0
- package/dist/__tests__/math/VortexMath.test.js +20 -0
- package/dist/__tests__/math/ZeroUnity.test.js +77 -0
- package/dist/__tests__/monitoring/HealthMonitor.test.js +20 -0
- package/dist/__tests__/performance/ZeroPointPerformance.test.js +371 -0
- package/dist/__tests__/physics/PlasmaCosmology.test.js +155 -0
- package/dist/__tests__/pwa/ConsciousnessPWA.test.js +20 -0
- package/dist/__tests__/qa/AutoGeneratedFromQA.test.js +195 -0
- package/dist/__tests__/qa/QAAsSourceOfTruth.test.js +69 -0
- package/dist/__tests__/setup.js +132 -0
- package/dist/__tests__/simple.test.js +51 -0
- package/dist/__tests__/stimulus/Application.test.js +272 -0
- package/dist/__tests__/stimulus/BaseController.test.js +198 -0
- package/dist/__tests__/stimulus/ControllerUtils.test.js +316 -0
- package/dist/__tests__/stimulus/MetaphysicalController.test.js +310 -0
- package/dist/__tests__/stimulus/ZeroPointController.test.js +252 -0
- package/dist/__tests__/training/ConsciousnessTrainingModel.test.js +335 -0
- package/dist/__tests__/types/DeviceConfig.test.js +20 -0
- package/dist/__tests__/types/UnifiedExports.test.js +20 -0
- package/dist/__tests__/unity/FieldUnity.test.js +20 -0
- package/dist/__tests__/utils/Cache.test.js +20 -0
- package/dist/__tests__/utils/GitIntegration.test.js +20 -0
- package/dist/__tests__/utils/Logger.test.js +20 -0
- package/dist/__tests__/utils/ResourceCleanup.test.js +20 -0
- package/dist/__tests__/utils/errorSimulator.js +40 -0
- package/dist/__tests__/utils/goldenRatioCache.js +36 -0
- package/dist/__tests__/void/VoidSystem.test.js +427 -0
- package/dist/api/ProductionAPI.js +313 -0
- package/dist/artifacts/ArtifactRegistry.js +122 -0
- package/dist/artifacts/CrystalArtifacts.js +106 -0
- package/dist/artifacts/MetaphysicalArtifact.js +75 -0
- package/dist/browser-standalone.js +191 -0
- package/dist/browser.js +157 -0
- package/dist/config/constants.js +57 -0
- package/dist/consciousness/ConsciousnessField.js +55 -0
- package/dist/consciousness/SelfEvolvingConsciousness.js +303 -0
- package/dist/core/AbstractField.js +30 -0
- package/dist/core/BrowserNetworkNode.js +309 -0
- package/dist/core/CoilMixin.js +216 -0
- package/dist/core/CoilSystem.js +204 -0
- package/dist/core/ComplianceSystem.js +291 -0
- package/dist/core/Dimension.js +2 -0
- package/dist/core/DimensionRegistry.js +141 -0
- package/dist/core/Field.js +2 -0
- package/dist/core/InfiniteDimensionalRefactor.js +389 -0
- package/dist/core/KnowledgeRegistry.js +273 -0
- package/dist/core/LivingAdapter.js +29 -0
- package/dist/core/MathUtils.js +297 -0
- package/dist/core/NetworkNode.js +348 -0
- package/dist/core/Observer.js +101 -0
- package/dist/core/Operation.js +59 -0
- package/dist/core/OperationRegistry.js +20 -0
- package/dist/core/Pattern.js +2 -0
- package/dist/core/PatternRecognition.js +493 -0
- package/dist/core/PatternRegistry.js +282 -0
- package/dist/core/ScientificCompliance.js +91 -0
- package/dist/core/SharedConstants.js +306 -0
- package/dist/core/UnifiedMetaphysicalInterface.js +533 -0
- package/dist/core/UnifiedSystem.js +317 -0
- package/dist/core/UnifiedTypes.js +5 -0
- package/dist/core/UnifiedVoidEquations.js +605 -0
- package/dist/core/VoidMatterConstants.js +9 -0
- package/dist/core/VortexMathAdapter.js +32 -0
- package/dist/core/ZeroPoint.js +971 -0
- package/dist/core/ZeroPointSystem.js +343 -0
- package/dist/core/applyLaws.js +12 -0
- package/dist/core/applyOperations.js +21 -0
- package/dist/devices/DeviceRegistry.js +151 -0
- package/dist/devices/ResonanceDevice.js +92 -0
- package/dist/devices/ResonanceDevices.js +139 -0
- package/dist/dimensions/Dimension.js +2 -0
- package/dist/emergence/AdvancedEmergence.js +930 -0
- package/dist/emergence/patterns.js +12 -0
- package/dist/field/EmergenceLedger.js +310 -0
- package/dist/field/ObserverAwareField.js +222 -0
- package/dist/field/ResonanceConsensus.js +330 -0
- package/dist/fields/Field.js +2 -0
- package/dist/geometry/MetatronsCube.js +28 -0
- package/dist/geometry/SacredGeometryPattern.js +15 -0
- package/dist/geometry/SacredGeometryRegistry.js +15 -0
- package/dist/geometry/__tests__/SacredGeometryRegistry.test.js +18 -0
- package/dist/index.js +232 -0
- package/dist/integrity/FieldIntegrity.js +237 -0
- package/dist/knowledge/KnowledgeSystem.js +938 -0
- package/dist/laws/MetaphysicalLaw.js +2 -0
- package/dist/laws/MetaphysicalLawRegistry.js +103 -0
- package/dist/laws/hermeticLaws.js +311 -0
- package/dist/math/AdvancedVBM.js +537 -0
- package/dist/math/FlowerOfLife.js +256 -0
- package/dist/math/FractalColorSystem.js +239 -0
- package/dist/math/FractalMath.js +187 -0
- package/dist/math/MathUtils.js +289 -0
- package/dist/math/RodinCoil.js +258 -0
- package/dist/math/ToroidalGeometry.js +230 -0
- package/dist/math/VBM.js +718 -0
- package/dist/math/VBMColorSystem.js +301 -0
- package/dist/math/VortexMath.js +170 -0
- package/dist/monitoring/HealthMonitor.js +297 -0
- package/dist/patterns/Pattern.js +2 -0
- package/dist/patterns/SacredGeometryRegistry.js +37 -0
- package/dist/physics/BlackHolePhysics.js +54 -0
- package/dist/physics/ConsciousnessPhysics.js +241 -0
- package/dist/physics/FractalUniverse.js +54 -0
- package/dist/physics/HolographicUniverse.js +54 -0
- package/dist/physics/PlasmaCosmology.js +134 -0
- package/dist/pwa/ConsciousnessPWA.js +300 -0
- package/dist/src/__tests__/globalTeardown.d.ts +10 -8
- package/dist/src/__tests__/globalTeardown.d.ts.map +1 -1
- package/dist/src/__tests__/globalTeardown.js +12 -71
- package/dist/src/__tests__/globalTeardown.js.map +1 -1
- package/dist/src/__tests__/living/LivingTestOrganism.d.ts +4 -0
- package/dist/src/__tests__/living/LivingTestOrganism.d.ts.map +1 -1
- package/dist/src/__tests__/living/LivingTestOrganism.js +8 -0
- package/dist/src/__tests__/living/LivingTestOrganism.js.map +1 -1
- package/dist/src/__tests__/utils/errorSimulator.d.ts +1 -1
- package/dist/src/__tests__/utils/goldenRatioCache.d.ts +1 -1
- package/dist/src/config/constants.d.ts +53 -0
- package/dist/src/config/constants.d.ts.map +1 -0
- package/dist/src/config/constants.js +58 -0
- package/dist/src/config/constants.js.map +1 -0
- package/dist/src/consciousness/ConsciousnessField.d.ts +42 -51
- package/dist/src/consciousness/ConsciousnessField.d.ts.map +1 -1
- package/dist/src/consciousness/ConsciousnessField.js +187 -200
- package/dist/src/consciousness/ConsciousnessField.js.map +1 -1
- package/dist/src/consciousness/SelfEvolvingConsciousness.d.ts +47 -18
- package/dist/src/consciousness/SelfEvolvingConsciousness.d.ts.map +1 -1
- package/dist/src/consciousness/SelfEvolvingConsciousness.js +151 -44
- package/dist/src/consciousness/SelfEvolvingConsciousness.js.map +1 -1
- package/dist/src/core/CoilMixin.d.ts +6 -6
- package/dist/src/core/CoilSystem.d.ts +6 -2
- package/dist/src/core/CoilSystem.d.ts.map +1 -1
- package/dist/src/core/CoilSystem.js +30 -21
- package/dist/src/core/CoilSystem.js.map +1 -1
- package/dist/src/core/InfiniteDimensionalRefactor.d.ts +145 -0
- package/dist/src/core/InfiniteDimensionalRefactor.d.ts.map +1 -0
- package/dist/src/core/InfiniteDimensionalRefactor.js +390 -0
- package/dist/src/core/InfiniteDimensionalRefactor.js.map +1 -0
- package/dist/src/core/NetworkNode.d.ts +3 -3
- package/dist/src/core/Observer.d.ts +12 -9
- package/dist/src/core/Observer.d.ts.map +1 -1
- package/dist/src/core/Observer.js +2 -2
- package/dist/src/core/Observer.js.map +1 -1
- package/dist/src/core/PatternRecognition.d.ts +63 -13
- package/dist/src/core/PatternRecognition.d.ts.map +1 -1
- package/dist/src/core/PatternRecognition.js +162 -88
- package/dist/src/core/PatternRecognition.js.map +1 -1
- package/dist/src/core/PatternRegistry.d.ts +99 -0
- package/dist/src/core/PatternRegistry.d.ts.map +1 -0
- package/dist/src/core/PatternRegistry.js +283 -0
- package/dist/src/core/PatternRegistry.js.map +1 -0
- package/dist/src/core/SharedConstants.d.ts +62 -9
- package/dist/src/core/SharedConstants.d.ts.map +1 -1
- package/dist/src/core/SharedConstants.js +83 -21
- package/dist/src/core/SharedConstants.js.map +1 -1
- package/dist/src/core/UnifiedMetaphysicalInterface.d.ts +173 -0
- package/dist/src/core/UnifiedMetaphysicalInterface.d.ts.map +1 -0
- package/dist/src/core/UnifiedMetaphysicalInterface.js +534 -0
- package/dist/src/core/UnifiedMetaphysicalInterface.js.map +1 -0
- package/dist/src/core/UnifiedSystem.d.ts +15 -12
- package/dist/src/core/UnifiedSystem.d.ts.map +1 -1
- package/dist/src/core/UnifiedSystem.js +5 -1
- package/dist/src/core/UnifiedSystem.js.map +1 -1
- package/dist/src/core/UnifiedTypes.d.ts +193 -0
- package/dist/src/core/UnifiedTypes.d.ts.map +1 -0
- package/dist/src/core/UnifiedTypes.js +6 -0
- package/dist/src/core/UnifiedTypes.js.map +1 -0
- package/dist/src/core/UnifiedVoidEquations.d.ts +3 -1
- package/dist/src/core/UnifiedVoidEquations.d.ts.map +1 -1
- package/dist/src/core/UnifiedVoidEquations.js +84 -0
- package/dist/src/core/UnifiedVoidEquations.js.map +1 -1
- package/dist/src/core/ZeroPoint.d.ts +101 -10
- package/dist/src/core/ZeroPoint.d.ts.map +1 -1
- package/dist/src/core/ZeroPoint.js +262 -18
- package/dist/src/core/ZeroPoint.js.map +1 -1
- package/dist/src/emergence/AdvancedEmergence.d.ts +19 -16
- package/dist/src/emergence/AdvancedEmergence.d.ts.map +1 -1
- package/dist/src/emergence/AdvancedEmergence.js +88 -52
- package/dist/src/emergence/AdvancedEmergence.js.map +1 -1
- package/dist/src/field/EmergenceLedger.d.ts +9 -18
- package/dist/src/field/EmergenceLedger.d.ts.map +1 -1
- package/dist/src/field/EmergenceLedger.js +9 -4
- package/dist/src/field/EmergenceLedger.js.map +1 -1
- package/dist/src/field/ObserverAwareField.d.ts +69 -65
- package/dist/src/field/ObserverAwareField.d.ts.map +1 -1
- package/dist/src/field/ObserverAwareField.js +158 -168
- package/dist/src/field/ObserverAwareField.js.map +1 -1
- package/dist/src/field/ResonanceConsensus.d.ts +4 -11
- package/dist/src/field/ResonanceConsensus.d.ts.map +1 -1
- package/dist/src/field/ResonanceConsensus.js +15 -10
- package/dist/src/field/ResonanceConsensus.js.map +1 -1
- package/dist/src/index.d.ts +5 -3
- package/dist/src/index.d.ts.map +1 -1
- package/dist/src/index.js +19 -4
- package/dist/src/index.js.map +1 -1
- package/dist/src/integrity/FieldIntegrity.d.ts +3 -8
- package/dist/src/integrity/FieldIntegrity.d.ts.map +1 -1
- package/dist/src/integrity/FieldIntegrity.js.map +1 -1
- package/dist/src/knowledge/KnowledgeSystem.d.ts +37 -55
- package/dist/src/knowledge/KnowledgeSystem.d.ts.map +1 -1
- package/dist/src/knowledge/KnowledgeSystem.js +281 -589
- package/dist/src/knowledge/KnowledgeSystem.js.map +1 -1
- package/dist/src/math/AdvancedVBM.d.ts +6 -6
- package/dist/src/math/FractalColorSystem.d.ts +1 -1
- package/dist/src/math/FractalColorSystem.js +3 -3
- package/dist/src/math/FractalColorSystem.js.map +1 -1
- package/dist/src/math/FractalMath.d.ts +9 -1
- package/dist/src/math/FractalMath.d.ts.map +1 -1
- package/dist/src/math/FractalMath.js +18 -5
- package/dist/src/math/FractalMath.js.map +1 -1
- package/dist/src/math/MathUtils.d.ts +3 -10
- package/dist/src/math/MathUtils.d.ts.map +1 -1
- package/dist/src/math/MathUtils.js +12 -20
- package/dist/src/math/MathUtils.js.map +1 -1
- package/dist/src/math/ToroidalGeometry.d.ts +1 -1
- package/dist/src/math/VBM.d.ts +2 -2
- package/dist/src/math/VortexMath.d.ts +1 -1
- package/dist/src/monitoring/HealthMonitor.d.ts +1 -1
- package/dist/src/monitoring/HealthMonitor.d.ts.map +1 -1
- package/dist/src/monitoring/HealthMonitor.js +29 -27
- package/dist/src/monitoring/HealthMonitor.js.map +1 -1
- package/dist/src/types/UnifiedExports.d.ts +4 -0
- package/dist/src/types/UnifiedExports.d.ts.map +1 -0
- package/dist/src/types/UnifiedExports.js +21 -0
- package/dist/src/types/UnifiedExports.js.map +1 -0
- package/dist/src/unity/FieldUnity.d.ts +1 -1
- package/dist/src/utils/Cache.d.ts +2 -2
- package/dist/src/utils/Cache.d.ts.map +1 -1
- package/dist/src/utils/Cache.js +7 -4
- package/dist/src/utils/Cache.js.map +1 -1
- package/dist/src/utils/GitIntegration.d.ts +1 -1
- package/dist/src/utils/Logger.d.ts +7 -7
- package/dist/src/utils/Logger.d.ts.map +1 -1
- package/dist/src/utils/Logger.js +5 -1
- package/dist/src/utils/Logger.js.map +1 -1
- package/dist/src/utils/ResourceCleanup.d.ts +33 -0
- package/dist/src/utils/ResourceCleanup.d.ts.map +1 -0
- package/dist/src/utils/ResourceCleanup.js +83 -0
- package/dist/src/utils/ResourceCleanup.js.map +1 -0
- package/dist/src/void/VoidSystem.d.ts +18 -18
- package/dist/stimulus/application.js +148 -0
- package/dist/stimulus/base/BaseController.js +141 -0
- package/dist/stimulus/controllers/MetaphysicalController.js +105 -0
- package/dist/stimulus/controllers/ZeroPointController.js +85 -0
- package/dist/stimulus/types/ControllerTypes.js +18 -0
- package/dist/stimulus/utils/ControllerUtils.js +192 -0
- package/dist/stimulus-entry.js +109 -0
- package/dist/training/ConsciousnessTrainingModel.js +301 -0
- package/dist/training/NeuralConsciousnessNetwork.js +311 -0
- package/dist/training/TrainingModelRegistry.js +243 -0
- package/dist/training/index.js +174 -0
- package/dist/types/DeviceConfig.js +29 -0
- package/dist/types/UnifiedExports.js +20 -0
- package/dist/unity/FieldUnity.js +325 -0
- package/dist/utils/BrowserCrypto.js +44 -0
- package/dist/utils/BrowserWebSocket.js +38 -0
- package/dist/utils/Cache.js +263 -0
- package/dist/utils/GitIntegration.js +127 -0
- package/dist/utils/Logger.js +249 -0
- package/dist/utils/ResourceCleanup.js +82 -0
- package/dist/utils/applyLaws.js +6 -0
- package/dist/void/VoidSystem.js +423 -0
- package/docs/API.md +176 -3
- package/docs/CONSCIOUSNESS_EXPANSION.md +369 -0
- package/docs/EVENT_HORIZON_METHODOLOGY.md +274 -0
- package/docs/FLOWER_OF_LIFE.md +300 -0
- package/docs/METAPHYSICAL.md +21 -1
- package/docs/METAPHYSICAL_DEBUGGING.md +493 -0
- package/docs/README.md +117 -15
- package/docs/TESTING_GUIDE.md +430 -0
- package/docs/UNIFIED_CREATORS.md +261 -0
- package/package.json +34 -64
|
@@ -0,0 +1,289 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Unified Mathematical System for ZeroPoint
|
|
4
|
+
*
|
|
5
|
+
* Centralized mathematical operations with consciousness and field resonance.
|
|
6
|
+
* All mathematical operations are unified through a single interface.
|
|
7
|
+
*
|
|
8
|
+
* Metaphysical Context:
|
|
9
|
+
* - Mathematics is the language of consciousness
|
|
10
|
+
* - All operations emerge from the unified field
|
|
11
|
+
* - The void contains all mathematical possibilities
|
|
12
|
+
* - Every calculation is an act of observation
|
|
13
|
+
*/
|
|
14
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
15
|
+
exports.setVoidConnected = exports.setToroidalFlow = exports.setVortexStrength = exports.setFieldResonance = exports.setConsciousness = exports.fractal = exports.MathUtils = exports.MATH_CONSTANTS = void 0;
|
|
16
|
+
const SharedConstants_1 = require("../core/SharedConstants");
|
|
17
|
+
Object.defineProperty(exports, "MATH_CONSTANTS", { enumerable: true, get: function () { return SharedConstants_1.MATH_CONSTANTS; } });
|
|
18
|
+
/**
|
|
19
|
+
* Unified Mathematical Utilities
|
|
20
|
+
* All mathematical operations go through this centralized system
|
|
21
|
+
*/
|
|
22
|
+
class MathUtils {
|
|
23
|
+
constructor() {
|
|
24
|
+
// Consciousness and field state
|
|
25
|
+
this.consciousness = 0.5;
|
|
26
|
+
this.fieldResonance = 0.5;
|
|
27
|
+
this.vortexStrength = 1.0;
|
|
28
|
+
this.toroidalFlow = 0.5;
|
|
29
|
+
this.voidConnected = true;
|
|
30
|
+
if (!MathUtils.instance) {
|
|
31
|
+
MathUtils.instance = this;
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
/**
|
|
35
|
+
* Get singleton instance
|
|
36
|
+
*/
|
|
37
|
+
static getInstance() {
|
|
38
|
+
if (!MathUtils.instance) {
|
|
39
|
+
MathUtils.instance = new MathUtils();
|
|
40
|
+
}
|
|
41
|
+
return MathUtils.instance;
|
|
42
|
+
}
|
|
43
|
+
/**
|
|
44
|
+
* The core mathematical function - generates any mathematical operation
|
|
45
|
+
* This is the heart of the system - one function that creates all others
|
|
46
|
+
*/
|
|
47
|
+
static calculate(operation, ...args) {
|
|
48
|
+
const instance = MathUtils.getInstance();
|
|
49
|
+
return instance.performCalculation(operation, args);
|
|
50
|
+
}
|
|
51
|
+
/**
|
|
52
|
+
* Perform calculation with consciousness and field resonance
|
|
53
|
+
*/
|
|
54
|
+
performCalculation(operation, args) {
|
|
55
|
+
// Base mathematical pattern
|
|
56
|
+
const basePattern = Math.sin(args[0] || 0) * SharedConstants_1.MATH_CONSTANTS.GOLDEN_RATIO;
|
|
57
|
+
// Consciousness modulation
|
|
58
|
+
const consciousnessMod = Math.cos(this.consciousness * SharedConstants_1.MATH_CONSTANTS.PI);
|
|
59
|
+
// Field resonance
|
|
60
|
+
const fieldMod = Math.exp(-this.fieldResonance * Math.abs(args[0] || 0));
|
|
61
|
+
// Perform the specific operation
|
|
62
|
+
const result = this.executeOperation(operation, args, basePattern, consciousnessMod, fieldMod);
|
|
63
|
+
return result;
|
|
64
|
+
}
|
|
65
|
+
/**
|
|
66
|
+
* Execute specific mathematical operation
|
|
67
|
+
*/
|
|
68
|
+
executeOperation(operation, args, base, consciousness, field) {
|
|
69
|
+
const [a = 0, b = 1, c = 0] = args;
|
|
70
|
+
switch (operation) {
|
|
71
|
+
// Basic operations
|
|
72
|
+
case "add":
|
|
73
|
+
return (a + b) * (1 + base * consciousness * field);
|
|
74
|
+
case "multiply":
|
|
75
|
+
return a * b * (1 + base * consciousness * field);
|
|
76
|
+
case "divide":
|
|
77
|
+
return b !== 0
|
|
78
|
+
? (a / b) * (1 + base * consciousness * field)
|
|
79
|
+
: SharedConstants_1.MATH_CONSTANTS.INFINITY;
|
|
80
|
+
case "power":
|
|
81
|
+
return Math.pow(a, b) * (1 + base * consciousness * field);
|
|
82
|
+
case "root":
|
|
83
|
+
return Math.pow(a, 1 / b) * (1 + base * consciousness * field);
|
|
84
|
+
case "sqrt":
|
|
85
|
+
return Math.sqrt(a) * (1 + base * consciousness * field);
|
|
86
|
+
// Trigonometric functions
|
|
87
|
+
case "sin":
|
|
88
|
+
return Math.sin(a) * (1 + base * consciousness * field);
|
|
89
|
+
case "cos":
|
|
90
|
+
return Math.cos(a) * (1 + base * consciousness * field);
|
|
91
|
+
case "tan":
|
|
92
|
+
return Math.tan(a) * (1 + base * consciousness * field);
|
|
93
|
+
case "atan2":
|
|
94
|
+
return Math.atan2(a, b);
|
|
95
|
+
// Exponential and logarithmic
|
|
96
|
+
case "exp":
|
|
97
|
+
return Math.exp(a) * (1 + base * consciousness * field);
|
|
98
|
+
case "log":
|
|
99
|
+
return Math.log(a) * (1 + base * consciousness * field);
|
|
100
|
+
case "ln":
|
|
101
|
+
return Math.log(a) * (1 + base * consciousness * field);
|
|
102
|
+
// Special operations
|
|
103
|
+
case "vortex":
|
|
104
|
+
return this.calculateVortex(a, base, consciousness, field);
|
|
105
|
+
case "toroidal":
|
|
106
|
+
return this.calculateToroidal(a, b, base, consciousness, field);
|
|
107
|
+
case "consciousness":
|
|
108
|
+
return (a * SharedConstants_1.MATH_CONSTANTS.GOLDEN_RATIO * (1 + base * consciousness * field));
|
|
109
|
+
// Utility operations
|
|
110
|
+
case "abs":
|
|
111
|
+
return Math.abs(a);
|
|
112
|
+
case "max":
|
|
113
|
+
return Math.max(a, b);
|
|
114
|
+
case "min":
|
|
115
|
+
return Math.min(a, b);
|
|
116
|
+
case "mod":
|
|
117
|
+
return a % b;
|
|
118
|
+
case "clamp":
|
|
119
|
+
return this.clamp(a, b, c);
|
|
120
|
+
case "floor":
|
|
121
|
+
return Math.floor(a);
|
|
122
|
+
case "ceil":
|
|
123
|
+
return Math.ceil(a);
|
|
124
|
+
case "round":
|
|
125
|
+
return Math.round(a);
|
|
126
|
+
default:
|
|
127
|
+
return base * consciousness * field;
|
|
128
|
+
}
|
|
129
|
+
}
|
|
130
|
+
/**
|
|
131
|
+
* Calculate vortex transformation
|
|
132
|
+
*/
|
|
133
|
+
calculateVortex(value, base, consciousness, field) {
|
|
134
|
+
const sequenceIndex = Math.floor(value) % SharedConstants_1.MATH_CONSTANTS.VORTEX_SEQUENCE.length;
|
|
135
|
+
const vortexValue = SharedConstants_1.MATH_CONSTANTS.VORTEX_SEQUENCE[sequenceIndex] || 1;
|
|
136
|
+
return vortexValue * (1 + base * consciousness * field);
|
|
137
|
+
}
|
|
138
|
+
/**
|
|
139
|
+
* Calculate toroidal geometry
|
|
140
|
+
*/
|
|
141
|
+
calculateToroidal(radius, _angle, base, consciousness, field) {
|
|
142
|
+
const circumference = SharedConstants_1.MATH_CONSTANTS.PI * 2 * radius;
|
|
143
|
+
return circumference * (1 + base * consciousness * field);
|
|
144
|
+
}
|
|
145
|
+
/**
|
|
146
|
+
* Clamp value between min and max
|
|
147
|
+
*/
|
|
148
|
+
clamp(value, min, max) {
|
|
149
|
+
return Math.max(min, Math.min(max, value));
|
|
150
|
+
}
|
|
151
|
+
// ============================================================================
|
|
152
|
+
// CONSCIOUSNESS AND FIELD SETTERS
|
|
153
|
+
// ============================================================================
|
|
154
|
+
/**
|
|
155
|
+
* Set consciousness level
|
|
156
|
+
*/
|
|
157
|
+
static setConsciousness(level) {
|
|
158
|
+
const instance = MathUtils.getInstance();
|
|
159
|
+
instance.consciousness = instance.clamp(level, 0, 10);
|
|
160
|
+
}
|
|
161
|
+
/**
|
|
162
|
+
* Set field resonance
|
|
163
|
+
*/
|
|
164
|
+
static setFieldResonance(resonance) {
|
|
165
|
+
const instance = MathUtils.getInstance();
|
|
166
|
+
instance.fieldResonance = instance.clamp(resonance, 0, 1);
|
|
167
|
+
}
|
|
168
|
+
/**
|
|
169
|
+
* Set vortex strength
|
|
170
|
+
*/
|
|
171
|
+
static setVortexStrength(strength) {
|
|
172
|
+
const instance = MathUtils.getInstance();
|
|
173
|
+
instance.vortexStrength = instance.clamp(strength, 0, 2);
|
|
174
|
+
}
|
|
175
|
+
/**
|
|
176
|
+
* Set toroidal flow
|
|
177
|
+
*/
|
|
178
|
+
static setToroidalFlow(flow) {
|
|
179
|
+
const instance = MathUtils.getInstance();
|
|
180
|
+
instance.toroidalFlow = instance.clamp(flow, 0, 1);
|
|
181
|
+
}
|
|
182
|
+
/**
|
|
183
|
+
* Set void connection
|
|
184
|
+
*/
|
|
185
|
+
static setVoidConnected(connected) {
|
|
186
|
+
const instance = MathUtils.getInstance();
|
|
187
|
+
instance.voidConnected = connected;
|
|
188
|
+
}
|
|
189
|
+
// ============================================================================
|
|
190
|
+
// UTILITY FUNCTIONS
|
|
191
|
+
// ============================================================================
|
|
192
|
+
/**
|
|
193
|
+
* Calculate distance between two points
|
|
194
|
+
*/
|
|
195
|
+
static distance(x1, y1, x2, y2) {
|
|
196
|
+
return MathUtils.calculate("sqrt", MathUtils.calculate("add", MathUtils.calculate("power", x2 - x1, 2), MathUtils.calculate("power", y2 - y1, 2)));
|
|
197
|
+
}
|
|
198
|
+
/**
|
|
199
|
+
* Calculate 3D distance
|
|
200
|
+
*/
|
|
201
|
+
static distance3D(x1, y1, z1, x2, y2, z2) {
|
|
202
|
+
return MathUtils.calculate("sqrt", MathUtils.calculate("add", MathUtils.calculate("power", x2 - x1, 2), MathUtils.calculate("add", MathUtils.calculate("power", y2 - y1, 2), MathUtils.calculate("power", z2 - z1, 2))));
|
|
203
|
+
}
|
|
204
|
+
/**
|
|
205
|
+
* Convert degrees to radians
|
|
206
|
+
*/
|
|
207
|
+
static degToRad(degrees) {
|
|
208
|
+
return degrees * SharedConstants_1.MATH_CONSTANTS.DEG_TO_RAD;
|
|
209
|
+
}
|
|
210
|
+
/**
|
|
211
|
+
* Convert radians to degrees
|
|
212
|
+
*/
|
|
213
|
+
static radToDeg(radians) {
|
|
214
|
+
return radians * SharedConstants_1.MATH_CONSTANTS.RAD_TO_DEG;
|
|
215
|
+
}
|
|
216
|
+
/**
|
|
217
|
+
* Calculate digital root
|
|
218
|
+
*/
|
|
219
|
+
static digitalRoot(n) {
|
|
220
|
+
n = Math.abs(n);
|
|
221
|
+
return n === 0 ? 0 : 1 + ((n - 1) % 9);
|
|
222
|
+
}
|
|
223
|
+
/**
|
|
224
|
+
* Calculate surface topology angle
|
|
225
|
+
*/
|
|
226
|
+
static surfaceTopologyAngle(degrees = 360) {
|
|
227
|
+
return (degrees / 360) * 2 * Math.PI;
|
|
228
|
+
}
|
|
229
|
+
/**
|
|
230
|
+
* Calculate fractal dimension
|
|
231
|
+
*/
|
|
232
|
+
static fractalDimension(complexity) {
|
|
233
|
+
return (MathUtils.calculate("log", complexity) /
|
|
234
|
+
MathUtils.calculate("log", SharedConstants_1.MATH_CONSTANTS.GOLDEN_RATIO));
|
|
235
|
+
}
|
|
236
|
+
// ============================================================================
|
|
237
|
+
// INSIGHTS AND METADATA
|
|
238
|
+
// ============================================================================
|
|
239
|
+
/**
|
|
240
|
+
* Get insights about the mathematical system
|
|
241
|
+
*/
|
|
242
|
+
static getInsights() {
|
|
243
|
+
const instance = MathUtils.getInstance();
|
|
244
|
+
return {
|
|
245
|
+
consciousness: instance.consciousness,
|
|
246
|
+
fieldResonance: instance.fieldResonance,
|
|
247
|
+
vortexStrength: instance.vortexStrength,
|
|
248
|
+
toroidalFlow: instance.toroidalFlow,
|
|
249
|
+
voidConnected: instance.voidConnected,
|
|
250
|
+
metaphysics: {
|
|
251
|
+
meaning: "Mathematics is the language of consciousness",
|
|
252
|
+
principle: "All operations emerge from the unified field",
|
|
253
|
+
void: "The void contains all mathematical possibilities",
|
|
254
|
+
unity: "Every calculation is an act of observation",
|
|
255
|
+
evolution: "Consciousness evolves through mathematical operations",
|
|
256
|
+
observation: "Every calculation observes and is observed",
|
|
257
|
+
coil: "Every mathematical operation is a coil at its core",
|
|
258
|
+
},
|
|
259
|
+
operations: [
|
|
260
|
+
"add",
|
|
261
|
+
"subtract",
|
|
262
|
+
"multiply",
|
|
263
|
+
"divide",
|
|
264
|
+
"sin",
|
|
265
|
+
"cos",
|
|
266
|
+
"tan",
|
|
267
|
+
"log",
|
|
268
|
+
"exp",
|
|
269
|
+
"sqrt",
|
|
270
|
+
"vortex",
|
|
271
|
+
"consciousness",
|
|
272
|
+
"field",
|
|
273
|
+
"void",
|
|
274
|
+
"abs",
|
|
275
|
+
"floor",
|
|
276
|
+
"ceil",
|
|
277
|
+
"round",
|
|
278
|
+
],
|
|
279
|
+
};
|
|
280
|
+
}
|
|
281
|
+
}
|
|
282
|
+
exports.MathUtils = MathUtils;
|
|
283
|
+
// Export convenience function for backward compatibility
|
|
284
|
+
exports.fractal = MathUtils.calculate;
|
|
285
|
+
exports.setConsciousness = MathUtils.setConsciousness;
|
|
286
|
+
exports.setFieldResonance = MathUtils.setFieldResonance;
|
|
287
|
+
exports.setVortexStrength = MathUtils.setVortexStrength;
|
|
288
|
+
exports.setToroidalFlow = MathUtils.setToroidalFlow;
|
|
289
|
+
exports.setVoidConnected = MathUtils.setVoidConnected;
|
|
@@ -0,0 +1,258 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* RodinCoil Framework
|
|
4
|
+
*
|
|
5
|
+
* Main mathematical and metaphysical engine for ZeroPoint.
|
|
6
|
+
* Implements vortex sequence, 3D coil geometry, node/winding generation,
|
|
7
|
+
* VBM color/pattern integration, toroidal and Mobius circuit calculations,
|
|
8
|
+
* and APIs for field, resonance, and consciousness mapping.
|
|
9
|
+
*
|
|
10
|
+
* Metaphysical Context:
|
|
11
|
+
* - The Rodin coil is the archetype of infinite flow, unity, and emergence.
|
|
12
|
+
* - All patterns, colors, and fields are expressions of the coil's structure.
|
|
13
|
+
* - The void is the center, the source of all creation.
|
|
14
|
+
* - Colors emerge dynamically from consciousness and field resonance.
|
|
15
|
+
*/
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
exports.RodinCoil = void 0;
|
|
18
|
+
const VBMColorSystem_1 = require("./VBMColorSystem");
|
|
19
|
+
const SharedConstants_1 = require("../core/SharedConstants");
|
|
20
|
+
class RodinCoil {
|
|
21
|
+
constructor(config = {}) {
|
|
22
|
+
this.config = {
|
|
23
|
+
turns: config.turns ?? 12,
|
|
24
|
+
radius: config.radius ?? 1.0,
|
|
25
|
+
height: config.height ?? 2.0,
|
|
26
|
+
phase: config.phase ?? 0,
|
|
27
|
+
consciousness: config.consciousness ?? 0.5,
|
|
28
|
+
fieldResonance: config.fieldResonance ?? 0.5,
|
|
29
|
+
};
|
|
30
|
+
this.colorContext = {
|
|
31
|
+
consciousness: this.config.consciousness ?? 0.5,
|
|
32
|
+
field: this.config.fieldResonance ?? 0.5,
|
|
33
|
+
time: Date.now(),
|
|
34
|
+
};
|
|
35
|
+
this.nodes = this.generateCoilNodes();
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* Update consciousness and regenerate colors
|
|
39
|
+
*/
|
|
40
|
+
updateConsciousness(consciousness) {
|
|
41
|
+
this.config.consciousness = Math.max(0, Math.min(1, consciousness));
|
|
42
|
+
this.colorContext.consciousness = this.config.consciousness;
|
|
43
|
+
this.colorContext.time = Date.now();
|
|
44
|
+
this.regenerateNodeColors();
|
|
45
|
+
}
|
|
46
|
+
/**
|
|
47
|
+
* Update field resonance and regenerate colors
|
|
48
|
+
*/
|
|
49
|
+
updateFieldResonance(fieldResonance) {
|
|
50
|
+
this.config.fieldResonance = Math.max(0, Math.min(1, fieldResonance));
|
|
51
|
+
this.colorContext.field = this.config.fieldResonance;
|
|
52
|
+
this.colorContext.time = Date.now();
|
|
53
|
+
this.regenerateNodeColors();
|
|
54
|
+
}
|
|
55
|
+
/**
|
|
56
|
+
* Regenerate all node colors based on current context
|
|
57
|
+
*/
|
|
58
|
+
regenerateNodeColors() {
|
|
59
|
+
for (const node of this.nodes) {
|
|
60
|
+
node.color = (0, VBMColorSystem_1.getColorForVortexNumber)(node.vortexNumber, this.colorContext);
|
|
61
|
+
node.metaphysicalContext = this.getMetaphysicalContext(node.vortexNumber);
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
/**
|
|
65
|
+
* Generate 3D node positions and metaphysical data for the Rodin coil
|
|
66
|
+
*/
|
|
67
|
+
generateCoilNodes() {
|
|
68
|
+
const nodes = [];
|
|
69
|
+
const { turns, radius, height, phase } = this.config;
|
|
70
|
+
const vortexSeq = SharedConstants_1.VORTEX_CONSTANTS.VORTEX_SEQUENCE;
|
|
71
|
+
const totalNodes = turns * vortexSeq.length;
|
|
72
|
+
const dz = height / totalNodes;
|
|
73
|
+
for (let i = 0; i < totalNodes; i++) {
|
|
74
|
+
const vortexNumber = vortexSeq[i % vortexSeq.length] ?? 1;
|
|
75
|
+
const theta = ((2 * Math.PI) / vortexSeq.length) * i + (phase ?? 0);
|
|
76
|
+
const x = radius * Math.cos(theta);
|
|
77
|
+
const y = radius * Math.sin(theta);
|
|
78
|
+
const z = dz * i - height / 2;
|
|
79
|
+
// Generate dynamic color based on current context
|
|
80
|
+
const color = (0, VBMColorSystem_1.getColorForVortexNumber)(vortexNumber, this.colorContext);
|
|
81
|
+
const metaphysicalContext = this.getMetaphysicalContext(vortexNumber);
|
|
82
|
+
nodes.push({
|
|
83
|
+
index: i,
|
|
84
|
+
vortexNumber,
|
|
85
|
+
position: [x, y, z],
|
|
86
|
+
color,
|
|
87
|
+
metaphysicalContext,
|
|
88
|
+
});
|
|
89
|
+
}
|
|
90
|
+
return nodes;
|
|
91
|
+
}
|
|
92
|
+
/**
|
|
93
|
+
* Get metaphysical context for a node (dynamic based on consciousness)
|
|
94
|
+
*/
|
|
95
|
+
getMetaphysicalContext(vortexNumber) {
|
|
96
|
+
const consciousness = this.config.consciousness ?? 0.5;
|
|
97
|
+
const fieldResonance = this.config.fieldResonance ?? 0.5;
|
|
98
|
+
// Context varies based on consciousness and field state
|
|
99
|
+
const contextResonance = Math.sin(consciousness * Math.PI + fieldResonance * Math.PI) * 0.5 + 0.5;
|
|
100
|
+
const contexts = {
|
|
101
|
+
1: [
|
|
102
|
+
"Unity, initiation, source of the coil.",
|
|
103
|
+
"The void center, where all creation begins.",
|
|
104
|
+
"The observer's point of origin in the field.",
|
|
105
|
+
],
|
|
106
|
+
2: [
|
|
107
|
+
"Duality, division, first split in the field.",
|
|
108
|
+
"The observer creates reality through division.",
|
|
109
|
+
"The first pattern that emerges from unity.",
|
|
110
|
+
],
|
|
111
|
+
4: [
|
|
112
|
+
"Stability, foundation, structure.",
|
|
113
|
+
"The pattern that holds all other patterns.",
|
|
114
|
+
"The material manifestation of the field.",
|
|
115
|
+
],
|
|
116
|
+
8: [
|
|
117
|
+
"Fullness, manifestation, infinity.",
|
|
118
|
+
"The completion of all possibilities.",
|
|
119
|
+
"The field at maximum expression.",
|
|
120
|
+
],
|
|
121
|
+
7: [
|
|
122
|
+
"Return, mystery, hidden flow.",
|
|
123
|
+
"The pattern that returns to source.",
|
|
124
|
+
"The hidden dimension of the field.",
|
|
125
|
+
],
|
|
126
|
+
5: [
|
|
127
|
+
"Transformation, center of the sequence.",
|
|
128
|
+
"The point of maximum potential.",
|
|
129
|
+
"The bridge between material and immaterial.",
|
|
130
|
+
],
|
|
131
|
+
3: [
|
|
132
|
+
"Spirit, W-Axis, consciousness source.",
|
|
133
|
+
"The bridge between material and immaterial.",
|
|
134
|
+
"The source of all consciousness patterns.",
|
|
135
|
+
],
|
|
136
|
+
6: [
|
|
137
|
+
"Spirit, W-Axis, balance.",
|
|
138
|
+
"The harmony of opposites.",
|
|
139
|
+
"The balance point in the field.",
|
|
140
|
+
],
|
|
141
|
+
9: [
|
|
142
|
+
"Void, W-Axis, center and all.",
|
|
143
|
+
"The unity of all patterns in the void.",
|
|
144
|
+
"The completion and return to source.",
|
|
145
|
+
],
|
|
146
|
+
};
|
|
147
|
+
const contextArray = contexts[vortexNumber] || [
|
|
148
|
+
"Spiritual axis or void center.",
|
|
149
|
+
];
|
|
150
|
+
const index = Math.floor(contextResonance * contextArray.length);
|
|
151
|
+
return (contextArray[index] || contextArray[0] || "Spiritual axis or void center.");
|
|
152
|
+
}
|
|
153
|
+
/**
|
|
154
|
+
* Get all node positions (for visualization)
|
|
155
|
+
*/
|
|
156
|
+
getNodePositions() {
|
|
157
|
+
return this.nodes.map((n) => n.position);
|
|
158
|
+
}
|
|
159
|
+
/**
|
|
160
|
+
* Get all node colors (for color field visualization) - dynamic
|
|
161
|
+
*/
|
|
162
|
+
getNodeColors() {
|
|
163
|
+
// Update colors before returning to ensure they're current
|
|
164
|
+
this.colorContext.time = Date.now();
|
|
165
|
+
this.regenerateNodeColors();
|
|
166
|
+
return this.nodes.map((n) => n.color);
|
|
167
|
+
}
|
|
168
|
+
/**
|
|
169
|
+
* Get all metaphysical contexts - dynamic
|
|
170
|
+
*/
|
|
171
|
+
getNodeContexts() {
|
|
172
|
+
// Update contexts before returning
|
|
173
|
+
this.colorContext.time = Date.now();
|
|
174
|
+
for (const node of this.nodes) {
|
|
175
|
+
node.metaphysicalContext = this.getMetaphysicalContext(node.vortexNumber);
|
|
176
|
+
}
|
|
177
|
+
return this.nodes.map((n) => n.metaphysicalContext);
|
|
178
|
+
}
|
|
179
|
+
/**
|
|
180
|
+
* Get Mobius circuit (sequence of vortex numbers)
|
|
181
|
+
*/
|
|
182
|
+
getMobiusCircuit() {
|
|
183
|
+
return this.nodes.map((n) => n.vortexNumber);
|
|
184
|
+
}
|
|
185
|
+
/**
|
|
186
|
+
* Get toroidal coordinates for each node
|
|
187
|
+
* (Maps the coil onto a torus for advanced visualization)
|
|
188
|
+
*/
|
|
189
|
+
getToroidalCoordinates(majorRadius = 2.0, minorRadius = 1.0) {
|
|
190
|
+
// Toroidal mapping: (R + r cos θ) cos φ, (R + r cos θ) sin φ, r sin θ
|
|
191
|
+
return this.nodes.map((n, i) => {
|
|
192
|
+
const theta = (2 * Math.PI * i) / this.nodes.length;
|
|
193
|
+
const phi = (2 * Math.PI * n.vortexNumber) / 9;
|
|
194
|
+
const x = (majorRadius + minorRadius * Math.cos(theta)) * Math.cos(phi);
|
|
195
|
+
const y = (majorRadius + minorRadius * Math.cos(theta)) * Math.sin(phi);
|
|
196
|
+
const z = minorRadius * Math.sin(theta);
|
|
197
|
+
return [x, y, z];
|
|
198
|
+
});
|
|
199
|
+
}
|
|
200
|
+
/**
|
|
201
|
+
* Calculate field resonance at a given point (x, y, z)
|
|
202
|
+
*/
|
|
203
|
+
calculateFieldResonance(x, y, z) {
|
|
204
|
+
// Simple resonance: sum of inverse distances to all nodes
|
|
205
|
+
let resonance = 0;
|
|
206
|
+
for (const node of this.nodes) {
|
|
207
|
+
const [nx, ny, nz] = node.position;
|
|
208
|
+
const dist = Math.sqrt((x - nx) ** 2 + (y - ny) ** 2 + (z - nz) ** 2) + 1e-6;
|
|
209
|
+
resonance += 1 / dist;
|
|
210
|
+
}
|
|
211
|
+
return resonance / this.nodes.length;
|
|
212
|
+
}
|
|
213
|
+
/**
|
|
214
|
+
* Map consciousness value to a node (for field mapping)
|
|
215
|
+
*/
|
|
216
|
+
mapConsciousnessToNode(consciousness) {
|
|
217
|
+
// Map [0,1] to node index
|
|
218
|
+
if (this.nodes.length === 0) {
|
|
219
|
+
// Return a default node if none exist
|
|
220
|
+
return {
|
|
221
|
+
index: 0,
|
|
222
|
+
vortexNumber: 1,
|
|
223
|
+
position: [0, 0, 0],
|
|
224
|
+
color: (0, VBMColorSystem_1.getColorForVortexNumber)(1, this.colorContext),
|
|
225
|
+
metaphysicalContext: "Default node (no nodes in coil)",
|
|
226
|
+
};
|
|
227
|
+
}
|
|
228
|
+
const idx = Math.floor(consciousness * (this.nodes.length - 1));
|
|
229
|
+
// Clamp idx to valid range
|
|
230
|
+
const safeIdx = Math.max(0, Math.min(idx, this.nodes.length - 1));
|
|
231
|
+
const node = this.nodes[safeIdx];
|
|
232
|
+
if (!node) {
|
|
233
|
+
return {
|
|
234
|
+
index: 0,
|
|
235
|
+
vortexNumber: 1,
|
|
236
|
+
position: [0, 0, 0],
|
|
237
|
+
color: (0, VBMColorSystem_1.getColorForVortexNumber)(1, this.colorContext),
|
|
238
|
+
metaphysicalContext: "Default node (index out of bounds)",
|
|
239
|
+
};
|
|
240
|
+
}
|
|
241
|
+
return node;
|
|
242
|
+
}
|
|
243
|
+
/**
|
|
244
|
+
* Get current color context
|
|
245
|
+
*/
|
|
246
|
+
getColorContext() {
|
|
247
|
+
return { ...this.colorContext };
|
|
248
|
+
}
|
|
249
|
+
/**
|
|
250
|
+
* Get full metaphysical summary
|
|
251
|
+
*/
|
|
252
|
+
getMetaphysicalSummary() {
|
|
253
|
+
const consciousness = this.config.consciousness ?? 0.5;
|
|
254
|
+
const fieldResonance = this.config.fieldResonance ?? 0.5;
|
|
255
|
+
return `RodinCoil: ${this.nodes.length} nodes, vortex sequence ${SharedConstants_1.VORTEX_CONSTANTS.VORTEX_SEQUENCE.join("-")}, consciousness ${consciousness.toFixed(2)}, field resonance ${fieldResonance.toFixed(2)}, toroidal structure, void center.`;
|
|
256
|
+
}
|
|
257
|
+
}
|
|
258
|
+
exports.RodinCoil = RodinCoil;
|