什么是以太坊技术?以太坊技术的9个核心概念详解

资讯 2024-06-21 阅读:57 评论:0
很多人都或多或少听说过以太坊,但是对于以太坊你了解多少?以太坊作为区块链技术2.0,它被称为公链之王(未来可能更有胜者),它的价值来自哪里,与区块链1.0又有什么不同。Many people have heard more or less...
美化布局示例

欧易(OKX)最新版本

【遇到注册下载问题请加文章最下面的客服微信】永久享受返佣20%手续费!

APP下载   全球官网 大陆官网

币安(Binance)最新版本

币安交易所app【遇到注册下载问题请加文章最下面的客服微信】永久享受返佣20%手续费!

APP下载   官网地址

火币HTX最新版本

火币老牌交易所【遇到注册下载问题请加文章最下面的客服微信】永久享受返佣20%手续费!

APP下载   官网地址

很多人都或多或少听说过以太坊,但是对于以太坊你了解多少?以太坊作为区块链技术2.0,它被称为公链之王(未来可能更有胜者),它的价值来自哪里,与区块链1.0又有什么不同。

Many people have heard more or less about Etherkom, but what do you know about Etherkom? By using it as block chain technology 2.0, it is known as the king of the public chain (which may be more successful in the future), where its value comes from, and how it differs from block chain 1.0.

1.png

自从2008年比特BTC币出现以来,它的存在已经渐渐为一部分人所接受,人们也积极展开了基于BTC的商业应用的思考与开发。但是随着应用的扩展,人们发现BTC的设计只适合虚拟货币场景,由于存在着非图灵完备性、缺少保存状态的账户概念,以及PoW挖矿机制所带来的资源浪费和效率问题,在很多区块链应用场景下并不适用。

Since the advent of the BTC currency in 2008, its existence has been accepted by some, and the thinking and development of BTC-based commercial applications has been actively pursued. But, as the application has expanded, the design of BTC has been found to be suitable only for virtual currency scenarios, and because of the non-turing integrity, the lack of preservation of the concept of accounts, and the waste of resources and efficiency problems associated with the PoW mining mechanism, it is not applicable in many block-chain applications.

因此人们需要一个新的基于区块链的具有图灵完备性、高效共识机制、支持更多应用场景的智能合约开发平台,以太坊在这种情况下应运而生。

There is therefore a need for a new intelligent contractual development platform, based on the block chain, that is tactile, efficient consensus-building mechanisms, and that supports more application scenarios, to be developed in such a context.

以太坊的目的是对脚本、竞争币和链上元协议等概念进行整合和提高,使得开发者能够创建任意的基于共识的、可扩展的、标准化的、图灵完备的、易于开发和协同的应用。

The intention of Tai Tai Tai Tai was to integrate and improve concepts such as scripts, competitive coins and chain-level meta-agreements, enabling developers to create consensus-based, scalable, standardized, well-established, easy to develop and synergetic applications.

以太坊是一个通用的全球性区块链,可以管理金融和非金融类型应用的状态。以太坊的新颖在于其神奇的计算机网络,它促成了一种新型的软件应用,真正的去中心化应用。将信任逻辑嵌入小程序里,运行在区块链上。而与BTC相比,以太坊建立了一种新的密码学技术基础框架,在其上开发应用更加容易,并对轻客户端友好,同时允许应用共享一个可行的去中心化应用打开了大门。从长远来看,它所带来的改变将影响全球经济和控制结构。

Ether is a universal global block chain that manages the state of financial and non-financial applications. Its novelness lies in its magical computer network, which promotes a new type of software application that is truly decentralized. The logic of trust is embedded in small programs, operating on block chains.

以太坊是个平台和编程语言,包括数字货币以太币(Ether),以及用来构建和发布分布式应用的以太脚本(EtherScript)。

Ether is a platform and programming language, including a digital currency in Tether and a script (EtherScript) used to construct and distribute distributional applications.

以太币ETH和著名的数字货币比特币BTC有非常多的相似之处。两者均为数字货币且无法伪造,都以去中心化的方式运行来保证货币供应不被某一方所控制。以太坊的另一半重要特性是提供一个完整的编程语言环境,有时也被叫作以太脚本。编程语言是人类用来控制计算机工作的,因此,用任何编程语言写好的指令对计算机来说都是准确无误没有歧义的。

There are many similarities between ETH and the famous digital currency, Bitcoin BTC. Both are digital currencies and cannot be forged. Both operate in a decentralised way to ensure that money supply is not controlled by one party. The other half of the key feature of Taiku is to provide a complete programming language, sometimes called a script. The programming language is used by humans to control computer work, so that instructions written in any programming language are accurate and unambiguous for computers.

从最底层角度来看,以太坊是一个多层的、基于密码学的开源技术协议。它的不同功能模块通过设计进行了全面的整合,作为一个整体,它是一个创建和部署去中心化应用的综合平台。虽然,以太坊看起来像由多个互相联系的开源项目的构成的混合体,但是它的进化一直被明确目标所引导,所以各个组件可以协同地组装在一起。

At the bottom of the spectrum, Ether is a multilayered, password-based open-source technology agreement. Its different functional modules are fully integrated through design, and as a whole, it is an integrated platform for creating and deploying decentralised applications. Although it looks like a mixture of multiple interconnected open-source projects, its evolution has been guided by clear objectives, so components can be assembled together.

以太坊是区块链与智能合约的完美结合,是智能合约的完整解决方案,被设计成了一个通用的去中心化平台,拥有一套完整的、可以扩展其功能的工具,在P2P网络、加密、HttpClient等技术的支持下实现了一个类似于比特币的区块链。它通过工作量证明机制实现共识、由矿工挖矿,通过P2P网络广播协议来实现对区块链的同步等操作。

Ether is a perfect combination of block chains and smart contracts. It is a complete solution to smart contracts. It has been designed as a universal decentralized platform, with a complete set of tools that can expand its functionality. It has achieved a bitcoin-like block chain supported by P2P networks, encryption, HttpClit, and so on.

以太坊不同于比特币的是可以在上面任意编写智能合约,通过智能合约实现强大的功能,实现去中心化应用的开发。在以太坊上部署的智能合约运行在以太坊特有的虚拟机上,通过以太坊虚拟机和RPC接口与底层区块链进行交互。

Ether is different from Bitcoin, where smart contracts can be freely written to achieve powerful functions and decentralised applications. Smart contracts deployed at Ether are operated on a virtual machine unique to Ether, interacting with the bottom block chain through the Etheraya virtual machine and the RPC interface.

以太坊技术的9个核心概念

The nine core concepts of Ethio-Technology

1.以太坊虚拟机:EVM

1. Etheria Virtual Machine: EVM

EVM是以太坊中智能合约的运行环境。它是以太坊项目中的另一个主要创新。它是由许多互相连接的计算机组成的。任何人都可以上传程序,并让这些程序自动执行,同时保证现在和所有以前的每个程序的状态总是公共可见的。

The EVM is the operating environment for the telecom smart contracts. It is another major innovation in the Taiyo project. It is made up of many connected computers. Anyone can upload programs and allow them to be self-executed, while ensuring that the state of each and every program now and in the past is always publicly visible.

2.以太坊账户

2. The Etherpau account

以太坊中有两类账户,它们共用同一个地址空间:外部账户:该类账户被公钥-私钥相对控制;合约账户:该类账户被存储在账户中的代码控制。外部账户的地址是由公钥决定的,合约账户的地址是在创建合约时由合约创建者的地址和该 地址发出过的交易数量计算得到。

There are two types of accounts in Ethio, which share the same address space: an external account: an account of this type is controlled relative to a public-private key; a contractual account: an account of this type is controlled by a code stored in an account. The address of an external account is determined by a public key, and the address of the contractual account is calculated by the address of the person who created the contract at the time the contract was created and the number of transactions sent by the address.

两类账户的唯一区别是:外部账户没有代码,人们可以通过创建和签名一笔交易从一个外部账户发送消息。每当合约账户收到一条消息,合约内部的代码就会被激活,允许它对内部存储进行读取、写入、发送其它消息和创建合约。

The only difference between the two types of accounts is that an external account has no code, and people can send a message from an external account by creating and signing a transaction. Whenever a message is received from a contractual account, the code inside the contract is activated, allowing it to read, write, send other messages and create a contract for internal storage.

以太坊的账户包含4个部分:

The Etheraya account contains four parts:

a.随机数,用于确定每笔交易只能被处理一次的计数器;

a. Random number of counters used to determine that each transaction can be processed only once;

b. 账户目前的以太币余额;

b. The current balance of the account in TT;

c.账户的合约代码(如果有的话);

c. Contract codes for accounts (if any);

d.账户的存储(默认为空)。

d. Storage of accounts (default is empty).

3.以太坊消息

The Etheraya news.

以太坊的消息在某种程度上类似于比特币的交易,但是两者之间存在3点重要的不同。

There are three important differences between the stories in Etheria, which are to some extent similar to the Bitcoin deal.

1)以太坊的消息可以由外部实体或合约创建,然而比特币的交易只能从外部创建;

1) The message can be created by an outside entity or contract, but the Bitcoin transaction can only be created from outside;

2)以太坊消息可以选择包含数据;

2) You can choose to include data with the Taiwan News;

3)如果以太坊消息的接收者是合约账户,可以选择进行回应,这意味着以太坊消息也包含函数概念。

3) If the recipient of the Taiwan message is a contractual account, you can choose to respond, which means that it also contains the function concept.

4.以太坊交易

4. The Etherpau deal.

以太坊中“交易”是指存在从外部账户发出的消息的签名数据包。交易包含消息的接收者、用于确认发送者的签名、以太坊账户余额、要发送的数据和被称为STARTGAS和GASPRICE的两个数值。为了防止代码出现指数型爆炸和无限循环,每笔交易需要对执行代码所引发的计算步骤做出限制。STARTGAS就是通过需要支付的燃料来对计算步骤进行限制,GASPRICE是每一计算步骤需要支付矿工的燃料价格。

& ldquao; transaction & rdquao; signature data packs with messages from external accounts. The transaction contains two values: the recipient of the message, the signature used to confirm the sender, the balance of the account in the Taiyo, the data to be sent, and what is known as STARTGAS and GASPRICE. In order to prevent an exponential explosion of the code and an unlimited cycle of the code, each transaction requires a restriction on the computational steps caused by the execution code.

5.燃料Gas

5. Fuel Gas

以太坊上的每笔交易都会被收取一定数量的燃料Gas,设置Gas的目的是限制交易执行所需的工作量,同时为交易的执行支付费用。当EVM执行交易时,Gas将按照特定规则被逐渐消耗。Gas价格由交易创建者设置,发送账户需要预付的交易费用=GASPRICE*Gas amount。如果执行结束还有Gas剩余,这些Gas将被返还给发送账户。无论执行到什么位置,一旦Gas被耗尽就会触发一个out-of-gas异常。同时,当前调用帧所做的所有状态修改都将被回滚。

Each transaction in the Tai Chamber is charged with a certain amount of fuel Gas, which is designed to limit the amount of work required to execute the transaction and to cover the cost of carrying out the transaction. When EVM executes the transaction, Gas is gradually consumed in accordance with certain rules. Gas prices are set by the transaction creators, sending accounts requires prepaid transaction costs = GASPRICE*Gas amount. If the execution ends with the rest of Gas, the Gas will be returned to the sender account. Wherever the execution goes, it triggers an out-of-gas anomaly once Gas is depleted. At the same time, all status changes made at the current transfer frame will be rolled back.

6.存储、主存和栈

6. Storage, master storage and storage

每一个账户都有一块永久的内存区域,被称为储存,其形式为Key-value,key和value的长度均为256位。相对于主存和栈,存储的读操作开销较大,一个合约只能对它自己的储存进行读写。

Each account has a permanent memory area, known as storage, in the form of Key-value, Key and Value, with a length of 256 places. The storage operation costs more than the master storage and storage, and a contract can only read and write on its own storage.

第二个内存区被称为主存。合约执行每次消息调用时都有一块新的被清除过的主存,主存可以按字节寻址,但是读写的最小单位为32字节。操作主存的开销随着主存的增长而变大。

The second memory area is referred to as the master memory. Each message call for the contract is accompanied by a new deleted master memory, which can be located by by bytes, but with a minimum of 32 bytes for reading and writing.

EVM不是基于寄存器的,而是基于栈的虚拟机。所有的计算都是在一个被称为栈的区域内执行。可以把栈里的元素放到存储或者主存中。

The EVM is based not on a register, but on a virtual machine in a store. All calculations are performed in an area known as a store. The elements in the store can be stored or stored.

7.指令集

7. Set of Instructions

EVM的指令集被房间保持在最小规模,以尽可能避免可能导致共识问题的错误。所有的指令都是针对256位这个基本的数据单位进行操作,具备常用的算术、位、逻辑和比较操作,也可以进行条件和无条件跳转。可约可以访问当前的相关属性,比如它的编号和时间戳。

The EVM command set is kept in the room as small as possible to avoid errors that could lead to consensus problems. All instructions are designed for 256 basic data units, with common arithmetic, bit, logic and comparison, and can be carried out under conditions and without conditions. The current properties, such as their numbering and time stamp, can be accessed.

8.消息调用

8. Message call

合约可以通过消息调用的方式来调用其它合约,或者发送以太币到非合约账户,消息调用 和交易非常类似,它们都有一个源,一个目标,数据负载,以太币,Gas和返回数据。事实上每个交易都可以被认为是一个顶层消息调用,这个消息调用会依次产生更多的消息调用。

Contracts can call other contracts by calling messages, or sending them to non-contractual accounts, calling messages and transactions that are very similar. They all have one source, one target, data load, in taels, Gas, and returning data. In fact, each transaction can be considered a top-level call, and this call will generate more in turn.

一个合约可以决定剩余Gas的分配,如果在内部消息调用时发生了out-of-gas异常或者其它异常,合约将得到通知。被调用的合约会拥有崭新的主存,并能够访问调用的负载。

A contract can determine the distribution of the remaining Gas, and if an out-of-gas anomaly or other anomaly occurs at the time of the internal call, the contract will be notified.

9.代码调用和库

9. Code call and library

以太坊中存在一种特殊类型的消息调用 ,被称为callcode。它跟消息调用几乎完全一样,只是加载来自目标地址的代码将在发起调用的合约上下文中运行,这意味着一个合约可以在运行时从另外一个地址动态加载代码。存储、当前地址、余额都指向发起调用的合约,只有代码是从被调用地址获取的。这使得Solidity可以实现“库”。可复用的库代码可以应用在一个合约的存储上,可以用来实现复杂的数据结构,从而使智能合约更加的强大。

There is a special type of message called in the Tails, known as Callcode. It's almost exactly the same as a message call, except that loading the code from the target address will run in the context of the contract that initiated the call, which means that a contract can dynamically load the code from another address when running. Storage, the current address, and the balance point to the contract that initiated the call, except that the code was obtained from the address that was called. This makes it possible for Solity to achieve & ldquo; the library & rdqua; and the reusable library code that can be applied to the storage of a contract and that can be used to achieve complex data structures, thus making the smart contract stronger.

美化布局示例

欧易(OKX)最新版本

【遇到注册下载问题请加文章最下面的客服微信】永久享受返佣20%手续费!

APP下载   全球官网 大陆官网

币安(Binance)最新版本

币安交易所app【遇到注册下载问题请加文章最下面的客服微信】永久享受返佣20%手续费!

APP下载   官网地址

火币HTX最新版本

火币老牌交易所【遇到注册下载问题请加文章最下面的客服微信】永久享受返佣20%手续费!

APP下载   官网地址
文字格式和图片示例

注册有任何问题请添加 微信:MVIP619 拉你进入群

弹窗与图片大小一致 文章转载注明

分享:

扫一扫在手机阅读、分享本文

发表评论
平台列表
美化布局示例

欧易(OKX)

  全球官网 大陆官网

币安(Binance)

  官网

火币(HTX)

  官网

Gate.io

  官网

Bitget

  官网

deepcoin

  官网
热门文章
  • 支付領域投下震撼彈!美國數位銀行Chime疑與GuardPay 神盾支付合作!

    支付領域投下震撼彈!美國數位銀行Chime疑與GuardPay 神盾支付合作!
    2020年,新冠肺炎(COVID-19)疫情加速數位貨幣進展。例如:2019年4月,國際清算銀行(BIS)的調查顯示,在全球66家中央銀行中,沒有一家計畫發行跨境支付的數位貨幣。惟到了2020年10月,BIS支付委員會主席康利夫(Jon Cunliffe)指出,肺炎疫情拉高民眾對無現金支付的需求,迫使各國加快數位貨幣的研發進程日本與韓國於2021年進入數位貨幣試驗階段。直到2019年12月,美國聯邦準備理事會(Fed)都尚無數位貨幣規劃,惟到了2020年2月,Fed已開始研擬...
  • 区块链:交易系统开发指南

    区块链:交易系统开发指南
    播报编辑《区块链:交易系统开发指南》使用通俗易懂的语言,从技术的角度详细介绍了区块链交易系统应有的功能架构及工作原理,让人们能够张开双臂轻松地拥抱区块链技术,享受区块链交易系统带来的惊喜与成就感。《区块链:交易系统开发指南》共分 7 章,第 1~2 章主要介绍区块链及数字货币的基本概念,以及各种公有链的 API 接口;第3~5 章主要介绍区块链交易系统的分类架构及功能; 6 章主要介绍区块链交易系统面临的问题及演进方向;第 7 章对全书做了总结。《区块链:交易系统开发指南》是...
  • 5.14加密货币价格:BTC突破6.2万美元以太坊和山寨币反映市场情绪

    5.14加密货币价格:BTC突破6.2万美元以太坊和山寨币反映市场情绪
    今天,随着比特币(BTC)的价格突破62 000美元的门槛,顶级加密货币的价格反弹了。 此外,以铁大幅上涨,维持在2 900美元的水平。 此外,其他顶尖山硬币,如索拉纳(SOL )、XRP、卡达诺(ADA )也大幅上涨。    今天密钥加密货币价格 1. 比特币价格    在5月14日星期二撰写本文时,比特币价格上升了2.57%,达到62 487.50美元。 另一方面,在过去24小时内,交易量从65.26 % 急剧上升至277亿美元。 与此同时,加密货币的市场价值为...
  • OKEx回应用户质疑:合约交易非期货 平台无机器人

    OKEx回应用户质疑:合约交易非期货 平台无机器人
       热点点 自选股份 数据中心 数据中心 研究和资料中心 资金流动 模拟交易 客户客户 具体来说,OKEx回答用户的问题:合同交易不是期货,平台不是机器人。 金融同步化,3月22日。    昨天下午,OKEx公司就维护先前用户线下的权利问题对同步财务公司作出了回应,指出OKEx公司提供的合同交易不是期货交易,在旗下的业务中没有正式的机器人。 同时,OKEX称,它不会以非法为由对任何投资损失索赔作出答复。 答复全文如下: 同步你的财务! 近日来,...
  • 0.00006694个比特币等于多少人民币/美金

    0.00006694个比特币等于多少人民币/美金
    0.00006694比特币等于多少人民币?根据比特币对人民币的最新汇率,0.00006694比特币等于4.53424784美元/32.5436 16人民币。比特币(BTC)美元(USDT)人民币(CNY)0.000066944.53424784【比特币密码】32.82795436 16比特币对人民币的最新汇率为:490408.64 CNY(1比特币=490408.64人民币)(1美元=7.24人民币)(0.00006694USDT=0.0004846456 CNY)汇率更新时...
标签列表