Explain in detail the role of functional mri in the diagnosis of dementia?