Given a positive integer , let denote the number of positive divisors of and denote the number of positive integers not exceeding that are relatively prime to . Find all for which one of the three numbers is the arithmetic mean of the other two.
CAPS 2012
Czech-Austrian-Polish-Slovak Match 2012.
Other problems
City of Mar del Plata is a square shaped land with streets that divides it into blocks, where is an even number (the leading streets form the perimeter of the square). Each block has a dimension of meters. All streets in Mar del Plata are one-way. The streets which are parallel and adjacent to each other are directed in opposite direction. Street is driven in the direction from to and the street travels from to . A street cleaning car starts from point . The driver wants to go to the point and in doing so, he must cross as much as possible roads. What is the length of the longest route he can go, if any -meter stretch cannot be crossed more than once? (The figure shows a plan of the city for and one of the possible - but not the longest - routes of the street cleaning car. See http://goo.gl/maps/JAzD too.)

Let be a right angled triangle with hypotenuse and be a point on the shorter arc of the circumcircle of triangle . The line, perpendicuar to and passing through , intersects , at points and respectively. Prove that the ratio of area of triangles and is independent of the position of point .