@stevenvo780/st-lang 4.5.1 → 4.6.0

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.
Files changed (465) hide show
  1. package/dist/bdd/index.d.ts +4 -0
  2. package/dist/bdd/index.d.ts.map +1 -0
  3. package/dist/bdd/index.js +29 -0
  4. package/dist/bdd/index.js.map +1 -0
  5. package/dist/bdd/manager.d.ts +122 -0
  6. package/dist/bdd/manager.d.ts.map +1 -0
  7. package/dist/bdd/manager.js +524 -0
  8. package/dist/bdd/manager.js.map +1 -0
  9. package/dist/bdd/types.d.ts +20 -0
  10. package/dist/bdd/types.d.ts.map +1 -0
  11. package/dist/bdd/types.js +28 -0
  12. package/dist/bdd/types.js.map +1 -0
  13. package/dist/categorical/fin-set.d.ts +39 -0
  14. package/dist/categorical/fin-set.d.ts.map +1 -0
  15. package/dist/categorical/fin-set.js +217 -0
  16. package/dist/categorical/fin-set.js.map +1 -0
  17. package/dist/categorical/free.d.ts +23 -0
  18. package/dist/categorical/free.d.ts.map +1 -0
  19. package/dist/categorical/free.js +168 -0
  20. package/dist/categorical/free.js.map +1 -0
  21. package/dist/categorical/functor.d.ts +40 -0
  22. package/dist/categorical/functor.d.ts.map +1 -0
  23. package/dist/categorical/functor.js +139 -0
  24. package/dist/categorical/functor.js.map +1 -0
  25. package/dist/categorical/index.d.ts +11 -0
  26. package/dist/categorical/index.d.ts.map +1 -0
  27. package/dist/categorical/index.js +33 -0
  28. package/dist/categorical/index.js.map +1 -0
  29. package/dist/categorical/limits.d.ts +64 -0
  30. package/dist/categorical/limits.d.ts.map +1 -0
  31. package/dist/categorical/limits.js +248 -0
  32. package/dist/categorical/limits.js.map +1 -0
  33. package/dist/categorical/monoidal.d.ts +14 -0
  34. package/dist/categorical/monoidal.d.ts.map +1 -0
  35. package/dist/categorical/monoidal.js +148 -0
  36. package/dist/categorical/monoidal.js.map +1 -0
  37. package/dist/categorical/poset.d.ts +14 -0
  38. package/dist/categorical/poset.d.ts.map +1 -0
  39. package/dist/categorical/poset.js +115 -0
  40. package/dist/categorical/poset.js.map +1 -0
  41. package/dist/categorical/types.d.ts +111 -0
  42. package/dist/categorical/types.d.ts.map +1 -0
  43. package/dist/categorical/types.js +15 -0
  44. package/dist/categorical/types.js.map +1 -0
  45. package/dist/csp-hoare/analysis.d.ts +51 -0
  46. package/dist/csp-hoare/analysis.d.ts.map +1 -0
  47. package/dist/csp-hoare/analysis.js +317 -0
  48. package/dist/csp-hoare/analysis.js.map +1 -0
  49. package/dist/csp-hoare/examples.d.ts +33 -0
  50. package/dist/csp-hoare/examples.d.ts.map +1 -0
  51. package/dist/csp-hoare/examples.js +108 -0
  52. package/dist/csp-hoare/examples.js.map +1 -0
  53. package/dist/csp-hoare/index.d.ts +6 -0
  54. package/dist/csp-hoare/index.d.ts.map +1 -0
  55. package/dist/csp-hoare/index.js +50 -0
  56. package/dist/csp-hoare/index.js.map +1 -0
  57. package/dist/csp-hoare/semantics.d.ts +49 -0
  58. package/dist/csp-hoare/semantics.d.ts.map +1 -0
  59. package/dist/csp-hoare/semantics.js +494 -0
  60. package/dist/csp-hoare/semantics.js.map +1 -0
  61. package/dist/csp-hoare/types.d.ts +60 -0
  62. package/dist/csp-hoare/types.d.ts.map +1 -0
  63. package/dist/csp-hoare/types.js +31 -0
  64. package/dist/csp-hoare/types.js.map +1 -0
  65. package/dist/game-theory/common-games.d.ts +50 -0
  66. package/dist/game-theory/common-games.d.ts.map +1 -0
  67. package/dist/game-theory/common-games.js +112 -0
  68. package/dist/game-theory/common-games.js.map +1 -0
  69. package/dist/game-theory/dominance.d.ts +26 -0
  70. package/dist/game-theory/dominance.d.ts.map +1 -0
  71. package/dist/game-theory/dominance.js +203 -0
  72. package/dist/game-theory/dominance.js.map +1 -0
  73. package/dist/game-theory/index.d.ts +8 -0
  74. package/dist/game-theory/index.d.ts.map +1 -0
  75. package/dist/game-theory/index.js +47 -0
  76. package/dist/game-theory/index.js.map +1 -0
  77. package/dist/game-theory/lemke-howson.d.ts +3 -0
  78. package/dist/game-theory/lemke-howson.d.ts.map +1 -0
  79. package/dist/game-theory/lemke-howson.js +269 -0
  80. package/dist/game-theory/lemke-howson.js.map +1 -0
  81. package/dist/game-theory/linalg.d.ts +7 -0
  82. package/dist/game-theory/linalg.d.ts.map +1 -0
  83. package/dist/game-theory/linalg.js +69 -0
  84. package/dist/game-theory/linalg.js.map +1 -0
  85. package/dist/game-theory/pure-nash.d.ts +3 -0
  86. package/dist/game-theory/pure-nash.d.ts.map +1 -0
  87. package/dist/game-theory/pure-nash.js +86 -0
  88. package/dist/game-theory/pure-nash.js.map +1 -0
  89. package/dist/game-theory/support-enumeration.d.ts +3 -0
  90. package/dist/game-theory/support-enumeration.d.ts.map +1 -0
  91. package/dist/game-theory/support-enumeration.js +214 -0
  92. package/dist/game-theory/support-enumeration.js.map +1 -0
  93. package/dist/game-theory/types.d.ts +57 -0
  94. package/dist/game-theory/types.d.ts.map +1 -0
  95. package/dist/game-theory/types.js +191 -0
  96. package/dist/game-theory/types.js.map +1 -0
  97. package/dist/hindley-milner/index.d.ts +7 -0
  98. package/dist/hindley-milner/index.d.ts.map +1 -0
  99. package/dist/hindley-milner/index.js +60 -0
  100. package/dist/hindley-milner/index.js.map +1 -0
  101. package/dist/hindley-milner/infer.d.ts +26 -0
  102. package/dist/hindley-milner/infer.d.ts.map +1 -0
  103. package/dist/hindley-milner/infer.js +278 -0
  104. package/dist/hindley-milner/infer.js.map +1 -0
  105. package/dist/hindley-milner/substitution.d.ts +21 -0
  106. package/dist/hindley-milner/substitution.d.ts.map +1 -0
  107. package/dist/hindley-milner/substitution.js +215 -0
  108. package/dist/hindley-milner/substitution.js.map +1 -0
  109. package/dist/hindley-milner/types.d.ts +84 -0
  110. package/dist/hindley-milner/types.d.ts.map +1 -0
  111. package/dist/hindley-milner/types.js +166 -0
  112. package/dist/hindley-milner/types.js.map +1 -0
  113. package/dist/hott/equality.d.ts +4 -0
  114. package/dist/hott/equality.d.ts.map +1 -0
  115. package/dist/hott/equality.js +108 -0
  116. package/dist/hott/equality.js.map +1 -0
  117. package/dist/hott/index.d.ts +13 -0
  118. package/dist/hott/index.d.ts.map +1 -0
  119. package/dist/hott/index.js +77 -0
  120. package/dist/hott/index.js.map +1 -0
  121. package/dist/hott/infer.d.ts +11 -0
  122. package/dist/hott/infer.d.ts.map +1 -0
  123. package/dist/hott/infer.js +465 -0
  124. package/dist/hott/infer.js.map +1 -0
  125. package/dist/hott/normalize.d.ts +5 -0
  126. package/dist/hott/normalize.d.ts.map +1 -0
  127. package/dist/hott/normalize.js +240 -0
  128. package/dist/hott/normalize.js.map +1 -0
  129. package/dist/hott/path-algebra.d.ts +25 -0
  130. package/dist/hott/path-algebra.d.ts.map +1 -0
  131. package/dist/hott/path-algebra.js +67 -0
  132. package/dist/hott/path-algebra.js.map +1 -0
  133. package/dist/hott/substitute.d.ts +3 -0
  134. package/dist/hott/substitute.d.ts.map +1 -0
  135. package/dist/hott/substitute.js +131 -0
  136. package/dist/hott/substitute.js.map +1 -0
  137. package/dist/hott/types.d.ts +126 -0
  138. package/dist/hott/types.d.ts.map +1 -0
  139. package/dist/hott/types.js +346 -0
  140. package/dist/hott/types.js.map +1 -0
  141. package/dist/index.d.ts +16 -1
  142. package/dist/index.d.ts.map +1 -1
  143. package/dist/index.js +83 -3
  144. package/dist/index.js.map +1 -1
  145. package/dist/information-theory/index.d.ts +29 -0
  146. package/dist/information-theory/index.d.ts.map +1 -0
  147. package/dist/information-theory/index.js +323 -0
  148. package/dist/information-theory/index.js.map +1 -0
  149. package/dist/lemma-synthesis/index.d.ts +124 -0
  150. package/dist/lemma-synthesis/index.d.ts.map +1 -0
  151. package/dist/lemma-synthesis/index.js +640 -0
  152. package/dist/lemma-synthesis/index.js.map +1 -0
  153. package/dist/namespaces/logic.d.ts +42 -0
  154. package/dist/namespaces/logic.d.ts.map +1 -0
  155. package/dist/namespaces/logic.js +112 -0
  156. package/dist/namespaces/logic.js.map +1 -0
  157. package/dist/namespaces/proof-systems.d.ts +18 -0
  158. package/dist/namespaces/proof-systems.d.ts.map +1 -0
  159. package/dist/namespaces/proof-systems.js +59 -0
  160. package/dist/namespaces/proof-systems.js.map +1 -0
  161. package/dist/namespaces/reasoning.d.ts +26 -0
  162. package/dist/namespaces/reasoning.d.ts.map +1 -0
  163. package/dist/namespaces/reasoning.js +72 -0
  164. package/dist/namespaces/reasoning.js.map +1 -0
  165. package/dist/namespaces/semantics.d.ts +21 -0
  166. package/dist/namespaces/semantics.d.ts.map +1 -0
  167. package/dist/namespaces/semantics.js +64 -0
  168. package/dist/namespaces/semantics.js.map +1 -0
  169. package/dist/namespaces/solvers.d.ts +22 -0
  170. package/dist/namespaces/solvers.d.ts.map +1 -0
  171. package/dist/namespaces/solvers.js +66 -0
  172. package/dist/namespaces/solvers.js.map +1 -0
  173. package/dist/namespaces/type-theory.d.ts +22 -0
  174. package/dist/namespaces/type-theory.d.ts.map +1 -0
  175. package/dist/namespaces/type-theory.js +65 -0
  176. package/dist/namespaces/type-theory.js.map +1 -0
  177. package/dist/optimization/branch-and-bound.d.ts +11 -0
  178. package/dist/optimization/branch-and-bound.d.ts.map +1 -0
  179. package/dist/optimization/branch-and-bound.js +311 -0
  180. package/dist/optimization/branch-and-bound.js.map +1 -0
  181. package/dist/optimization/index.d.ts +5 -0
  182. package/dist/optimization/index.d.ts.map +1 -0
  183. package/dist/optimization/index.js +20 -0
  184. package/dist/optimization/index.js.map +1 -0
  185. package/dist/optimization/simplex.d.ts +8 -0
  186. package/dist/optimization/simplex.d.ts.map +1 -0
  187. package/dist/optimization/simplex.js +408 -0
  188. package/dist/optimization/simplex.js.map +1 -0
  189. package/dist/optimization/standard-form.d.ts +11 -0
  190. package/dist/optimization/standard-form.d.ts.map +1 -0
  191. package/dist/optimization/standard-form.js +112 -0
  192. package/dist/optimization/standard-form.js.map +1 -0
  193. package/dist/optimization/types.d.ts +44 -0
  194. package/dist/optimization/types.d.ts.map +1 -0
  195. package/dist/optimization/types.js +15 -0
  196. package/dist/optimization/types.js.map +1 -0
  197. package/dist/profiles/hol/connectives.d.ts +46 -0
  198. package/dist/profiles/hol/connectives.d.ts.map +1 -0
  199. package/dist/profiles/hol/connectives.js +104 -0
  200. package/dist/profiles/hol/connectives.js.map +1 -0
  201. package/dist/profiles/hol/index.d.ts +7 -0
  202. package/dist/profiles/hol/index.d.ts.map +1 -0
  203. package/dist/profiles/hol/index.js +77 -0
  204. package/dist/profiles/hol/index.js.map +1 -0
  205. package/dist/profiles/hol/rules.d.ts +31 -0
  206. package/dist/profiles/hol/rules.d.ts.map +1 -0
  207. package/dist/profiles/hol/rules.js +258 -0
  208. package/dist/profiles/hol/rules.js.map +1 -0
  209. package/dist/profiles/hol/term.d.ts +52 -0
  210. package/dist/profiles/hol/term.d.ts.map +1 -0
  211. package/dist/profiles/hol/term.js +345 -0
  212. package/dist/profiles/hol/term.js.map +1 -0
  213. package/dist/profiles/hol/type-system.d.ts +38 -0
  214. package/dist/profiles/hol/type-system.d.ts.map +1 -0
  215. package/dist/profiles/hol/type-system.js +133 -0
  216. package/dist/profiles/hol/type-system.js.map +1 -0
  217. package/dist/profiles/hol/types.d.ts +59 -0
  218. package/dist/profiles/hol/types.d.ts.map +1 -0
  219. package/dist/profiles/hol/types.js +26 -0
  220. package/dist/profiles/hol/types.js.map +1 -0
  221. package/dist/smt-lib/ast.d.ts +138 -0
  222. package/dist/smt-lib/ast.d.ts.map +1 -0
  223. package/dist/smt-lib/ast.js +73 -0
  224. package/dist/smt-lib/ast.js.map +1 -0
  225. package/dist/smt-lib/emitter.d.ts +12 -0
  226. package/dist/smt-lib/emitter.d.ts.map +1 -0
  227. package/dist/smt-lib/emitter.js +174 -0
  228. package/dist/smt-lib/emitter.js.map +1 -0
  229. package/dist/smt-lib/index.d.ts +6 -0
  230. package/dist/smt-lib/index.d.ts.map +1 -0
  231. package/dist/smt-lib/index.js +31 -0
  232. package/dist/smt-lib/index.js.map +1 -0
  233. package/dist/smt-lib/parser.d.ts +13 -0
  234. package/dist/smt-lib/parser.d.ts.map +1 -0
  235. package/dist/smt-lib/parser.js +614 -0
  236. package/dist/smt-lib/parser.js.map +1 -0
  237. package/dist/smt-lib/tokenizer.d.ts +16 -0
  238. package/dist/smt-lib/tokenizer.d.ts.map +1 -0
  239. package/dist/smt-lib/tokenizer.js +234 -0
  240. package/dist/smt-lib/tokenizer.js.map +1 -0
  241. package/dist/tactic-dsl/combinators.d.ts +6 -0
  242. package/dist/tactic-dsl/combinators.d.ts.map +1 -0
  243. package/dist/tactic-dsl/combinators.js +98 -0
  244. package/dist/tactic-dsl/combinators.js.map +1 -0
  245. package/dist/tactic-dsl/index.d.ts +39 -0
  246. package/dist/tactic-dsl/index.d.ts.map +1 -0
  247. package/dist/tactic-dsl/index.js +162 -0
  248. package/dist/tactic-dsl/index.js.map +1 -0
  249. package/dist/tactic-dsl/tactics.d.ts +21 -0
  250. package/dist/tactic-dsl/tactics.d.ts.map +1 -0
  251. package/dist/tactic-dsl/tactics.js +536 -0
  252. package/dist/tactic-dsl/tactics.js.map +1 -0
  253. package/dist/tactic-dsl/types.d.ts +54 -0
  254. package/dist/tactic-dsl/types.d.ts.map +1 -0
  255. package/dist/tactic-dsl/types.js +226 -0
  256. package/dist/tactic-dsl/types.js.map +1 -0
  257. package/dist/tests/api/namespaces.test.d.ts +9 -0
  258. package/dist/tests/api/namespaces.test.d.ts.map +1 -0
  259. package/dist/tests/api/namespaces.test.js +218 -0
  260. package/dist/tests/api/namespaces.test.js.map +1 -0
  261. package/dist/tests/bdd/manager.test.d.ts +2 -0
  262. package/dist/tests/bdd/manager.test.d.ts.map +1 -0
  263. package/dist/tests/bdd/manager.test.js +472 -0
  264. package/dist/tests/bdd/manager.test.js.map +1 -0
  265. package/dist/tests/categorical/categorical.test.d.ts +2 -0
  266. package/dist/tests/categorical/categorical.test.d.ts.map +1 -0
  267. package/dist/tests/categorical/categorical.test.js +300 -0
  268. package/dist/tests/categorical/categorical.test.js.map +1 -0
  269. package/dist/tests/csp-hoare/csp-hoare.test.d.ts +2 -0
  270. package/dist/tests/csp-hoare/csp-hoare.test.d.ts.map +1 -0
  271. package/dist/tests/csp-hoare/csp-hoare.test.js +313 -0
  272. package/dist/tests/csp-hoare/csp-hoare.test.js.map +1 -0
  273. package/dist/tests/game-theory/game-theory.test.d.ts +2 -0
  274. package/dist/tests/game-theory/game-theory.test.d.ts.map +1 -0
  275. package/dist/tests/game-theory/game-theory.test.js +252 -0
  276. package/dist/tests/game-theory/game-theory.test.js.map +1 -0
  277. package/dist/tests/hindley-milner/hindley-milner.test.d.ts +2 -0
  278. package/dist/tests/hindley-milner/hindley-milner.test.d.ts.map +1 -0
  279. package/dist/tests/hindley-milner/hindley-milner.test.js +327 -0
  280. package/dist/tests/hindley-milner/hindley-milner.test.js.map +1 -0
  281. package/dist/tests/hol/hol.test.d.ts +2 -0
  282. package/dist/tests/hol/hol.test.d.ts.map +1 -0
  283. package/dist/tests/hol/hol.test.js +340 -0
  284. package/dist/tests/hol/hol.test.js.map +1 -0
  285. package/dist/tests/hott/hott.test.d.ts +2 -0
  286. package/dist/tests/hott/hott.test.d.ts.map +1 -0
  287. package/dist/tests/hott/hott.test.js +271 -0
  288. package/dist/tests/hott/hott.test.js.map +1 -0
  289. package/dist/tests/information-theory/information-theory.test.d.ts +2 -0
  290. package/dist/tests/information-theory/information-theory.test.d.ts.map +1 -0
  291. package/dist/tests/information-theory/information-theory.test.js +291 -0
  292. package/dist/tests/information-theory/information-theory.test.js.map +1 -0
  293. package/dist/tests/lemma-synthesis/lemma-synthesis.test.d.ts +2 -0
  294. package/dist/tests/lemma-synthesis/lemma-synthesis.test.d.ts.map +1 -0
  295. package/dist/tests/lemma-synthesis/lemma-synthesis.test.js +460 -0
  296. package/dist/tests/lemma-synthesis/lemma-synthesis.test.js.map +1 -0
  297. package/dist/tests/optimization/ilp.test.d.ts +2 -0
  298. package/dist/tests/optimization/ilp.test.d.ts.map +1 -0
  299. package/dist/tests/optimization/ilp.test.js +204 -0
  300. package/dist/tests/optimization/ilp.test.js.map +1 -0
  301. package/dist/tests/optimization/lp.test.d.ts +2 -0
  302. package/dist/tests/optimization/lp.test.d.ts.map +1 -0
  303. package/dist/tests/optimization/lp.test.js +224 -0
  304. package/dist/tests/optimization/lp.test.js.map +1 -0
  305. package/dist/tests/properties/agm.property.test.d.ts +2 -0
  306. package/dist/tests/properties/agm.property.test.d.ts.map +1 -0
  307. package/dist/tests/properties/agm.property.test.js +75 -0
  308. package/dist/tests/properties/agm.property.test.js.map +1 -0
  309. package/dist/tests/properties/anti-unification.property.test.d.ts +2 -0
  310. package/dist/tests/properties/anti-unification.property.test.d.ts.map +1 -0
  311. package/dist/tests/properties/anti-unification.property.test.js +43 -0
  312. package/dist/tests/properties/anti-unification.property.test.js.map +1 -0
  313. package/dist/tests/properties/argumentation.property.test.d.ts +2 -0
  314. package/dist/tests/properties/argumentation.property.test.d.ts.map +1 -0
  315. package/dist/tests/properties/argumentation.property.test.js +51 -0
  316. package/dist/tests/properties/argumentation.property.test.js.map +1 -0
  317. package/dist/tests/properties/bayesian.property.test.d.ts +2 -0
  318. package/dist/tests/properties/bayesian.property.test.d.ts.map +1 -0
  319. package/dist/tests/properties/bayesian.property.test.js +32 -0
  320. package/dist/tests/properties/bayesian.property.test.js.map +1 -0
  321. package/dist/tests/properties/bisimulation.property.test.d.ts +2 -0
  322. package/dist/tests/properties/bisimulation.property.test.d.ts.map +1 -0
  323. package/dist/tests/properties/bisimulation.property.test.js +50 -0
  324. package/dist/tests/properties/bisimulation.property.test.js.map +1 -0
  325. package/dist/tests/properties/cdcl.property.test.d.ts +2 -0
  326. package/dist/tests/properties/cdcl.property.test.d.ts.map +1 -0
  327. package/dist/tests/properties/cdcl.property.test.js +70 -0
  328. package/dist/tests/properties/cdcl.property.test.js.map +1 -0
  329. package/dist/tests/properties/coinduction.property.test.d.ts +2 -0
  330. package/dist/tests/properties/coinduction.property.test.d.ts.map +1 -0
  331. package/dist/tests/properties/coinduction.property.test.js +34 -0
  332. package/dist/tests/properties/coinduction.property.test.js.map +1 -0
  333. package/dist/tests/properties/constructive-reals.property.test.d.ts +2 -0
  334. package/dist/tests/properties/constructive-reals.property.test.d.ts.map +1 -0
  335. package/dist/tests/properties/constructive-reals.property.test.js +59 -0
  336. package/dist/tests/properties/constructive-reals.property.test.js.map +1 -0
  337. package/dist/tests/properties/csp.property.test.d.ts +2 -0
  338. package/dist/tests/properties/csp.property.test.d.ts.map +1 -0
  339. package/dist/tests/properties/csp.property.test.js +58 -0
  340. package/dist/tests/properties/csp.property.test.js.map +1 -0
  341. package/dist/tests/properties/generators.d.ts +78 -0
  342. package/dist/tests/properties/generators.d.ts.map +1 -0
  343. package/dist/tests/properties/generators.js +348 -0
  344. package/dist/tests/properties/generators.js.map +1 -0
  345. package/dist/tests/properties/ho-unify.property.test.d.ts +2 -0
  346. package/dist/tests/properties/ho-unify.property.test.d.ts.map +1 -0
  347. package/dist/tests/properties/ho-unify.property.test.js +46 -0
  348. package/dist/tests/properties/ho-unify.property.test.js.map +1 -0
  349. package/dist/tests/properties/hyperreal.property.test.d.ts +2 -0
  350. package/dist/tests/properties/hyperreal.property.test.d.ts.map +1 -0
  351. package/dist/tests/properties/hyperreal.property.test.js +33 -0
  352. package/dist/tests/properties/hyperreal.property.test.js.map +1 -0
  353. package/dist/tests/properties/intuit-nj.property.test.d.ts +2 -0
  354. package/dist/tests/properties/intuit-nj.property.test.d.ts.map +1 -0
  355. package/dist/tests/properties/intuit-nj.property.test.js +57 -0
  356. package/dist/tests/properties/intuit-nj.property.test.js.map +1 -0
  357. package/dist/tests/properties/lambda-calc.property.test.d.ts +2 -0
  358. package/dist/tests/properties/lambda-calc.property.test.d.ts.map +1 -0
  359. package/dist/tests/properties/lambda-calc.property.test.js +35 -0
  360. package/dist/tests/properties/lambda-calc.property.test.js.map +1 -0
  361. package/dist/tests/properties/mln.property.test.d.ts +2 -0
  362. package/dist/tests/properties/mln.property.test.d.ts.map +1 -0
  363. package/dist/tests/properties/mln.property.test.js +41 -0
  364. package/dist/tests/properties/mln.property.test.js.map +1 -0
  365. package/dist/tests/properties/mltt.property.test.d.ts +2 -0
  366. package/dist/tests/properties/mltt.property.test.d.ts.map +1 -0
  367. package/dist/tests/properties/mltt.property.test.js +33 -0
  368. package/dist/tests/properties/mltt.property.test.js.map +1 -0
  369. package/dist/tests/properties/nbe.property.test.d.ts +2 -0
  370. package/dist/tests/properties/nbe.property.test.d.ts.map +1 -0
  371. package/dist/tests/properties/nbe.property.test.js +44 -0
  372. package/dist/tests/properties/nbe.property.test.js.map +1 -0
  373. package/dist/tests/properties/planning.property.test.d.ts +2 -0
  374. package/dist/tests/properties/planning.property.test.d.ts.map +1 -0
  375. package/dist/tests/properties/planning.property.test.js +51 -0
  376. package/dist/tests/properties/planning.property.test.js.map +1 -0
  377. package/dist/tests/properties/profile-bridge.property.test.d.ts +2 -0
  378. package/dist/tests/properties/profile-bridge.property.test.d.ts.map +1 -0
  379. package/dist/tests/properties/profile-bridge.property.test.js +71 -0
  380. package/dist/tests/properties/profile-bridge.property.test.js.map +1 -0
  381. package/dist/tests/properties/refinement-types.property.test.d.ts +2 -0
  382. package/dist/tests/properties/refinement-types.property.test.d.ts.map +1 -0
  383. package/dist/tests/properties/refinement-types.property.test.js +37 -0
  384. package/dist/tests/properties/refinement-types.property.test.js.map +1 -0
  385. package/dist/tests/properties/sequent-g3.property.test.d.ts +2 -0
  386. package/dist/tests/properties/sequent-g3.property.test.d.ts.map +1 -0
  387. package/dist/tests/properties/sequent-g3.property.test.js +34 -0
  388. package/dist/tests/properties/sequent-g3.property.test.js.map +1 -0
  389. package/dist/tests/properties/symbolic-diff.property.test.d.ts +2 -0
  390. package/dist/tests/properties/symbolic-diff.property.test.d.ts.map +1 -0
  391. package/dist/tests/properties/symbolic-diff.property.test.js +49 -0
  392. package/dist/tests/properties/symbolic-diff.property.test.js.map +1 -0
  393. package/dist/tests/properties/system-f.property.test.d.ts +2 -0
  394. package/dist/tests/properties/system-f.property.test.d.ts.map +1 -0
  395. package/dist/tests/properties/system-f.property.test.js +37 -0
  396. package/dist/tests/properties/system-f.property.test.js.map +1 -0
  397. package/dist/tests/properties/theorem-cache.property.test.d.ts +2 -0
  398. package/dist/tests/properties/theorem-cache.property.test.d.ts.map +1 -0
  399. package/dist/tests/properties/theorem-cache.property.test.js +38 -0
  400. package/dist/tests/properties/theorem-cache.property.test.js.map +1 -0
  401. package/dist/tests/properties/trs.property.test.d.ts +2 -0
  402. package/dist/tests/properties/trs.property.test.d.ts.map +1 -0
  403. package/dist/tests/properties/trs.property.test.js +34 -0
  404. package/dist/tests/properties/trs.property.test.js.map +1 -0
  405. package/dist/tests/properties/unification.property.test.d.ts +2 -0
  406. package/dist/tests/properties/unification.property.test.d.ts.map +1 -0
  407. package/dist/tests/properties/unification.property.test.js +42 -0
  408. package/dist/tests/properties/unification.property.test.js.map +1 -0
  409. package/dist/tests/smt-lib/emitter.test.d.ts +2 -0
  410. package/dist/tests/smt-lib/emitter.test.d.ts.map +1 -0
  411. package/dist/tests/smt-lib/emitter.test.js +155 -0
  412. package/dist/tests/smt-lib/emitter.test.js.map +1 -0
  413. package/dist/tests/smt-lib/parser.test.d.ts +2 -0
  414. package/dist/tests/smt-lib/parser.test.d.ts.map +1 -0
  415. package/dist/tests/smt-lib/parser.test.js +164 -0
  416. package/dist/tests/smt-lib/parser.test.js.map +1 -0
  417. package/dist/tests/smt-lib/tokenizer.test.d.ts +2 -0
  418. package/dist/tests/smt-lib/tokenizer.test.d.ts.map +1 -0
  419. package/dist/tests/smt-lib/tokenizer.test.js +59 -0
  420. package/dist/tests/smt-lib/tokenizer.test.js.map +1 -0
  421. package/dist/tests/tactic-dsl/tactic-dsl.test.d.ts +2 -0
  422. package/dist/tests/tactic-dsl/tactic-dsl.test.d.ts.map +1 -0
  423. package/dist/tests/tactic-dsl/tactic-dsl.test.js +259 -0
  424. package/dist/tests/tactic-dsl/tactic-dsl.test.js.map +1 -0
  425. package/dist/tests/tptp/bridge.test.d.ts +2 -0
  426. package/dist/tests/tptp/bridge.test.d.ts.map +1 -0
  427. package/dist/tests/tptp/bridge.test.js +154 -0
  428. package/dist/tests/tptp/bridge.test.js.map +1 -0
  429. package/dist/tests/tptp/emitter.test.d.ts +2 -0
  430. package/dist/tests/tptp/emitter.test.d.ts.map +1 -0
  431. package/dist/tests/tptp/emitter.test.js +128 -0
  432. package/dist/tests/tptp/emitter.test.js.map +1 -0
  433. package/dist/tests/tptp/parser.test.d.ts +2 -0
  434. package/dist/tests/tptp/parser.test.d.ts.map +1 -0
  435. package/dist/tests/tptp/parser.test.js +192 -0
  436. package/dist/tests/tptp/parser.test.js.map +1 -0
  437. package/dist/tests/tptp/tokenizer.test.d.ts +2 -0
  438. package/dist/tests/tptp/tokenizer.test.d.ts.map +1 -0
  439. package/dist/tests/tptp/tokenizer.test.js +60 -0
  440. package/dist/tests/tptp/tokenizer.test.js.map +1 -0
  441. package/dist/tptp/ast.d.ts +73 -0
  442. package/dist/tptp/ast.d.ts.map +1 -0
  443. package/dist/tptp/ast.js +35 -0
  444. package/dist/tptp/ast.js.map +1 -0
  445. package/dist/tptp/bridge.d.ts +14 -0
  446. package/dist/tptp/bridge.d.ts.map +1 -0
  447. package/dist/tptp/bridge.js +146 -0
  448. package/dist/tptp/bridge.js.map +1 -0
  449. package/dist/tptp/emitter.d.ts +5 -0
  450. package/dist/tptp/emitter.d.ts.map +1 -0
  451. package/dist/tptp/emitter.js +103 -0
  452. package/dist/tptp/emitter.js.map +1 -0
  453. package/dist/tptp/index.d.ts +7 -0
  454. package/dist/tptp/index.d.ts.map +1 -0
  455. package/dist/tptp/index.js +31 -0
  456. package/dist/tptp/index.js.map +1 -0
  457. package/dist/tptp/parser.d.ts +23 -0
  458. package/dist/tptp/parser.d.ts.map +1 -0
  459. package/dist/tptp/parser.js +440 -0
  460. package/dist/tptp/parser.js.map +1 -0
  461. package/dist/tptp/tokenizer.d.ts +14 -0
  462. package/dist/tptp/tokenizer.d.ts.map +1 -0
  463. package/dist/tptp/tokenizer.js +264 -0
  464. package/dist/tptp/tokenizer.js.map +1 -0
  465. package/package.json +5 -1
@@ -0,0 +1,65 @@
1
+ "use strict";
2
+ /**
3
+ * Namespace: TypeTheory
4
+ *
5
+ * Sistemas de tipos y cálculos lambda — correspondencia Curry-Howard,
6
+ * System F polimórfico, MLTT (Martin-Löf), λ-calc puro, combinadores SKI,
7
+ * NBE (normalization by evaluation), refinement types.
8
+ *
9
+ * Importa así:
10
+ * import { TypeTheory } from '@stevenvo780/st-lang';
11
+ * const t = TypeTheory.systemF.typeOf(term);
12
+ * const proof = TypeTheory.curryHoward.termToProof(lam);
13
+ */
14
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
15
+ if (k2 === undefined) k2 = k;
16
+ var desc = Object.getOwnPropertyDescriptor(m, k);
17
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
18
+ desc = { enumerable: true, get: function() { return m[k]; } };
19
+ }
20
+ Object.defineProperty(o, k2, desc);
21
+ }) : (function(o, m, k, k2) {
22
+ if (k2 === undefined) k2 = k;
23
+ o[k2] = m[k];
24
+ }));
25
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
26
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
27
+ }) : function(o, v) {
28
+ o["default"] = v;
29
+ });
30
+ var __importStar = (this && this.__importStar) || (function () {
31
+ var ownKeys = function(o) {
32
+ ownKeys = Object.getOwnPropertyNames || function (o) {
33
+ var ar = [];
34
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
35
+ return ar;
36
+ };
37
+ return ownKeys(o);
38
+ };
39
+ return function (mod) {
40
+ if (mod && mod.__esModule) return mod;
41
+ var result = {};
42
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
43
+ __setModuleDefault(result, mod);
44
+ return result;
45
+ };
46
+ })();
47
+ Object.defineProperty(exports, "__esModule", { value: true });
48
+ exports.higherOrderUnify = exports.refinementTypes = exports.nbe = exports.combinatorsSKI = exports.lambdaCalc = exports.mltt = exports.systemF = exports.curryHoward = void 0;
49
+ const curryHoward = __importStar(require("../curry-howard"));
50
+ exports.curryHoward = curryHoward;
51
+ const systemF = __importStar(require("../system-f"));
52
+ exports.systemF = systemF;
53
+ const mltt = __importStar(require("../mltt"));
54
+ exports.mltt = mltt;
55
+ const lambdaCalc = __importStar(require("../lambda-calc"));
56
+ exports.lambdaCalc = lambdaCalc;
57
+ const combinatorsSKI = __importStar(require("../combinators-ski"));
58
+ exports.combinatorsSKI = combinatorsSKI;
59
+ const nbe = __importStar(require("../nbe"));
60
+ exports.nbe = nbe;
61
+ const refinementTypes = __importStar(require("../refinement-types"));
62
+ exports.refinementTypes = refinementTypes;
63
+ const higherOrderUnify = __importStar(require("../higher-order-unify"));
64
+ exports.higherOrderUnify = higherOrderUnify;
65
+ //# sourceMappingURL=type-theory.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"type-theory.js","sourceRoot":"","sources":["../../src/namespaces/type-theory.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;GAWG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEH,6DAA+C;AAU7C,kCAAW;AATb,qDAAuC;AAUrC,0BAAO;AATT,8CAAgC;AAU9B,oBAAI;AATN,2DAA6C;AAU3C,gCAAU;AATZ,mEAAqD;AAUnD,wCAAc;AAThB,4CAA8B;AAU5B,kBAAG;AATL,qEAAuD;AAUrD,0CAAe;AATjB,wEAA0D;AAUxD,4CAAgB"}
@@ -0,0 +1,11 @@
1
+ import type { ILPOptions, ILPProblem, ILPSolution, LPProblem } from './types';
2
+ /**
3
+ * Genera el LP relajado: descarta integerVars/binaryVars pero
4
+ * mantiene `variableBounds` (los binarios ya tienen [0,1] ahí).
5
+ */
6
+ export declare function lpRelaxation(ilp: ILPProblem): LPProblem;
7
+ /**
8
+ * Solver ILP principal. Estrategia DFS con pila explícita.
9
+ */
10
+ export declare function solveILP(problem: ILPProblem, opts?: ILPOptions): ILPSolution;
11
+ //# sourceMappingURL=branch-and-bound.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"branch-and-bound.d.ts","sourceRoot":"","sources":["../../src/optimization/branch-and-bound.ts"],"names":[],"mappings":"AAwBA,OAAO,KAAK,EAAE,UAAU,EAAE,UAAU,EAAE,WAAW,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AAM9E;;;GAGG;AACH,wBAAgB,YAAY,CAAC,GAAG,EAAE,UAAU,GAAG,SAAS,CA+BvD;AAmGD;;GAEG;AACH,wBAAgB,QAAQ,CAAC,OAAO,EAAE,UAAU,EAAE,IAAI,GAAE,UAAe,GAAG,WAAW,CAgKhF"}
@@ -0,0 +1,311 @@
1
+ "use strict";
2
+ // ============================================================
3
+ // Branch-and-bound para Integer Linear Programming.
4
+ // ============================================================
5
+ // Estrategia clásica:
6
+ // 1. Resolver la relajación LP. Si infactible/unbounded, salir.
7
+ // 2. Si la solución LP es entera en `integerVars`, es óptima
8
+ // del ILP y devolvemos.
9
+ // 3. Elegir la variable entera más fraccional (closest-to-0.5).
10
+ // Generar dos subproblemas añadiendo x ≤ ⌊x*⌋ y x ≥ ⌈x*⌉ a
11
+ // las restricciones originales y descender (DFS con pila).
12
+ // 4. Mantener mejor incumbent (mejor entero encontrado). Podar
13
+ // cuando el bound de la relajación es peor que el incumbent
14
+ // (más una tolerancia).
15
+ //
16
+ // Para problemas binarios (variables 0/1) las cotas adicionales
17
+ // son innecesarias porque ya están restringidas por
18
+ // `variableBounds`; aún así, la lógica B&B funciona idéntica.
19
+ //
20
+ // Limitación conocida: no detecta optimalidad por GAP=0 sin
21
+ // explorar toda la rama; el `gap` reportado es relativo al
22
+ // bound del root LP.
23
+ // ============================================================
24
+ Object.defineProperty(exports, "__esModule", { value: true });
25
+ exports.lpRelaxation = lpRelaxation;
26
+ exports.solveILP = solveILP;
27
+ const simplex_1 = require("./simplex");
28
+ const DEFAULT_MAX_NODES = 10000;
29
+ const DEFAULT_TIMEOUT_MS = 30000;
30
+ const INTEGER_TOL = 1e-6;
31
+ /**
32
+ * Genera el LP relajado: descarta integerVars/binaryVars pero
33
+ * mantiene `variableBounds` (los binarios ya tienen [0,1] ahí).
34
+ */
35
+ function lpRelaxation(ilp) {
36
+ // Si hay binarios sin cotas explícitas, las inyectamos.
37
+ const bounds = ilp.variableBounds
38
+ ? ilp.variableBounds.map((b) => ({ ...b }))
39
+ : new Array(ilp.objective.coefficients.length)
40
+ .fill({})
41
+ .map(() => ({}));
42
+ if (ilp.binaryVars) {
43
+ for (const idx of ilp.binaryVars) {
44
+ const existing = bounds[idx] ?? {};
45
+ bounds[idx] = {
46
+ lower: existing.lower ?? 0,
47
+ upper: existing.upper !== undefined ? Math.min(existing.upper, 1) : 1,
48
+ };
49
+ }
50
+ }
51
+ return {
52
+ objective: {
53
+ kind: ilp.objective.kind,
54
+ coefficients: ilp.objective.coefficients.slice(),
55
+ },
56
+ constraints: ilp.constraints.map((c) => ({
57
+ coefficients: c.coefficients.slice(),
58
+ operator: c.operator,
59
+ rhs: c.rhs,
60
+ })),
61
+ variableBounds: bounds,
62
+ variableNames: ilp.variableNames ? ilp.variableNames.slice() : undefined,
63
+ };
64
+ }
65
+ /**
66
+ * Comprueba qué variable de `integerVars` es la más fraccional en
67
+ * `x`. Devuelve `-1` si todas son enteras (dentro de la tolerancia).
68
+ */
69
+ function pickBranchVariable(x, integerVars) {
70
+ let bestIdx = -1;
71
+ let bestFrac = -1;
72
+ for (const i of integerVars) {
73
+ const v = x[i] ?? 0;
74
+ const frac = Math.abs(v - Math.round(v));
75
+ if (frac > INTEGER_TOL && frac > bestFrac) {
76
+ bestFrac = frac;
77
+ bestIdx = i;
78
+ }
79
+ }
80
+ return bestIdx;
81
+ }
82
+ /**
83
+ * Construye un nuevo LP con una restricción adicional sobre la
84
+ * variable `idx`: si `direction='floor'`, x_idx ≤ value; si
85
+ * `direction='ceil'`, x_idx ≥ value.
86
+ */
87
+ function branch(lp, idx, value, direction) {
88
+ const row = new Array(lp.objective.coefficients.length).fill(0);
89
+ row[idx] = 1;
90
+ return {
91
+ objective: {
92
+ kind: lp.objective.kind,
93
+ coefficients: lp.objective.coefficients.slice(),
94
+ },
95
+ constraints: [
96
+ ...lp.constraints.map((c) => ({
97
+ coefficients: c.coefficients.slice(),
98
+ operator: c.operator,
99
+ rhs: c.rhs,
100
+ })),
101
+ {
102
+ coefficients: row,
103
+ operator: direction === 'floor' ? '<=' : '>=',
104
+ rhs: value,
105
+ },
106
+ ],
107
+ variableBounds: lp.variableBounds ? lp.variableBounds.map((b) => ({ ...b })) : undefined,
108
+ variableNames: lp.variableNames ? lp.variableNames.slice() : undefined,
109
+ };
110
+ }
111
+ /**
112
+ * ¿La solución LP es entera (en `integerVars`) y respeta los
113
+ * binarios (en {0,1})?
114
+ */
115
+ function isIntegerSolution(x, integerVars) {
116
+ for (const i of integerVars) {
117
+ const v = x[i] ?? 0;
118
+ if (Math.abs(v - Math.round(v)) > INTEGER_TOL)
119
+ return false;
120
+ }
121
+ return true;
122
+ }
123
+ /**
124
+ * Redondea las componentes enteras de `x` (ya verificadas como
125
+ * casi-enteras) para limpiar ruido numérico.
126
+ */
127
+ function roundIntegers(x, integerVars) {
128
+ const out = x.slice();
129
+ for (const i of integerVars) {
130
+ const v = out[i];
131
+ if (v !== undefined)
132
+ out[i] = Math.round(v);
133
+ }
134
+ return out;
135
+ }
136
+ /**
137
+ * ¿`a` es mejor que `b` según la dirección de optimización?
138
+ * Para 'maximize': a > b. Para 'minimize': a < b.
139
+ */
140
+ function isBetter(a, b, kind) {
141
+ if (kind === 'maximize')
142
+ return a > b + INTEGER_TOL;
143
+ return a < b - INTEGER_TOL;
144
+ }
145
+ /**
146
+ * El bound del nodo (valor LP relajado) ¿puede mejorar al
147
+ * incumbent? Si no, podamos.
148
+ */
149
+ function canImprove(bound, incumbent, kind, hasIncumbent) {
150
+ if (!hasIncumbent)
151
+ return true;
152
+ if (kind === 'maximize')
153
+ return bound > incumbent + INTEGER_TOL;
154
+ return bound < incumbent - INTEGER_TOL;
155
+ }
156
+ /**
157
+ * Solver ILP principal. Estrategia DFS con pila explícita.
158
+ */
159
+ function solveILP(problem, opts = {}) {
160
+ const maxNodes = opts.maxNodes ?? DEFAULT_MAX_NODES;
161
+ const timeoutMs = opts.timeoutMs ?? DEFAULT_TIMEOUT_MS;
162
+ const lpOpts = opts.lpOptions ?? {};
163
+ const kind = problem.objective.kind;
164
+ const startTime = Date.now();
165
+ // integerVars unificado (incluye binarios)
166
+ const integerVarsSet = new Set(problem.integerVars);
167
+ if (problem.binaryVars) {
168
+ for (const b of problem.binaryVars)
169
+ integerVarsSet.add(b);
170
+ }
171
+ const integerVars = Array.from(integerVarsSet);
172
+ const rootLP = lpRelaxation(problem);
173
+ const rootSol = (0, simplex_1.solveLP)(rootLP, lpOpts);
174
+ if (rootSol.status === 'infeasible' || rootSol.status === 'unbounded') {
175
+ return {
176
+ ...rootSol,
177
+ nodesExplored: 1,
178
+ };
179
+ }
180
+ if (rootSol.status === 'iteration_limit') {
181
+ return {
182
+ ...rootSol,
183
+ nodesExplored: 1,
184
+ };
185
+ }
186
+ // Si la relajación ya es entera, listo
187
+ if (isIntegerSolution(rootSol.variables, integerVars)) {
188
+ return {
189
+ ...rootSol,
190
+ variables: roundIntegers(rootSol.variables, integerVars),
191
+ nodesExplored: 1,
192
+ gap: 0,
193
+ };
194
+ }
195
+ let bestValue = kind === 'maximize' ? -Infinity : Infinity;
196
+ let bestVars = null;
197
+ let nodesExplored = 1;
198
+ const rootBound = rootSol.objectiveValue;
199
+ // Stack para DFS. Cada nodo lleva su LP y el bound padre para
200
+ // pruning agresivo (la LP de los hijos no puede mejorar al padre).
201
+ const stack = [{ lp: rootLP, parentBound: rootBound }];
202
+ while (stack.length > 0) {
203
+ if (Date.now() - startTime > timeoutMs) {
204
+ // Timeout: devolvemos el incumbent (si existe) como mejor esfuerzo
205
+ if (bestVars) {
206
+ return {
207
+ status: 'iteration_limit',
208
+ variables: bestVars,
209
+ objectiveValue: bestValue,
210
+ iterations: 0,
211
+ nodesExplored,
212
+ gap: Math.abs(rootBound - bestValue),
213
+ };
214
+ }
215
+ return {
216
+ status: 'iteration_limit',
217
+ variables: rootSol.variables,
218
+ objectiveValue: NaN,
219
+ iterations: rootSol.iterations,
220
+ nodesExplored,
221
+ };
222
+ }
223
+ if (nodesExplored >= maxNodes) {
224
+ if (bestVars) {
225
+ return {
226
+ status: 'iteration_limit',
227
+ variables: bestVars,
228
+ objectiveValue: bestValue,
229
+ iterations: 0,
230
+ nodesExplored,
231
+ gap: Math.abs(rootBound - bestValue),
232
+ };
233
+ }
234
+ return {
235
+ status: 'iteration_limit',
236
+ variables: rootSol.variables,
237
+ objectiveValue: NaN,
238
+ iterations: rootSol.iterations,
239
+ nodesExplored,
240
+ };
241
+ }
242
+ const node = stack.pop();
243
+ if (!node)
244
+ break;
245
+ // Pruning preliminar contra el bound del padre
246
+ if (!canImprove(node.parentBound, bestValue, kind, bestVars !== null)) {
247
+ continue;
248
+ }
249
+ const sol = (0, simplex_1.solveLP)(node.lp, lpOpts);
250
+ nodesExplored++;
251
+ if (sol.status === 'infeasible' || sol.status === 'unbounded')
252
+ continue;
253
+ if (sol.status === 'iteration_limit')
254
+ continue;
255
+ // Pruning por bound: si el LP relajado de este nodo no mejora al
256
+ // incumbent, podamos.
257
+ if (!canImprove(sol.objectiveValue, bestValue, kind, bestVars !== null)) {
258
+ continue;
259
+ }
260
+ if (isIntegerSolution(sol.variables, integerVars)) {
261
+ // Candidato entero. Actualizar incumbent si mejora.
262
+ if (bestVars === null || isBetter(sol.objectiveValue, bestValue, kind)) {
263
+ bestValue = sol.objectiveValue;
264
+ bestVars = roundIntegers(sol.variables, integerVars);
265
+ }
266
+ continue;
267
+ }
268
+ // Branch
269
+ const branchIdx = pickBranchVariable(sol.variables, integerVars);
270
+ if (branchIdx === -1)
271
+ continue; // todas enteras: ya manejado arriba
272
+ const value = sol.variables[branchIdx] ?? 0;
273
+ const floor = Math.floor(value);
274
+ const ceil = Math.ceil(value);
275
+ // DFS: empujamos primero el de menor prioridad. Para max,
276
+ // exploramos primero la rama ceil (suele tener mejor bound).
277
+ if (kind === 'maximize') {
278
+ stack.push({
279
+ lp: branch(node.lp, branchIdx, floor, 'floor'),
280
+ parentBound: sol.objectiveValue,
281
+ });
282
+ stack.push({ lp: branch(node.lp, branchIdx, ceil, 'ceil'), parentBound: sol.objectiveValue });
283
+ }
284
+ else {
285
+ stack.push({ lp: branch(node.lp, branchIdx, ceil, 'ceil'), parentBound: sol.objectiveValue });
286
+ stack.push({
287
+ lp: branch(node.lp, branchIdx, floor, 'floor'),
288
+ parentBound: sol.objectiveValue,
289
+ });
290
+ }
291
+ }
292
+ if (bestVars === null) {
293
+ // No se encontró ningún entero factible
294
+ return {
295
+ status: 'infeasible',
296
+ variables: new Array(problem.objective.coefficients.length).fill(0),
297
+ objectiveValue: NaN,
298
+ iterations: rootSol.iterations,
299
+ nodesExplored,
300
+ };
301
+ }
302
+ return {
303
+ status: 'optimal',
304
+ variables: bestVars,
305
+ objectiveValue: bestValue,
306
+ iterations: rootSol.iterations,
307
+ nodesExplored,
308
+ gap: Math.abs(rootBound - bestValue),
309
+ };
310
+ }
311
+ //# sourceMappingURL=branch-and-bound.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"branch-and-bound.js","sourceRoot":"","sources":["../../src/optimization/branch-and-bound.ts"],"names":[],"mappings":";AAAA,+DAA+D;AAC/D,oDAAoD;AACpD,+DAA+D;AAC/D,sBAAsB;AACtB,kEAAkE;AAClE,+DAA+D;AAC/D,6BAA6B;AAC7B,kEAAkE;AAClE,gEAAgE;AAChE,gEAAgE;AAChE,iEAAiE;AACjE,iEAAiE;AACjE,6BAA6B;AAC7B,EAAE;AACF,gEAAgE;AAChE,oDAAoD;AACpD,8DAA8D;AAC9D,EAAE;AACF,4DAA4D;A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AU;QAC9B,aAAa;QACb,GAAG,EAAE,IAAI,CAAC,GAAG,CAAC,SAAS,GAAG,SAAS,CAAC;KACrC,CAAC;AACJ,CAAC"}
@@ -0,0 +1,5 @@
1
+ export type { LPProblem, LPSolution, LPStatus, LPConstraint, LPOptions, ILPProblem, ILPSolution, ILPOptions, ObjectiveKind, ConstraintOperator, } from './types';
2
+ export { solveLP } from './simplex';
3
+ export { solveILP, lpRelaxation } from './branch-and-bound';
4
+ export { standardForm } from './standard-form';
5
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/optimization/index.ts"],"names":[],"mappings":"AAUA,YAAY,EACV,SAAS,EACT,UAAU,EACV,QAAQ,EACR,YAAY,EACZ,SAAS,EACT,UAAU,EACV,WAAW,EACX,UAAU,EACV,aAAa,EACb,kBAAkB,GACnB,MAAM,SAAS,CAAC;AAEjB,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,QAAQ,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAC5D,OAAO,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC"}
@@ -0,0 +1,20 @@
1
+ "use strict";
2
+ // ============================================================
3
+ // ST Optimization — barrel público.
4
+ // ============================================================
5
+ // API:
6
+ // solveLP(problem, opts?) → LPSolution simplex de dos fases
7
+ // solveILP(problem, opts?) → ILPSolution branch-and-bound
8
+ // lpRelaxation(ilp) → LPProblem relajación continua
9
+ // standardForm(lp) → LPProblem forma estándar
10
+ // ============================================================
11
+ Object.defineProperty(exports, "__esModule", { value: true });
12
+ exports.standardForm = exports.lpRelaxation = exports.solveILP = exports.solveLP = void 0;
13
+ var simplex_1 = require("./simplex");
14
+ Object.defineProperty(exports, "solveLP", { enumerable: true, get: function () { return simplex_1.solveLP; } });
15
+ var branch_and_bound_1 = require("./branch-and-bound");
16
+ Object.defineProperty(exports, "solveILP", { enumerable: true, get: function () { return branch_and_bound_1.solveILP; } });
17
+ Object.defineProperty(exports, "lpRelaxation", { enumerable: true, get: function () { return branch_and_bound_1.lpRelaxation; } });
18
+ var standard_form_1 = require("./standard-form");
19
+ Object.defineProperty(exports, "standardForm", { enumerable: true, get: function () { return standard_form_1.standardForm; } });
20
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/optimization/index.ts"],"names":[],"mappings":";AAAA,+DAA+D;AAC/D,oCAAoC;AACpC,+DAA+D;AAC/D,OAAO;AACP,oEAAoE;AACpE,gEAAgE;AAChE,mEAAmE;AACnE,8DAA8D;AAC9D,+DAA+D;;;AAe/D,qCAAoC;AAA3B,kGAAA,OAAO,OAAA;AAChB,uDAA4D;AAAnD,4GAAA,QAAQ,OAAA;AAAE,gHAAA,YAAY,OAAA;AAC/B,iDAA+C;AAAtC,6GAAA,YAAY,OAAA"}
@@ -0,0 +1,8 @@
1
+ import type { LPOptions, LPProblem, LPSolution } from './types';
2
+ /**
3
+ * Solver LP principal. Acepta el problema en cualquier forma
4
+ * (min/max, ≤/≥/=, con o sin cotas), lo lleva a standardForm y
5
+ * ejecuta simplex de dos fases.
6
+ */
7
+ export declare function solveLP(problem: LPProblem, opts?: LPOptions): LPSolution;
8
+ //# sourceMappingURL=simplex.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"simplex.d.ts","sourceRoot":"","sources":["../../src/optimization/simplex.ts"],"names":[],"mappings":"AA8BA,OAAO,KAAK,EAAE,SAAS,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAyRhE;;;;GAIG;AACH,wBAAgB,OAAO,CAAC,OAAO,EAAE,SAAS,EAAE,IAAI,GAAE,SAAc,GAAG,UAAU,CA4G5E"}