The domain of metamaterials now covers many area of physics: electromagnetics, acoustics, mechanics, thermics, or even seismology. Huge literature is now available on the subject but the results are scattered. Although many ideas and possible applications have been proposed, which of these will emerge as a viable technology will only unfold with time.This book covers the fundamental science behind metamaterials, from the physical, mathematical, and numerical points of view, focusing mainly on methods. It concentrates on electromagnetic waves, but would also be useful in studying other types of metamaterials. It presents the structure of Maxwell equations, discusses the homogenization theory in detail, and includes important problems on resonance. It has an entire section devoted to numerical methods (finite elements, Fourier modal methods, scattering theory), which aims to motivate a reader to implement them. The book is not written as a collection of independent chapters but as a textbook with a strong pedagogical flavor.