The demand curve is given by qd = 500 – 2px what is the total revenue

The demand curve is given by QD = 500 – 2PX
a. What is the total revenue function?
b. The marginal revenue function is MR = 250 – Q.
Graph the total revenue function, the demand curve, and the marginal revenue function.
c. At what price is revenue maximized, and what is revenue at that point?
d. Identify the elastic and inelastic regions of the demand curve.

Please show work so that I can actually understand where the answers came from. Thank you