hjhan
b7469be104
refactor(margin): 保证金去除'计息基数'错误概念, 改用余额建模
保证金就是保证金——有余额、有利率、有利息, 不存在'计息基数/Notional'概念。
现有代码把保证金塞进 InterestPrincipalFix 当计息腿处理是错误建模。
修正:
- 删除 MarginLeg.cs(CalcBalance/accrualFactor 是融资腿的概念, 不该用在保证金)
- 新增 MarginAccount.cs: 管理余额变动(Deposit追加/Withdraw释放), 不含计息
- MarginBalance: 注释去掉'计息基数', 改为'保证金余额'
- IMarginResolver.Resolve: 去掉 accrualFactor 参数(融资腿比例, 非保证金概念)
- CashMargin/CreditMargin/GuaranteeMargin: 同步去掉 accrualFactor
- 枚举注释: '计息余额' → '余额'
保证金利息由 SwapInterest 纯函数按 余额×利率×天数/年化 计算,
MarginAccount 只提供余额, 不掺计息逻辑。
验证: sln编译0错误, 全量486测试7失败(基线一致,零回归)。
2026-08-11 10:06:27 +08:00
..
2025-07-18 17:44:58 +08:00
2026-04-27 15:34:12 +08:00
2024-05-09 14:06:26 +08:00
2026-07-07 15:47:17 +08:00
2026-08-11 10:06:27 +08:00
2026-03-11 15:04:10 +08:00
2024-05-09 14:06:26 +08:00
2024-05-09 14:06:26 +08:00
2026-07-21 15:28:17 +08:00
2026-06-26 09:13:37 +08:00
2024-05-09 14:06:26 +08:00
2024-05-09 14:06:26 +08:00
2026-07-23 18:30:05 +08:00
2026-06-26 09:13:37 +08:00