The connection between higher BMI and greater cognitive decline with age is being blamed on inflammation.
Data from the English Longitudinal Study of Aging, involving some 21,500 older adults (50+) showed that, the higher the BMI at the start, the greater the rise in lovels of C-reactive protein over the next four years. CRP is a marker in the blood of systemic inflammation. This 4-year change in CRP predicted change in cognition six years after the start of the study.
https://www.eurekalert.org/pub_releases/2016-10/uoa-hyb101716.php
Bourassa, K., & Sbarra, D. A. (2017). Body mass and cognitive decline are indirectly associated via inflammation among aging adults. Brain, Behavior, and Immunity, 60, 63–70. https://doi.org/10.1016/j.bbi.2016.09.023
