Gas - Reading Assignment

  • How do we calculate the total gas cost for a transaction?
    • The cumulative sum of all the operations is the total gas cost for the transaction
  • What is gas limit?
    • The maximum amtt of gas one is willing to spend on the transaction
  • What happens if we specify a gas limit that is too low?
    • Providing too little gas will result in a failed transaction; the fees are kept by the miner, but u do not lose any other funds
  • What happens if we specify a gas limit that is too high and therefore not consumed fully?
    • unspent gas is refunded automatically
  • What is a gwei?
    • Wei is the smallest unit of ether, and gwei is simply 1 billion wei

Further questions outta curiosity //

  • How do miners turn gwei into other currencies? Do they just stack up until issa transferable amount of ETH?
  • Where do all these weird names like “wei; femtoether; shannon, babbage, etc” come from?

Thanks for this v interesting class! I always wondered how minin on ETH worked, this article explained A LOT.

@LORDKALVIN - :point_left:
(tap here to follow me on spotify)

1 Like
  1. Multiply the total gas allocated to this transaction by the gwei price of 20 to 30 depending on current price levels.

  2. The total units of fees ( Gas) that the issuer of a transaction is willing to spend.

  3. The transaction will not be initiated or completed.

  4. In most cases unspent gas is refunded, taking into consideration that transaction blocks will only utilize gas based on their limit only, no less no more.

  5. 1000000000 Wei, 1 Wei is the smallest unit of gas.

1 Like

Reading Assignment: Gas.

  1. How do we calculate the total gas cost for a transaction?
    The cumulative sum of all the operations is the total gas cost for the transaction.

  2. What is gas limit?
    Maximum amount of gas you are willing to spend on the transaction.

  3. What happens if we specify a gas limit that is too low?
    Your transaction will start to be executed, but will eventually run out of gas and be stopped.
    When this happens, you will not get back ether spend on the gas used, but since the transaction did not complete, the blockchain does not reflect a transfer, so the main funds essentially never left the wallet.

  4. What happens if we specify a gas limit that is too high and therefore not consumed fully?
    It will be refunded automatically.
    However, high value for the gas limit fills up the block gas limit, that isn’t computationally-dense enough for miners to want.

  5. What is a gwei?
    It’s a Gas unit measured in a fractional amount of ether.
    1 ether = 1.000.000.000 gwei.
    1 gwei = 1.000.000.000 wei (smallest unit).

1 Like
  1. By adding up all costs of the operation.
  2. The maximum amount of gas youre paying
  3. The TX starts but never will go through. Ether will still be in the wallet but you potentially lost the gas you started paying for the TX.
  4. theres a limit to the consumation of gas for ether miners. If it exceeds the limit it cant be dealt with
  5. a subivision of ETH
1 Like

1.) Total gas cost depends on computational power needed to execute the transaction
2.) The gas limit is the maximum amount of gas allocated to the transaction
3.) The transaction will fail if the gas limit is too low.
4.) Ethereum blocks have a size limit, and the transaction won’t execute if the price is too high. However, if you don’t reach this level, then the gas is refunded to you.
5.) 1 gwei = 1,000,000,000 wei = 0.000000001 ETH

1 Like
  1. The cumulative sum of all the operations is the total gas cost for the transaction.
  2. the MAXIMUM amount of gas you are willing to spend on the transaction.
  3. Your transaction will start to be executed, but will eventually run out of gas and be stopped. When this happens, you will not get back ether spend on the gas used, but since the transaction did not complete, the blockchain does not reflect a transfer, so the main funds essentially never left the wallet.
    4.miners only get paid for the actual gas consumed by a transaction, so it will be refunded.
    5.Wei is the smallest unit of ether, and gwei is simply 1000000000 wei.
1 Like
  1. How do we calculate the total gas cost for a transaction? the sum of the operations you want to perform.
  2. What is gas limit? the max the user is willing to pay
  3. What happens if we specify a gas limit that is too low? the operation requested will be not be executed or could be delayed
  4. What happens if we specify a gas limit that is too high and therefore not consumed fully? the excess will remain in the wallet unused.
  5. What is a gwei? a gwei is 1 billion wei and wei is the smallest unit of ether, like cents is to dollar
1 Like
  1. How do we calculate the total gas cost for a transaction?
    cumulative sum of operations
  2. What is gas limit?
    MAXIMUM amount of gas you are willing to spend on the transaction
  3. What happens if we specify a gas limit that is too low?
    transaction will start to be executed, but will eventually run out of gas and be stopped
  4. What hapens if we specify a gas limit that is too high and therefore not consumed fully?
    It will remain in the wallet unused
  5. What is a gwei?gas price is is a billion of wei
1 Like
  1. The gas cost is calculated from all operation you are wiling to do .
    2.Gas limit is the maximum amount of gas you are willing to spend on a transaction.
    3.Your transaction will start to be executed, but will eventually run out of gas and be stopped.
    4.Miners only get paid for the actual gas consumed by a transaction, so putting a high value for the gas limit fills up the block gas limit, but isn’t computationally-dense enough for miners to want.
    5.Wei is the smallest unit of ether, and gwei is simply 1000000000 wei.
1 Like
  1. How do we calculate the total gas cost for a transaction?
    By adding up the total of all gas fees per step within the transaction.

  2. What is gas limit?
    The maximum amount that someone is willing to pay for a transaction

  3. What happens if we specify a gas limit that is too low?
    The transaction will be rejected and you will lose your Eth fee.

  4. What happens if we specify a gas limit that is too high and therefore not consumed fully?
    The remaining amount will be refunded

  5. What is a gwei?
    A gwei is 1 billion wei which is the smallest unit of Eth.

1 Like
  1. calculate the cost of each required transaction and add them up to find the total gas cost. It is a subject the minimum gas cost set at 21000
  2. the gas limit is the maximum you are willing to spend
  3. too low - transactions are not completed but the miner keeps the fees spent on gas
  4. too much - excess is automatically refunded
  5. Wei is the smallest unit of Ether and Gwen is One Billion Wei
1 Like
  1. The total gas cost for a transaction is calculated by summing up all the predetermined costs per function and lines of code on the transaction.
    There is a minimum gas limit per transaction of 21,000+ gas.

  2. The maximum amount of gas you are willing to pay on a transaction.

  3. The transaction will start to be executed, but will eventually run out of gas and be stopped.
    The gas fees are kept by the miner who accepted to execute such transaction.

  4. The transaction will not be processed due to exceeding the actual gas limit the blocks of the Ethereum network can consume on all transactions.
    Also, miners only get paid for the actual gas consumed by the transaction, so putting a high value for the gas limit fills up the block gas limit, but isn’t computationally-dense enough for miners to want to execute.

  5. A gwei is 1,000,000,000 wei, the smallest unit of ether.
    It is used to measure Gas prices on transactions on the Ethereum network.

1 Like
  1. The cumulative sum of all the operations in the smart contract is the total gas cost for the transaction.
  2. The maximum amount they are willing to spend on the transaction.
  3. The execution starts but will run out of gas at some point and stop. The miner keeps the gas fees but the transaction operation doesn’t complete.
  4. The excess gets refunded.
  5. 1000000000 wei or 0.000000001 ether
1 Like
  1. How do we calculate the total gas cost for a transaction?
  • The total gas for a transaction is calculated by the cumulative sum of all the operations performed.
  1. What is gas limit?
  • The gas limit is similar to block size in bytes with Bitcoin. The gas limit is the maximum amount that one will pay for a transaction. This is now being altered with EIP 1559 as Eth will now become deflationary in a process in which Eth is burned by the Ethereum foundation.
  1. What happens if we specify a gas limit that is too low?
  • When you specify a gas limit that is too low it will result in a failed transaction, the fee paid will be lost, but the Eth that was transferred never leaves the wallet since it was never updated into the blockchain.
  1. What happens if we specify a gas limit that is too high and therefore not consumed fully?
  • You cannot exceed this amount if you wish for your transaction to be processed. Also, miners only get paid for the actual gas consumed by a transaction, so putting a high value for the gas limit fills up the block gas limit, but isn’t computationally-dense enough for miners to want.
  1. What is a gwei?
  • wei is the smallest unit of measure for Eth. 1 wei represents 1,000,000,000 gwei. Gwei is a fractional measure of Eth as well.
1 Like
  1. We add up all gas prices from all operations in txn

  2. Its the max gas you want to spent on the txn

  3. You loss the fee but your txn doesn’t go throug

  4. It’ll be refunded if if wasn’t crazy crazy high amount of gas fee because then the txn doesn’t go through because miners only get paid the actual used gas

  5. A sub currency from Ether

1 Like
  1. The cumulative sum of all the operations is the total gas cost for the transaction.
  2. This corresponds to the MAXIMUM amount of gas you are willing to spend on the transaction.
  3. The transaction will not fully execute and be rejected. The transaction fee will be lost but the main funds will not leave the wallet.
  4. Miners are only payed for consumed gas. You set a maximum you are willing to pay n total and the gas that not are consumed will be refunded back to you.
  5. A Gwei is a fractional part of Ether in that is represents 1000000000 wei. Wei is the smallest unit of Ether.
1 Like
  1. By cumulatively summing up all the gas costs of executed operations.

  2. Gas limit is the maximum amount of gas one is willing to spend on the transaction.

  3. Transaction fails because miners won’t accept it and the user loses the gas cost already spent on executed operations before the transactions stops.

  4. Miners might not take the transaction into verification, because blocks have a specified maximum amount of gas all transactions in the block can consume and miners want to build computationally dense blocks.

  5. Wei is the smallest unit of ether. Gwei is 10^9 wei, while ether is 10^18 wei. Gas price is usually measured in gwei.

1 Like
  1. How do we calculate the total gas cost for a transaction?

We guess based on previous experience. * Transactions on the Ethereum network require fees in the form of gas . The amount of gas depends on the amount of computation required to complete the transaction.

  1. What is gas limit?
  • Gas Limit is the maximum amount of gas allotted to the transaction, 21000 being sufficient for simple transfers and much higher amounts for transfers to smart contracts like those in ICOs.
  1. What happens if we specify a gas limit that is too low?

The transaction is not processed so it’s like it didn’t happen.

  • Providing too little gas will result in a failed transaction, the fees are kept by the miner
  • Extra, unspent gas is refunded automatically
  1. What happens if we specify a gas limit that is too high and therefore not consumed fully?
    Extra, unspent gas is refunded automatically

  2. What is a gwei?

gwei’: ‘1000000000’

It is also the smallest amount of measurable Ether.

1 Like
  1. How do we calculate the total gas cost for a transaction?
    Total gas cost is the sum of all operations.

  2. What is gas limit?
    This is the maximum of gas you are willing to spend on a transaction.

  3. What happens if we specify a gas limit that is too low?
    Your transaction will begin but then stop and ultimate fail, and the miner will keep the gas fees.

  4. What happens if we specify a gas limit that is too high and therefore not consumed fully?
    This will be refund.

  5. What is a gwei?
    This is 1,000,000,000 wei, wei being the smallest unit of Ether.

1 Like
  1. How do we calculate the total gas cost for a transaction?
    With the sum of the gas fee for every operation subject to a gas fee
  2. What is gas limit?
    the MAXIMUM amount of gas an user is willing to spend on the transaction.
  3. What happens if we specify a gas limit that is too low?
    The transaction will not complete, the user will lose the fee paid but the capital is safe because the transaction has not been executed
  4. What happens if we specify a gas limit that is too high and therefore not consumed fully?
    The transaction get executed and the change get refunded
  5. What is a gwei?
    gas price is measured in ether or wei. 1 Biliion wei is called gwei)
1 Like