## Project Euler Problem 285

Another quite nice problem from Project Euler is number 285. The result of the problem depends on the computation of a certain probability, which in turn is related to the computation of a certain area. Below is an illustration of the computation for k equal to 10.

To save you some time, here’s a picture of the case k=1 which I ignored and spent quite a lot of time debugging… Plus, it only affects the last three digits or so after the decimal point…

Here’s a Matlab code which can construct the pictures above and can compute the result for low cases. To solve the problem, you should compute explicitly all these areas.

function problem285(k) N = 100000; a = rand(1,N); b = rand(1,N); ind = find(abs(sqrt((k*a+1).^2+(k*b+1).^2)-k)<0.5); plot(a(ind),b(ind),'.'); axis equal M = k; pl = 1; for k=1:M if mod(k,100)==0 k end r1 = (k+0.5)/k; r2 = (k-0.5)/k; f1 = @(x) (x<=(-1/k+r1)).*(x>=(-1/k-r1)).*(sqrt(r1^2-(x+1/k).^2)-1/k).*(x>=0).*(x<=1); f1 = @(x) f1(x).*(f1(x)>=0); f2 = @(x) (x<=(-1/k+r2)).*(x>=(-1/k-r2)).*(sqrt(r2^2-(x+1/k).^2)-1/k).*(x>=0).*(x<=1); f2 = @(x) f2(x).*(f2(x)>=0); if k == pl thetas = linspace(0,pi/2,200); hold on plot(-1/k+r1*cos(thetas),-1/k+r1*sin(thetas),'r','LineWidth',2); plot(-1/k+r2*cos(thetas),-1/k+r2*sin(thetas),'r','LineWidth',2); plot([0 1 1 0 0],[0 0 1 1 0],'k','LineWidth',3); hold off axis off end A(k) = integral(@(x) f1(x)-f2(x),0,1); end xs = xlim; ys = ylim; w = 0.01; axis([xs(1)-w xs(2)+w ys(1)-w ys(2)+w]); sum((1:k).*A)

## Problems of the Miklos Schweitzer Competition 2014

**Problem 1.** Let be a positive integer. Let be a familiy of sets that contains more than half of all subsets of an -element set . Prove that from we can select sets that form a separating family of , i.e., for any two distinct elements of there is a selected set containing exactly one of the two elements.

**Problem 2.** let and let be non-degenerate subintervals of the interval . Prove that

where the summation is over all pairs of indices such that and are not disjoint.

**Problem 3.** We have points in the plane, no three of them collinear. The points are colored with two colors. Prove that from the points we can form empty triangles (they have no colored points in their interiors) with pairwise disjoint interiors, such that all points occuring as vertices of the triangles have the same color.

**Problem 4.** For a positive integer , let be the number of sequences of positive integers such that and for . We make the convention . Let be the unique real number greater than such that . Prove that

- (i) .
- (ii) There exists no number such that .

**Problem 5.** Let be a non-real algebraic integer of degree two, and let be the set of irreducible elements of the ring . Prove that

**Problem 6.** Let be a representation of a finite -group over a field of characteristic . Prove that if the restriction of the linear map to a finite dimensional subspace of is injective, then the subspace spanned by the subspaces () is the direct sum of these subspaces.

**Problem 7.** Lef be a continuous function and let be arbitrary. Suppose that the Minkowski sum of the graph of and the graph of (i.e. the set has Lebesgue measure zero. Does it follow then that the function is of the form , with suitable constants ?

**Problem 8.** Let be a fixed integer. Calculate the distance

where runs over polynomials of degree less than with real coefficients and runs over functions of the form

defined on the closed interval , where and .

**Problem 9.** Let , and let be a convex body, i.e. a compact convex set with nonempty interior. Define the barycenter of the body with respect to the weight function by the usual formula

Prove that the translates of the body have pairwise distinct barycenters with respect to .

**Problem 10.** To each vertex of a given triangulation of the two dimensional sphere, we assign a convex subset of the plane. Assume that the three convex sets corresponding to the three vertices of any two dimensional face of the triangulation have at least one point in common. Show that there exist four vertices such that the corresponding convex sets have at least one point in common.

**Problem 11.** Let be a random variable that is uniformly distributed on the interval , and let

Show that, as , the limit distribution of is the Cauchy distribution with density function .

## Two examples of Probability applications

**Problem 1.** The probability that an animal reacts positively to an injection is . Eight random animals have been injected. Calculate the probability of the following events:

a) No animal has a positive reaction;

b) Exactly two animals have a positive reaction;

c) At most two animals have a positive reaction;

d) At least two animals have a positive reaction.

## How can everybody (probably) get the right change?

We are all annoyed when we buy something and the seller doesn’t have the right change. You have a few possibilities: leave the change (not a real option…), go change your money yourself, or wait for another buyer. Below a simplistic situation is presented, where people wait in line to buy cinema tickets. The price is euros, and the customers all have bills of and euros (to be more precise people have euros bills and people have euros bills). Note that there are more people with euros bills than those with euros bills, so in the end everybody could receive change, even if the cashier has no euro bills in the beginning. Still, the problem is that each client would like to pay for his ticket and receive the change on the spot, without waiting. In order to do that the cashier would need to have some number of euro bills in the beginning.

The worst case is when all clients with euros bills are first in line, case in which the cashier would need bills of euros for everyone to be happy. We can ask for a more weak condition, namely that the probability that everyone is satisfied is big, let’s say . How many euros bills would the cashier need to fulfill this goal? How many bills does he need to reach a probability of ?

## IMC 2011 Day 1 Problem 4

## Arithmetic progressions which cover the positive integers

Suppose we have a family (finite or infinite) of arithmetic progressions of ratios , and suppose that their union is . Prove that .

## 2 Hunters

Suppose and are two hunters having the same abilities, which means that the probability that kills his prey is equal to the probability that kills his prey. During their hunting sessions aimed ducks and aimed ducks. What is the probability that shot more ducks than did?