From 5dc9164ee3245185b58c425a0983fcd2e410ebdb Mon Sep 17 00:00:00 2001 From: Maxim Dolgolyov Date: Sat, 30 May 2026 12:42:44 +0300 Subject: [PATCH] =?UTF-8?q?feat(biochem):=20=D1=8F=D0=B4=D1=80=D0=BE=20bio?= =?UTF-8?q?chem-core.js=20+=20=D0=BD=D0=B0=D1=81=D1=82=D0=BE=D1=8F=D1=89?= =?UTF-8?q?=D0=B0=D1=8F=203D-=D0=B3=D0=B5=D0=BE=D0=BC=D0=B5=D1=82=D1=80?= =?UTF-8?q?=D0=B8=D1=8F=20(VSEPR)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Фаза 0 (фундамент) + Фаза 1 (3D) плана BIOCHEM_UPGRADE: - Новый общий модуль frontend/js/biochem-core.js (window.BIO): реестр элементов (CPK, масса, валентность, электроотрицательность, ковалентный/ ван-дер-ваальсов радиусы), hillFormula/molarMass/parseFormula/dbe, нормализация связей (bF/bT/bO — чинит расхождение полей f/from, o/order), render2D, vsepr (генератор 3D по ОЭПВО), render3D (ball-and-stick с глубиной и затенением), safe (обёртка API с тостом), RING_TEMPLATES. - biochem.html: подключён core; фейковый 3D (плоская проекция a.z||0) заменён на честную VSEPR-геометрию через BIO.render3D; в панель свойств добавлены форма молекулы, гибридизация и валентный угол; фикс бага порядка связи в getBondSum. VSEPR проверен: вода — угловая, метан — тетраэдр 109.5°, CO2 — линейная 180°, NH3 — пирамидальная; sp/sp2/sp3 верно. Co-Authored-By: Claude Opus 4.8 (1M context) --- frontend/biochem.html | 132 +++------ frontend/js/biochem-core.js | 533 ++++++++++++++++++++++++++++++++++++ 2 files changed, 566 insertions(+), 99 deletions(-) create mode 100644 frontend/js/biochem-core.js diff --git a/frontend/biochem.html b/frontend/biochem.html index d16be75..4324f5e 100644 --- a/frontend/biochem.html +++ b/frontend/biochem.html @@ -507,6 +507,7 @@ +