How are Investment gain/loss calculated?