Immediately after passing under the inguinal ligament, the femoral nerve divides into anterior and posterior branches, which supply muscles of the anterior compartment of the thigh and skin on the anterior and medial aspects of the thigh and on the medial sides of the leg and foot.