Mathematical Anxiety is the feeling of fear or dislike when dealing with mathematically rich situations. Although MA seems innocent in general, it can seriously compromise math performance, lead to avoidance, affect the learning procedure, as well as influence future career choices and directions. The accurate recognition of MA, apart from diagnostic purposes, is considered to be very important for e-learning systems as well. This work presents an automatic system for the detection of MA based on electroencephalographic (EEG) signals. EEG, compared to self-report and psychometric questionnaires, is considered to be more objective, since it cannot be intentionally modulated as easily. We gathered multichannel EEG recordings from 32 university students. The students were grouped by different levels of MA (Low and High), evaluated with the Abbreviated Math Anxiety Scale. From these EEG signals we extracted 466 features and then we selected only one feature that was able to recognize MA with 93.75% accuracy, using a Naïve Bayesian Tree with 10-fold cross validation.