Update: rewrite of parts 1 and 2