From c7bc11e8e161cfff379adb6d5fb63b92914cee2c Mon Sep 17 00:00:00 2001 From: Taconator Date: Sat, 14 Apr 2018 16:17:58 -0400 Subject: [PATCH] bsip38: Clarifications --- bsip-0038.md | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/bsip-0038.md b/bsip-0038.md index 62dca9d..7a16725 100644 --- a/bsip-0038.md +++ b/bsip-0038.md @@ -53,6 +53,13 @@ position in margin call territory. ## The Definition of Target Collateral Ratio +For reference purpose, the collateral ratio of any given debt/short position +describes the ratio between the available collateral (e.g. core toke BTS) to +the debt that is owed (e.g. CNY, etc.) by the original borrower to the +blockchain. It is defined to be a dimensionless value as +`CR = collateral / (debt / feed_price)` where the price is measured in units of +the debt asset / units of the collateral asset (e.g. `CNY / BTS`). + "Target collateral ratio" is an optional value which can be set onto a short position, when the position being automatically liquidized (margin called), sell no more than required collateral until collateral ratio of the position @@ -108,7 +115,8 @@ target but not go too far beyond. That said, if a short position got matched with a big limit order, after partially filled, its collateral ratio should be **just** higher than specified target collateral ratio. Which means if `max_debt_to_cover` has no -fraction, need to plus it by one Satoshi; otherwise, need to round it up. +fractional component (e.g. 5.00 as opposed to 5.23), need to plus it by one +Satoshi; otherwise, need to round it up. An effectively same approach is to round down then add one Satoshi onto the result. @@ -264,7 +272,7 @@ The new option need to be presented and can be used in UI after the hard fork. When there are call orders to be filled, if `target_collateral_ratio` option is set, UI need to show exact amount of collateral that another trader is able to buy and exact amount of debt that need to pay according to the equation -described above. +described above. Note that this calculation will need to use the current `feed_price`. # Discussion