# Broken Stick Math Discussion

Here's a math question I've been thinking about lately.

We have a stick of length one which is broken in one spot (with that spot chosen randomly and uniformly). Of the two broken pieces we take the one on the right and break it into two pieces in the same manner as before.

With our three pieces we then form a triangle. What is the expected value of the triangle's area assuming we can indeed form a triangle?

Anybody have any ideas. Thanks.

kuruman
Homework Helper
Gold Member
When you have two pieces and you take the "one on the right" there are two possibilities, (a) if is the smaller piece, you will never be able to form a triangle; (b) if it is the larger piece, you will always be able to form a triangle. So I think a better way to phrase the problem is to pick the larger piece of the two and break it to get the three pieces.

Last edited:
lewando
Homework Helper
Gold Member
Possibility (b) does not guarantee a triangle. Case: if the “left” piece is length 0.4, then the larger “right” piece could be broken into lengths 0.01 and 0.59 which cannot form a triangle.

lewando
Homework Helper
Gold Member
So the rule is: if you want to form a triangle, a side cannot exceed 0.5 units.
Not sure how to solve for the expected value of the area analytically.
The first break could be a random variable with uniform distribution ranging between 0 and 0.5 units. The second break would also be a random variable with uniform distribution but the range would be dependent on the actual value of the first break (again, if you want to form a triangle):
Example 1: if the leftmost piece "a" is 0.1 units, this constrains the second piece "b" to be in the range of 0.4 to 0.5 units.
Example 2: if the leftmost piece "a" is 0.4 units, this constrains the second piece "b" to be in the range of 0.1 to 0.5 units.

Use of the Monte Carlo method could provide an estimate of the expected area value, and would be nice to compare with an analytic result.

WWGD
Gold Member
Maybe we can set up a system using the triangle-cosine law:

We start with 1, breaking it into x, 1-x . Then we remove y from 1-x, to end up with x,1-x-y,y

Which needs to satisfy ## x^2 = y^2+(1-x-y)^2 -2y(1-x-y)cos\gamma ##

Where ##\gamma## is the angle opposite to the side of length ##x##.
EDIT: Implying ##x= \sqrt{y^2+(1-x-y)^2-2y(1-x-y)cos \gamma} ## and so we need
##y^2+(1-x-y)^2 \geq 2y(1-x-y)cos \gamma ##

I don't see a simple way of dealing with it, other than using geometric probability in some way..

Last edited:
Can't one use heron's formula (from highschool math) for the area?

Other than that, it seems to me answer should depend on exact rule for choice of points. That is:
-- what is the probability distribution (uniform or non-uniform .... good idea to assume uniform to simplify calc.)
-- how are exactly cuts placed (but I think that is described unambiguously in the OP)

So mainly it "seems" to me we have to find "expected area" given that resulting set of sides form a triangle.

For that I think we necessarily need to have necessary and sufficient conditions for a triangle (given three sides a,b,c). My initial guess is that such a condition might be relatively simple(?) (.... unless I am missing something .... which is quite possible).
Let c denote the largest side. The guess is:
c < a+b
It would probably be a good idea to verify or refute it with more careful reasoning.

Once we have the right condition, then we can think about returning to main question.

Edit:
edited the condition

Last edited:
It seems that the condition I mentioned in previous post should be correct. The idea of the condition was to determine necessary and sufficient conditions to determine that three sides a,b,c can form a triangle.

The condition was:
Given sides a,b,c .... let c be the largest side. Then we must have:
c<a+b

One way is to consider the side c being placed horizontally (note that the angles α and β opposite to sides a and b will be both acute angles ..... if they weren't, this would violate c being the largest side). Then if we draw a circle of radius a from left endpoint and a circle of radius b from right endpoint then they will intersect (above the side c) only if a+b>c.

===========

Now the problem in OP was:
"We have a stick of length one which is broken in one spot (with that spot chosen randomly and uniformly). Of the two broken pieces we take the one on the right and break it into two pieces in the same manner as before.
With our three pieces we then form a triangle. What is the expected value of the triangle's area assuming we can indeed form a triangle?"

Let's suppose that the first cut was placed on position c. Then we want the following condition to be satisfied:
1/3 ≤ c < 0.5
That is the first cut is in the interval [1/3,0.5) ...... this cut is placed instead of arbitrary (0,1) cut.

Now the right-side has length 1-c. An arbitrary cut would be (0,1-c). Suppose the left-side of this cut is "a" and the right-side is "b".
We have the following conditions:
c≥a
c≥b
a+b=1-c

We want to get the conditions for "a". We get:
a ≥ 1-2c
a ≤ c
So the second cut should be [1-2c,c] instead of (0,1-c).

==========

Can the above conditions be used to write down a solution equation (not sure whether it would be analytically feasible)? It seems to me that this could be done (though I haven't tried yet).

Edit:
There is probably one other issue. In general we have the following possibilities:
c is the left-side of first cut (covered above)
c is the left-side of second cut
c is the right-side of second cut

It seems we will also have to cover the second and third possibilities in the general case.

It is possible perhaps that due to certain symmetry considerations (in the case of uniform probability distribution) the other cases might not have to be considered for the expected area(?) .... not sure about this.

Last edited:
kuruman
Homework Helper
Gold Member
Possibility (b) does not guarantee a triangle.
Yes, of course. It was a hasty statement on my part. Here is what I came up with, building on posts #5 and #7. Heron's formula
##A=\sqrt{p(p-a)(p-b)(p-c)}~;~p=(a+b+c)/2##
can be transformed to
##A=\frac{1}{2}\sqrt{p(p-a)(a^2-\eta^2)}~;~\eta \equiv b-c##
Here, ##a## is the first broken piece and there is uniform probability that it be between 0 and ##p##. The remaining piece can be broken into two more pieces of which the larger piece is labeled ##b## and the smaller piece is labeled ##c##. The difference ##b-c## has uniform probability of having an upper value and a lower value. What are these limits? From ##a+c>b## it follows that ##b-c=\eta<a##. The smallest value for ##\eta## is zero in which case we have an isosceles triangle of sides ##a, p-a/2, p-a/2##. This satisfies the triangle inequality for any value ##0<a<p##.
I assume, without being 100% sure, that the expected value of the area sought by OP is given by
$$\langle A \rangle =\frac{\frac{1}{2}\int_0^p{da}\int_0^a{\sqrt{p(p-a)(a^2-\eta^2)} d \eta}} {\int_0^p{d a}\int_0^a{d \eta}}$$
The denominator integral is trivial. I found the numerator integral using Mathematica.

Edit:
There is probably one other issue. In general we have the following possibilities:
c is the left-side of first cut (covered above)
c is the left-side of second cut
c is the right-side of second cut

It seems we will also have to cover the second and third possibilities in the general case.
Just a small point. When I covered the case of c("largest side") being the left-side of first cut, I also included the possibility of it being equal to the other two sides.
So, to be rigorous, when we consider the largest side being the left-side of second cut, we might want to exclude the possibility of it being equal to the left-side of first cut (while including the possibility of its equality to the right-side of second cut).
And similarly we can exclude all equality possibilities in the case when we consider the largest side being the right-side of second cut.

Don't know whether it makes any difference in actual calculation but probably good to make this distinction anyway.

Anyway, the final result it seems will be in the form of an integral (don't know whether it would turn out to be equivalent to one in last post).

haruspex
Homework Helper
Gold Member
2020 Award
Heron's formula
There must be an easier way.
Let the stick have length 1. If the first cut is x from the left that has uniform distribution over (0,1). If the second is y from the right, that has uniform distribution over (0,1-x).
To form a triangle, we need x<1/2, y<1/2, x+y>1/2: ##\int_{x=0}^{½}\int_{y=½-x}^{½}\frac {dxdy}{1-x}##.

WWGD
kuruman
Homework Helper
Gold Member
To form a triangle, we need x<1/2, y<1/2, x+y>1/2: ##\int_{x=0}^{½}\int_{y=½-x}^{½}\frac {dxdy}{1-x}##.

I understand the upper and lower limits, but I do not understand what the double integral represents. It has dimensions of length. How is the average area taken?

I understand the upper and lower limits, but I do not understand what the double integral represents. It has dimensions of length. How is the average area taken?
There are two related problems (given the complete description in OP):
(1) Expected area of the triangle ("given" that a triangle can be formed)
(2) Percentage possibility that a triangle can be formed from the resulting sides

I suspect that haruspex's calculation might be yielding the latter quantity (or something similar) ..... but I could be wrong, I would have to look more carefully to make sure.

Last edited:
There are number of points that are confusing me tbh (so hopefully this post make some sense) .... which always seems to happen to me when thinking about probability problems.

From previous post:
"(2) Percentage possibility that a triangle can be formed from the resulting sides"
Let us denote this probability as P.

Considering the integral in post#11 (since this form is comparatively simpler) ...... To find the expectation value of area (given a triangle is formed), can't we just attach formula for area (as in post#11) inside the integral (call the resulting integral E) and then divide the resulting answer E by P** (or will there be some problem with this?).

** I am thinking of this division because the OP asked for expectation value of area "given" that we can form a triangle. If we were to assume the area as 0 say (if a triangle couldn't be formed) then the resulting expectation value of area would be like(?):
E+0*(1-P)=E

haruspex
Homework Helper
Gold Member
2020 Award
Percentage possibility that a triangle can be formed from the resulting sides
You are right, I misread the question.

Yes, but the form of your integral is simpler compared to the other suggested ones in the thread (especially mine... which seems to go in an unnecessarily complex direction).

haruspex
Homework Helper
Gold Member
2020 Award
Yes, but the form of your integral is simpler compared to the other suggested ones in the thread (especially mine... which seems to go in an unnecessarily complex direction).
Plugging Heron's formula into my integrand produces a first stage integral the same as kuruman's in complexity.

That seems to be true certainly.

WWGD
Gold Member
I understand the upper and lower limits, but I do not understand what the double integral represents. It has dimensions of length. How is the average area taken?
There are two constraints on the definition/bounds of/for area; each integral describes/defines one of the bounds.

kuruman
Homework Helper
Gold Member
There are two constraints on the definition/bounds of/for area; each integral describes/defines one of the bounds.
Each integral is also a sum. What is being added here?

WWGD
Gold Member
Each integral is also a sum. What is being added here?
You're adding the product ##\frac {dxdy}{1-x}## along both constraints given by ##x,y## respectively. The area , given as a product , has restrictions/bounds
along each of the ##x,y## variables. You add along one constraint then along the other ( for most functions you run into, order of the sum does not matter). Think of a discrete scenario, e.g., of Salary as a function of years of college and years of work experience where you want to find the average salary over, say all your workers with between 0-4 years of college and 0-5 years of experience so that there is some interaction between the factors ( i.e., non-linearity) given as a product (##dxdy## here) Then you are adding all combinations of work experience values 0-4 as well as years of college . Hope that was clear, let me know otherwise.

kuruman
Homework Helper
Gold Member
You're adding the product ##\frac {dxdy}{1-x}## along both constraints given by x,yx,y respectively.
I understand that I am adding ##\frac {dxdy}{1-x}## and I understand the constraints. What I don't understand is that, when I'm done adding, I get that the value of the integral is ##\ln(2)-1/2=0.193##. What is the meaning of ##0.193## in terms of what the problem is asking to find?

WWGD
Gold Member
I understand that I am adding ##\frac {dxdy}{1-x}## and I understand the constraints. What I don't understand is that, when I'm done adding, I get that the value of the integral is ##\ln(2)-1/2=0.193##. What is the meaning of ##0.193## in terms of what the problem is asking to find?
EDIT2: The probability that a stick of length 1, broken at random twice as described, will produce a triangle, i.e., satisfy the constraint ##a< b+c ## as a sum of " infinitesimal" probabilities for combinations of constraint pairs along ##x,y##. EDIT: More accurately, a sum of probability/area values at a choice of pairs of values for ## x,y## selected across choices of intervals ##[x_i, x_{i+1},], [y_j,y_{j+1}]## whose value converges to the sum of all values per the conditions for convergence of the Riemann integral, a.k.a, geometrically, the volume of the subset of the cube of choices of triples of values ## x,y,z## which will produce a triangle.

Last edited:
WWGD
Gold Member
EDIT2: The probability that a stick of length 1, broken at random twice as described, will produce a triangle, i.e., satisfy the constraint ##a< b+c ## as a sum of " infinitesimal" probabilities for combinations of constraint pairs along ##x,y##. EDIT: More accurately, a sum of probability/area values at a choice of pairs of values for ## x,y## selected across choices of intervals ##[x_i, x_{i+1},], [y_j,y_{j+1}]## whose value converges to the sum of all values per the conditions for convergence of the Riemann integral, a.k.a, geometrically, the volume of the subset of the cube of choices of triples of values ## x,y,z## which will produce a triangle.

Ultimately, 0.193 means: The unit cube represents the collection of all possible values the three sides of a triangle bounded by ## 0 \leq x,y,z \leq 1## that may be assumed when we cut two pieces as described. 0.193 represents the portion of the volume of ##1= 1\times 1 \times 1 ## of all these values that form a "viable" (actual) triangle. This value is obtained by adding the "infinitesimal" volumes of viable pairs. So 19.3% of all cuts produce a triangle.

kuruman
So if ##A(x,y)## is the area of the triangle in terms of segments ##x## and ##y##, then the expectation value of the area would be $$<A>=\frac{\int_0^{\frac 1 2}{d x}\int_{\frac 1 2 -x}^xA(x,y){dy}}{\ln(2)-\frac{1}{2}}.$$