When you sell a bond, you forgo the bond's principal, which you would have received at maturity. Your returns from the investment consist of the interest that you received from the bond before selling it and the proceeds from the sale. Your gains from the sale will not be as much as your gains from holding the bond until maturity, but you'll receive the proceeds at an earlier date.
Add 1 to the bond's stated coupon rate. For example, if the bond pays 5.5 percent interest annually, add 1 to 0.055 to get 1.055.
Raise this sum to the power of the number of periods before you sell the bond. For example, if you sell the bond after two years, raise 1.055 to the power of 2 to get 1.113.
Multiply this factor by the bond's principal. For example, if you're selling a $5,000 bond, multiply 1.113 by $5,000 to get $5,565.
Subtract the bond's principal. Continuing the example, subtract $5,000 from $5,565 to get $565. This is your profit from the bond's returns.
Subtract the price you paid for the bond from its selling price. For example, if you buy the bond for $7,400 and sell it for $7,000, subtract $7,400 from $7,000 to get -$400. This is your profit from trading the bond.
Add your profit from the bond's returns to your profit from trading the bond. Continuing the example, add $565 and -$400 to get $165. This represents your total gains from the bond's sale.
Ryan Menezes is a professional writer and blogger. He has a Bachelor of Science in journalism from Boston University and has written for the American Civil Liberties Union, the marketing firm InSegment and the project management service Assembla. He is also a member of Mensa and the American Parliamentary Debate Association.