Let x represent length of smallest piece.
We have been given that the longest piece is 13 inches longer than three times the smallest piece. So length of longest piece would be [tex]3x+13[/tex].
The middle piece is 5 inches less than the longest piece. So length of middle piece would be [tex]3x+13-5=3x+8[/tex].
We have been given that the length of pipe is 7 foot.
1 feet = 12 inches.
7 feet = 7*12 inches = 84 inches.
Now we will equate the sum of lengths of 3 pipes with 84 as:
[tex]x+3x+13+3x+8=84[/tex]
Let us solve for x.
[tex]7x+21=84[/tex]
[tex]7x+21-21=84-21[/tex]
[tex]7x=63[/tex]
[tex]\frac{7x}{7}=\frac{63}{7}[/tex]
[tex]x=9[/tex]
Length of middle piece would be [tex]3x+8\Rightarrow 3(9)+8=27+8=35[/tex].
Therefore, the middle piece is 35 inches long.