The optimal composition of foreign exchange reserves