[Math] Number of triangles formed by n lines and m parallel lines.

combinationscombinatoricsdiscrete mathematicsgeometry

This question was posted back in 2012, but a proper answer was never given.
Here's the question I'm stuck on: "How many triangles are formed by $n$ lines, and $m$ parallel lines, where no 3 lines can intersect at one point."

These $m$ parallel lines are all parallel to each other, so all $m$ lines have the same slope. I've been trying to draw out cases and cannot find some type of pattern. Any help would be great.

We did this for $n$ non-parallel lines, and found out that the amount of triangles formed was $\binom{n}{3}$.

So we'd have $n-m$ non-parallel lines, and we were trying to find a pattern by drawming more lines, and more non/parallel lines with no success.

Best Answer

A triangle can be formed either by 3 of the non-parallel lines or 2 of the non-parallel lines combined with one of the parallel lines (no triangle can be formed with 2 or more of the parallel lines).

therefore, the total number of triangles is $\binom{n-m}{3}$ + $\binom {n-m}{2}$ * m