In this paper, methods for constructing a real head model from MRI (Magneti
c Resonance Imaging) data and its boundary element mesh are proposed. Based
on this real head model, forward computations of electroencephalo-graphy a
nd magnetoencephalography are investigated and numerical simulation results
are presented. Deflation is adopted in order to solve the singularity of d
iscrete system equations in boundary element method. Isolated problem appro
ach is applied to overcome the smear effect of skull conductivity. An impro
ved auto solid angle algorithm is developed to speed up the computation of
kernel matrix.