I will list the files in the project to inspect the setup and see what icons, chart libraries, or UI frameworks are installed.
I will inspect package.json to see what dependencies and libraries (such as Lucide icons, Tailwind, Recharts, or math/utility libraries) are installed in the project.
I will install lucide-react for iconography and recharts for interactive charting of the lifecycle curves (alongside the detailed data tables).
I will check src/App.tsx to inspect the default template and existing structure.
I will read index.html to see the current title and favicon/metadata setup.
I will update index.html to give the application an appropriate title and improve its typography support.
I will create src/types/lifecycle.ts to define all TypeScript interfaces for the mathematical parameters (A,p,k,B,m), the 12 Changsheng stages, table rows, presets, and calculation summary statistics.
I will create src/data/changsheng.ts to store detailed data for all 12 Changsheng stages, including traditional philosophy meanings, business lifecycle mappings, strategy recommendations, and custom UI styling classes.
I will create src/data/presets.ts containing the exact mathematical parameters provided in the user's prompt alongside additional model presets (e.g., Fast Tech Boom, Slow Long-Life Brand, Heavy Capital Deep Pit, and Pure Gamma standard form).
I will create src/utils/math.ts to implement the mathematical engines for y(t)=Atpe−kt−Be, derivative velocities, numerical root-finding for zero-crossings (t0), peak searching (t∗=p/k), cumulative integrals, and data table generators.
I will edit src/utils/math.ts to fix the property name observedValue in calculateFitComparison.
I will create src/components/Header.tsx to provide the application title, formula badge, preset selector, and action buttons for viewing mathematical documentation and quick resetting.
I will edit src/components/Header.tsx to remove unused declarations so there are zero TypeScript warnings.
I will create src/components/ParameterPanel.tsx to provide interactive sliders, numeric controls, and real-time LaTeX-styled formula previews for both Profit and Cost curves.
I will create src/components/LifecycleChart.tsx to display an interactive SVG chart using Recharts, complete with zero-crossing markers, Peak "帝旺" markers, and 12 Changsheng stage tooltips.
I will edit src/components/LifecycleChart.tsx to remove the unused Legend import and type the onClick event handler safely.
I will edit src/components/LifecycleChart.tsx to explicitly type (e: any) in Recharts onClick.
I will create src/components/TableSection.tsx to serve as the comprehensive Data Table Studio with 4 specialized tabs: the 12 Changsheng Stage Table, Custom Time-Step Table, Cumulative Financial Accounting Table, and User Sketch Point Fitting Table, along with CSV export and Markdown copy tools.
I will edit src/components/TableSection.tsx to remove unused declarations (Filter, DataRow, onChangeConfig).
I will create src/components/FormulaGuideModal.tsx to display an educational modal covering the mathematical derivation, parameter mappings, and philosophical relationship between Twelve Changsheng and Lifecycle Curves.
I will update src/App.tsx to integrate the header, parameter studio, responsive lifecycle chart, comprehensive data table studio, and educational guide modal.
I will edit src/components/TableSection.tsx to make onChangeConfig?: (newConfig: ModelConfig) => void; optional in TableSectionProps.
I will now run build_project to test that the application compiles without any TypeScript or Vite build errors.
我已为你开发了**「十二长生 & 商业生命周期」多模态数学拟合与交互数据表格系统 (Lifecycle Math & Table Studio)**。项目已完成构建并生成完全独立的交互应用。
🌟 核心功能与亮点
1. 完整实现题干推荐数学模型与双线差值计算
系统内置并默认加载了你提出的经典推荐参数:
- 利润曲线 P(t):P(t)=2.2t1.0e
2. 四大专业交互数据表格(表格工作台核心)
在主页中部的表格工作台中,你可以切换四类表格视图:
- 十二长生宫气数表(12阶段对应表)
- 严格对应「胎 → 养 → 长生 → 沐浴 → 冠带 → 临官 → 帝旺 → 衰 → 病 → 死 → 墓 → 绝」12个宫位顺序。
- 每行清晰列示:时期 t、利润 P(t)、成本 C(t)、净盈亏 Π(t)、旺度百分比 %(相对帝旺主峰归一化 = 100%)、增长速度斜率 ,以及对应的与。
3. 随心导出与共享工具
- 导出 Excel / CSV 表格:带 UTF-8 BOM 编码,在 Excel 软件中直接打开中文字段与数学符号绝无乱码。
- 一键复制 Markdown 格式表格:精准排版,可直接粘贴进微信、Notion、Obsidian、Word 或论文 LaTeX 笔记。
- 一键复制公式方程文本:点击顶部「复制方程」可复制完整的数学关系式文本。
4. 全生命周期同构曲线交互示波器
- 采用 Recharts 绘制利润 P(t)、成本 C(t) 与净利 Π(t) 三线同图。
- 鼠标点击或悬停图表节点,可与下方表格实现双向联动高亮;图表中清晰标记零水平虚线与帝旺标记峰点。
- 顶部「公式原理解读」弹窗包含完整的数学推导、参数对照与命理哲学思考。
Files built: index.html, src/types/lifecycle.ts, src/data/changsheng.ts, src/data/presets.ts, src/utils/math.ts, src/components/Header.tsx, src/components/ParameterPanel.tsx, src/components/LifecycleChart.tsx, src/components/TableSection.tsx, src/components/FormulaGuideModal.tsx, src/App.tsx