diff --git a/aeon-coin-supply-0.html b/aeon-coin-supply-0.html index 4de98bb..d83936b 100644 --- a/aeon-coin-supply-0.html +++ b/aeon-coin-supply-0.html @@ -44,11 +44,6 @@ var chart = get_chart([].concat( chartData_9, ), aeon_config); -function toggleProj() { - chart.graphs[1].hidden = !document.getElementById("proj").checked; - chart.validateNow(); -} - function togglePan() { chart.chartCursor.pan = document.getElementById("pan").checked; } @@ -58,7 +53,6 @@ function togglePan() {

Aeon coin supply

-

Show projected supply

Enable panning

Back to top

diff --git a/aeon-coin-supply-1.html b/aeon-coin-supply-1.html index 1343624..4801300 100644 --- a/aeon-coin-supply-1.html +++ b/aeon-coin-supply-1.html @@ -28,11 +28,6 @@ var chart = get_chart([].concat( chartData_11, ), aeon_config, aeon_offset_1); -function toggleProj() { - chart.graphs[1].hidden = !document.getElementById("proj").checked; - chart.validateNow(); -} - function togglePan() { chart.chartCursor.pan = document.getElementById("pan").checked; } @@ -42,7 +37,6 @@ function togglePan() {

Aeon coin supply

-

Show projected supply

Enable panning

Back to top

diff --git a/aeon-config.js b/aeon-config.js index 52b3a39..341137a 100644 --- a/aeon-config.js +++ b/aeon-config.js @@ -33,5 +33,6 @@ var aeon_offset_1 = { height: 1000000, supply: "16230799273689217059", supply_proj: "16234708945129113452", + accum_fee: "8090111859795393", bc_size: 2745344988, }; diff --git a/js/coin-supply.js b/js/coin-supply.js index fbf80cf..3ca555c 100644 --- a/js/coin-supply.js +++ b/js/coin-supply.js @@ -3,14 +3,24 @@ function get_chart(chartData, cryptonote_config, offset) { chartData[i].date = new Date(1000 * chartData[i][0]); chartData[i].height = i + (offset === undefined ? 0 : offset.height); chartData[i].coin_supply = bigInt(chartData[i][3]); + chartData[i].fee = bigInt(0); for (var j = 0; j < chartData[i][6].length; ++j) - chartData[i].coin_supply = chartData[i].coin_supply.minus(chartData[i][6][j][4]); // subtract fees - if (i === 0 && offset !== undefined) - chartData[i].coin_supply = chartData[i].coin_supply.plus(offset.supply); + chartData[i].fee = chartData[i].fee.plus(chartData[i][6][j][4]); + chartData[i].coin_supply = chartData[i].coin_supply.minus(chartData[i].fee); if (i > 0) + { chartData[i].coin_supply = chartData[i].coin_supply.plus(chartData[i - 1].coin_supply); + chartData[i].fee = chartData[i].fee.plus(chartData[i - 1].fee); + } + else if (offset !== undefined) + { + chartData[i].coin_supply = chartData[i].coin_supply.plus(offset.supply); + chartData[i].fee = chartData[i].fee.plus(offset.accum_fee); + } chartData[i].coin_supply_str = print_money(chartData[i].coin_supply, cryptonote_config.CRYPTONOTE_DISPLAY_DECIMAL_POINT); chartData[i].coin_supply_real = chartData[i].coin_supply.toJSNumber() / Math.pow(10, cryptonote_config.CRYPTONOTE_DISPLAY_DECIMAL_POINT); + chartData[i].fee_str = print_money(chartData[i].fee, cryptonote_config.CRYPTONOTE_DISPLAY_DECIMAL_POINT); + chartData[i].fee_real = chartData[i].fee.toJSNumber() / Math.pow(10, cryptonote_config.CRYPTONOTE_DISPLAY_DECIMAL_POINT); // projected supply var target = cryptonote_config.get_difficulty_target((offset === undefined ? 0 : offset.height) + i); var target_minutes = target / 60; @@ -19,7 +29,7 @@ function get_chart(chartData, cryptonote_config, offset) { var base_reward = bigInt(cryptonote_config.MONEY_SUPPLY).minus(already_generated_coins).shiftRight(emission_speed_factor); if (base_reward.lesser(cryptonote_config.FINAL_SUBSIDY_PER_MINUTE * target_minutes)) { - base_reward = bigInt(cryptonote_config.FINAL_SUBSIDY_PER_MINUTE * target_minutes); + base_reward = bigInt(cryptonote_config.FINAL_SUBSIDY_PER_MINUTE * target_minutes); } chartData[i].coin_supply_proj = base_reward.plus(already_generated_coins); chartData[i].coin_supply_proj_str = print_money(chartData[i].coin_supply_proj, cryptonote_config.CRYPTONOTE_DISPLAY_DECIMAL_POINT); @@ -37,13 +47,28 @@ function get_chart(chartData, cryptonote_config, offset) { "marginTop": 7, "dataProvider": chartData, "valueAxes": [{ + "id":"va_supply", + "color": "DarkGoldenrod", + "axisColor": "DarkGoldenrod", + "axisThickness": 2, + "axisAlpha": 0, + "position": "left" + }, { + "id":"va_fee", + "color": "LightSeaGreen", + "axisColor": "LightSeaGreen", + "axisThickness": 2, "axisAlpha": 0, + "gridAlpha": 0, + "position": "right" }], "mouseWheelZoomEnabled": true, "graphs": [{ "id": "g1", - "lineColor": "#cc9900", - "balloonText": "Supply: [[coin_supply_str]]\n(Proj: [[coin_supply_proj_str]])\nHeight: [[height]]", + "valueAxis": "va_supply", + "lineColor": "DarkGoldenrod", + "lineThickness": 4, + "balloonText": "Supply: [[coin_supply_str]]\n(Proj: [[coin_supply_proj_str]])\n(Accum fee: [[fee_str]])\nHeight: [[height]]", "bullet": "round", "bulletBorderAlpha": 1, "bulletColor": "#FFFFFF", @@ -56,7 +81,9 @@ function get_chart(chartData, cryptonote_config, offset) { } },{ "id": "g2", - "lineColor": "#447700", + "valueAxis": "va_supply", + "lineColor": "DarkKhaki", + "lineThickness": 2, "bullet": "round", "bulletBorderAlpha": 1, "bulletColor": "#FFFFFF", @@ -65,7 +92,19 @@ function get_chart(chartData, cryptonote_config, offset) { "valueField": "coin_supply_proj_real", "useLineColorForBulletBorder": true, "showBalloon": false, - "hidden": true, + },{ + "id": "g3", + "valueAxis": "va_fee", + "lineColor": "LightSeaGreen", + "lineThickness": 1, + "bullet": "round", + "bulletBorderAlpha": 1, + "bulletColor": "#FFFFFF", + "hideBulletsCount": 50, + "title": "accumulated fee", + "valueField": "fee_real", + "useLineColorForBulletBorder": true, + "showBalloon": false, }], "chartScrollbar": { "autoGridCount": true, diff --git a/monero-coin-supply-0.html b/monero-coin-supply-0.html index 511553e..432c35b 100644 --- a/monero-coin-supply-0.html +++ b/monero-coin-supply-0.html @@ -44,11 +44,6 @@ var chart = get_chart([].concat( chartData_9, ), monero_config); -function toggleProj() { - chart.graphs[1].hidden = !document.getElementById("proj").checked; - chart.validateNow(); -} - function togglePan() { chart.chartCursor.pan = document.getElementById("pan").checked; } @@ -58,7 +53,6 @@ function togglePan() {

Monero coin supply

-

Show projected supply

Enable panning

Back to top

diff --git a/monero-coin-supply-1.html b/monero-coin-supply-1.html index 4dbe52d..d66ee69 100644 --- a/monero-coin-supply-1.html +++ b/monero-coin-supply-1.html @@ -44,11 +44,6 @@ var chart = get_chart([].concat( chartData_19, ), monero_config, monero_offset_1); -function toggleProj() { - chart.graphs[1].hidden = !document.getElementById("proj").checked; - chart.validateNow(); -} - function togglePan() { chart.chartCursor.pan = document.getElementById("pan").checked; } @@ -58,7 +53,6 @@ function togglePan() {

Monero coin supply

-

Show projected supply

Enable panning

Back to top

diff --git a/monero-config.js b/monero-config.js index f17b2db..ac7974f 100644 --- a/monero-config.js +++ b/monero-config.js @@ -18,7 +18,8 @@ var monero_config = { var monero_offset_1 = { height: 1000000, - supply: bigInt("11319902360375037196"), - supply_proj: bigInt("11338799512357636715"), + supply: "11319902360375037196", + supply_proj: "11338799512357636715", + accum_fee: "28065472452232840", bc_size: 2630363526, }; diff --git a/wownero-coin-supply.html b/wownero-coin-supply.html index 1f1b263..9401fdd 100644 --- a/wownero-coin-supply.html +++ b/wownero-coin-supply.html @@ -28,11 +28,6 @@ var chart = get_chart([].concat( chartData_1 ), wownero_config); -function toggleProj() { - chart.graphs[1].hidden = !document.getElementById("proj").checked; - chart.validateNow(); -} - function togglePan() { chart.chartCursor.pan = document.getElementById("pan").checked; } @@ -42,7 +37,6 @@ function togglePan() {

Wownero coin supply

-

Show projected supply

Enable panning

Back to top