Added the advanced model segment and a bit of the counting methods.