Measurement of the energy penetration depth into solid targets irradiated by ultrashort laser pulses