Material
Class representing an electromagnetic material.
Contents
Description
Material represents an electromagnetic material with electric permittivity and magnetic permeability. Users should provide the name and color of the material in the constructor
Construction
mat = Material(name, color, eps, [islossless]) mat = Material(name, color, eps, mu, [islossless])
Input Arguments
- name: name of the material. Used to distinguish materials and label them in figures.
- color: color of the material. Used to visualize the material in figures. It can be MATLAB's reserved color code characters (e.g., 'r' for red, 'k' for black) or an RGB code [r g b] where r, g, b are real numbers between 0 and 1. Use color = 'none' to hide the objects made of this material in figures.
- eps: electric permittivity of the material.
- mu: magnetic permeability of the material. If unassigned, the default value mu = 1 is used.
- islossless: optional argument. true to ignore the loss or gain in material; false otherwise. The default value is false.
Example
% Create an instance of Material. vacuum = Material('vacuum', 'none', 1.0);
% Use the constructed material in maxwell_run(). [E, H] = maxwell_run({INITIAL ARGUMENTS}, 'OBJ', vacuum, Box([0 100; 0 50; 0 20]), {REMAINING ARGUMENTS});