  A 4D-Var data assimilation technique is applied to the rectangular-box
configuration of the NEMO in order to identify the optimal parametrization of
boundary conditions at lateral boundaries. The case of the staircase-shaped
coastlines is studied by rotating the model grid around the center of the box.
It is shown that, in some cases, the formulation of the boundary conditions at
the exact boundary leads to appearance of exponentially growing modes while
optimal boundary conditions allow to correct the errors induced by the
staircase-like appriximation of the coastline.
