The functional status of patients with dementia in a geriatric hospital