The magnetoelectric effect of composites and polycrystals