implemented BCs