<p><b>Abstract</b>—In this paper, we present a new economics-based power-aware protocol, called the <it>distributed economic subcontracting protocol</it> (DESP), that dynamically distributes task computation among mobile devices in an ad hoc wireless network. Mobile computation devices may be energy buyers, contractors, or subcontractors. Tasks are transferred between devices via distributed bargaining and transactions. When additional energy is required, buyers and contractors negotiate energy prices within their local markets. Contractors and subcontractors spend communication and computation energy to relay or execute buyers' tasks. Buyers pay the negotiated price for this energy. Decision-making algorithms are proposed for buyers, contractors, and subcontractors, each of which has a different optimization goal. We have built a wireless network simulator, called ESIM, to assist in the design and analysis of these algorithms. When the average communication energy required to transfer a task is less than the average energy required to execute a task, our experimental results indicate that markets based on our protocol and decision-making algorithms fairly and effectively allocate energy resources among different tasks in both cooperative and competitive scenarios.</p>