  Blockchain has recently been applied in many applications such as bitcoin,
smart grid, and Internet of Things (IoT) as a public ledger of transactions.
However, the use of blockchain in mobile environments is still limited because
the mining process consumes too much computing and energy resources on mobile
devices. Edge computing offered by the Edge Computing Service Provider can be
adopted as a viable solution for offloading the mining tasks from the mobile
devices, i.e., miners, in the mobile blockchain environment. However, a
mechanism needs to be designed for edge resource allocation to maximize the
revenue for the Edge Computing Service Provider and to ensure incentive
compatibility and individual rationality is still open. In this paper, we
develop an optimal auction based on deep learning for the edge resource
allocation. Specifically, we construct a multi-layer neural network
architecture based on an analytical solution of the optimal auction. The neural
networks first perform monotone transformations of the miners' bids. Then, they
calculate allocation and conditional payment rules for the miners. We use
valuations of the miners as the data training to adjust parameters of the
neural networks so as to optimize the loss function which is the expected,
negated revenue of the Edge Computing Service Provider. We show the
experimental results to confirm the benefits of using the deep learning for
deriving the optimal auction for mobile blockchain with high revenue
