(f) Subject to paragraph (e) of this clause, the Contractor and the Contracting Officer may agree upon the whole or any part of the amount to be paid or remaining to be paid because of the termination. The amount may include a reasonable allowance for profit on work done. However, the agreed amount, whether under this paragraph (f) or paragraph (g) of this clause, exclusive of costs shown in paragraph (g)(3) of this clause, may not exceed the total contract price as reduced by (1) the amount of payments previously made and (2) the contract price of work not terminated. The contract shall be modified, and the Contractor paid the agreed amount. Paragraph (g) of this clause shall not limit, restrict, or affect the amount that may be agreed upon to be paid under this paragraph.