the collateral at every moment must coincide with value mark-to-market of swap

let’s take as a example simple **swap** with just one cashflow , which pays 100 euros at time T [it has no variable leg]

at time T swap’s value is 100 euros

so collateral value is also 100

at time T-1 (previous day) how much collateral we have to put?

if collateral is in EUR and grows with overnight EONIA rate

we must put 100 euros (=value of cashflow) decounted with EONIA rate

but as collateral coincides with MTM of derivative the cashflow must be discounted with the same rate

another example

if **swap** is in EUR but the collateral is in USD we still have to discount the derivative with OIS rate (usd fed funds)