Skip to content

Instantly share code, notes, and snippets.

@endorxmr
endorxmr / 51_attacks_mining_incentive.md
Last active September 6, 2023 16:59
51% mining attacks vs. mining incentives

51% attacks and mining incentives

Mining incentive [$/s] = Coin price [$/coin] * Block reward [coin/block] / Target block time [s/block]

(Note that the block reward includes tx fees)

Mining incentives of BTC, BCH, XMR, at the time of writing (2023-09-06)

Coin Price [$/coin] Reward [coins/block] Blocktime [s/block] Mining Incentive [$/s]
@endorxmr
endorxmr / mining-profitability.py
Last active November 5, 2022 15:57
Estimate a Monero miner's income and profitability, plus an upper bound for the total energy consumption of the mining network and the number of cpus involved
import texttable as tt
import datetime
import requests
import json
import math
node_jsonrpc = "http://node.supportxmr.com:18081/json_rpc"
time_format = "%Y-%m-%d %H:%M:%S"