Problem 140 of Project Euler is very much a continuation of the Problem 137, as we can see from the problem descriptionConsider the infinite polynomial series AG(x) = xG1 + x2G2 + x3G3 + ..., where Gk is the kth term of the second order recurrence relation Gk = Gk-1 + Gk-2, G1 = 1 and G2 = 4; that is, 1, 4, 5, 9, 14, 23, ... .We shall call AG(x) a golden nugget if x is rational. Find the sum of the first thirty golden nuggets.In Problem 137 I mentioned in the end that the problem could be solved using a Diophantine equation. This is exactly the way I will go for this problem.

Continue reading...Saturday, March 9, 2013

In Project Euler There are loads of problems that end up with a number theoretic solution. Problem 139 is no exception to that. The problem readsLet (a, b, c) represent the three sides of a right angle triangle with integral length sides. It is possible to place four such triangles together to form a square with length c.For example, (3, 4, 5) triangles can be placed together to form a 5 by 5 square with a 1 by 1 hole in the middle and it can be seen that the 5 by 5 square can be tiled with twenty-five 1 by 1 squares.Given that the perimeter of the right triangle is less than one-hundred million, how many Pythagorean triangles would allow such a tiling to take place?I will give you two different approaches to solving it.

Continue reading...Saturday, March 2, 2013

Problem 138 of Project Euler readsFind ∑ L for the twelve smallest isosceles triangles for which h = b ± 1 and b, L are positive integers.The key to solving this problem is definitively to only consider the rightangled part of the triangle, such that you get a triangle consisting of one of the sides with length L, h and half the base (which I will denote x).I started out by figuring out that solutions would be primitive pythagorean triplets which we have worked with in Problem 9 among other places. So I tried to build a solution where I check to see if the triplets fulfill the condition that 2x ± 1 = h. However, I quickly ran into the fact that the solution would take forever to complete. So I had to take a step back and try another approach.

Continue reading...Saturday, June 9, 2012

So now we are at Problem 100 at Project Euler, you could call this an anniversary and I would have expected something extra difficult. It took a while for me to crack the following problemIf a box contains twenty-one coloured discs, composed of fifteen blue discs and six red discs, and two discs were taken at random, it can be seen that the probability of taking two blue discs, P(BB) = (15/21)(14/20) = 1/2. By finding the first arrangement to contain over 1012 = 1,000,000,000,000 discs in total, determine the number of blue discs that the box would contain.

Continue reading...This site uses cookies.

Saturday, March 16, 2013

5 Comments