After 2 years, $7000 gains 14%, which is $980 so the amount in the account becomes $7980.
When the rate changes, the question is: does 8% apply to the increased amount or to the original amount?
If it applies to $7980 the amount after a further 3 years is 7980+24% of $7980=$9895.20.
If it applies to the original $7000, the amount is 7000+14% of 7000+24% of 7000=$9660.
At this point $4000 is added to the account making the total amount either $13895.20 or $13660.
If this accumulated amount is subject to 8% simple interest, after a further 4 years 7 months, the percentage increase is (4+7/12)*8=36⅔% of $13895.20 or $13660. This gives us $5094.91 or $5008.67 interest and the total amount is $18990.11 or $18668.67.
However, the amount is lower if we consider the investments as separate payments subject to simple interest over the whole of the time period in which interest is gained.
$7000 for 2 years at 7% then 3 years at 8%, then 4+7/12 years at 8%=$12226.67.
$4000 for 4+7/12 years at 8%=$5466.67.
Total=$17693.33.