Analysis of mental activity based on EEG