The two triangles are simillar due to AAA theorem. This means that equivalent sides of the triangles are proportional, which means that we can create a relationship between them.
We were given the measurements for sides BD and EF. We were also told that BD is twice the length of ED, therefore we have:
![\begin{gathered} (BC)/(EF)=(BD)/(ED) \\ (2\cdot ED)/(4)=(8)/(ED) \\ ED^2=2\cdot8 \\ ED^2=16 \\ ED=\sqrt[]{16} \\ ED=4 \end{gathered}](https://img.qammunity.org/2023/formulas/mathematics/college/8709s0rvdykhfcl3a4ycb8qiimexackyyp.png)
The length of ED is equal to 4.