Effective length of beam

Hello guys I need help, I’m trying to get the effective length (according to the image is A + B), the beam is intercepted with an element (Foundation). The cut length value is the total length. Any recommendation.