  This paper considers the cooperation between primary and secondary users at
information and energy levels when both users are energy harvesting nodes. In
particular, a secondary transmitter helps relaying the primary message, and in
turn, gains the spectrum access as a reward. Also, the primary transmitter
supplies energy to the secondary transmitter if the latter is
energy-constrained, which facilitates an uninterrupted cooperation. We address
this two-level cooperation over a finite horizon with the finite battery
constraint at the secondary transmitter. While promising the rate-guaranteed
service to both primary and secondary users, we aim to maximize the primary
rate. We develop an iterative algorithm that obtains the optimal offline power
policies for primary and secondary users. To acquire insights about the
structure of the optimal solution, we examine specific scenarios. Furthermore,
we investigate the effects of the secondary rate constraint and finite battery
on the primary rate and the probability of cooperation. We show that the joint
information and energy cooperation increases the chances of cooperation and
achieves significant rate gains over only information cooperation.
