The Electromagnetic Waves, Beam Envelopes (ewbe) interface (

), found under the 
Wave Optics branch (

) when adding a physics interface, is used to compute electric and magnetic field distributions for systems and devices where the field amplitude varies slowly on a wavelength scale.
 
    
    
    
    When this physics interface is added, these default nodes are also added to the Model Builder — 
Wave Equation, Beam Envelopes, 
Perfect Electric Conductor, and 
Initial Values. Then, from the 
Physics toolbar, add other nodes that implement, for example, boundary conditions. You can also right-click 
Electromagnetic Waves, Beam Envelopes to select physics features from the context menu.
 
    
    The physics-controlled mesh is controlled from the Mesh node’s 
Settings window (if the 
Sequence type is 
Physics-controlled mesh). There, in the table in the 
Physics-Controlled Mesh section, find the physics interface in the 
Contributor column and select or clear the check box in the 
Use column on the same table row for enabling (the default) or disabling contributions from the physics interface to the physics-controlled mesh.
 
    When the Use check box for the physics interface is selected, in the section for the physics interface below the table, choose the 
Mesh type — 
Swept mesh (default for 3D), 
Mapped mesh (default for 2D), 
Tetrahedral mesh (3D), and 
Triangular mesh (2D).
 
    When a structured Mesh type (either 
Swept mesh in 3D or 
Mapped mesh in 2D) is selected, enter values for 
Number of transverse mesh elements (default is 10) and 
Number of longitudinal mesh elements (default is 10). The entered 
Number of transverse mesh elements will be distributed along the longest side of the input boundary. A boundary is identified as an input boundary if there is an active feature, like a 
Port, a 
Scattering Boundary Condition, and so on, added to that boundary and the feature defines an incident wave. The mesh will be denser in domains where the refractive index is larger. Similarly, the entered 
Number of longitudinal mesh elements will be distributed along propagation direction. Also here, the mesh will be denser in domains where the refractive index is larger.
 
    
    When an unstructured Mesh type (either 
Tetrahedral mesh in 3D or 
Triangular mesh in 2D) is selected, enter a value for the 
Maximum element size in free space. The physics-controlled mesh automatically scales the maximum mesh element size as the material wavelength changes in different dielectric and magnetic regions.
 
    
    
      
      
        |  | For an example using the Physics-controlled mesh with a Swept mesh , see Directional Coupler : Application Library path Wave_Optics_Module/Waveguides_and_Couplers/directional_coupler . | 
    
    
      
      
        |  | For an example using the Physics-controlled mesh with a Triangular mesh , see Gaussian Beam Incident at the Brewster Angle : Application Library path Wave_Optics_Module/Optical_Scattering/brewster_interface | 
    
    
      
      
        |  | In the COMSOL Multiphysics Reference Manual see the Physics-Controlled Mesh  section for more information about how to define the physics-controlled mesh. | 
    
    
    The Label is the default physics interface name.
 
    The Name is used primarily as a scope prefix for variables defined by the physics interface. Refer to such physics interface variables in expressions using the pattern 
<name>.<variable_name>. In order to distinguish between variables belonging to different physics interfaces, the 
name string must be unique. Only letters, numbers, and underscores (_) are permitted in the 
Name field. The first character must be a letter.
 
    The default Name (for the first physics interface in the model) is 
ewbe.
 
    
    
    Select the Electric field components solved for — 
Three-component vector (the default), 
Out-of-plane vector, or 
In-plane vector. Select:
 
    
      
        
          | • | Three-component vector to solve using a full three-component vector for the electric field envelope(s) E1  (and E2 ). | 
      
     
    
      
        
          | • | Out-of-plane vector to solve for the electric field envelope vector component perpendicular to the modeling plane, assuming that there is no electric field in the plane. | 
      
     
    
      
        
          | • | In-plane vector to solve for the electric field envelope vector components in the modeling plane assuming that there is no electric field perpendicular to the plane. | 
      
     
    
    Select the Number of directions — 
Bidirectional (the default) or 
Unidirectional.
 
    Select the Type of phase specification — 
Wave vector (the default) or 
User defined.
 
    In the tables, if Wave vector is selected for 
Type of phase specification, enter values or expressions for the 
Wave vector, first wave k1 (SI unit: rad/m) and, if 
Bidirectional is selected, for 
Wave vector, second wave k2 (SI unit: rad/m).
 
    If User defined is selected for 
Type of phase specification, enter an expression for 
Phase, first wave 
 (SI unit: rad) and, if 
Bidirectional is selected, for 
Phase, second wave 
 (SI unit: rad).
 
    When Unidirectional is selected, the electric field is expressed as
 
    
    where E1 is the electric field envelope that is solved for and 

 is the prescribed rapidly varying phase function. When 
Wave vector is selected for 
Type of phase specification, the phase is defined as
 
    
    Notice that the wave vector k1 is assumed to be the same for all domains selected for the physics interface. This also means that the phase will satisfy the condition of being continuous everywhere. If the wave is assumed to bend or there are different materials in the domains, the phase approximation above is not good and it is better to select a 
User defined Type of phase specification. When specifying the phase expression 

, it is important that it is continuous everywhere.
 
    
    The solution for the electric field envelope E1 is as exact as the solution for the total electric field 
E, as is done for 
The Electromagnetic Waves, Frequency Domain Interface. The advantage is that the mesh only need to resolve the spatial variation of the field envelope 
E1 and not the rapid variation of the phase factor. On the other hand, for problems involving reflections and scattering there is a rapid spatial variation also for the field envelope. Then there is a no advantage of using the 
Unidirectional formulation.
 
    When Bidirectional is selected, the electric field is expressed as
 
    
    where E2 and 

 are the electric field envelope and the prescribed phase function for the second wave. When specifying 
User defined phases, 

 and 

, each phase should be continuous across the boundaries.
 
    The Bidirectional formulation is good to use when there are boundaries reflecting the wave in another direction than that of the incident wave. The direction for the reflected beam is typically in the opposite direction to the incident beam. The boundary conditions at these internal and/or external boundaries couple the electric field envelopes 
E1 and 
E2.
 
    Notice, however, that there is no coupling between E1 and 
E2 within domains, unless weak expressions are explicitly added to the domains in the Model Builder. For more information about how to add weak domain expressions, see 
Common Physics Interface and Feature Settings and Nodes.
 
    
      
      
        |  | In the COMSOL Multiphysics Reference Manual see Table 2-4  for links to common sections and Table 2-5  to common feature nodes. You can also search for information: press F1 to open the Help  window or Ctrl+F1 to open the Documentation  window. | 
    
    
      
      
        |  | For 2D and 3D, the default value for k1 (or   ) represents a wave vector pointing in the x  direction. The default value for k2 represents the wave vector for a plane wave reflected from a plane normal to the x  direction. Thus, the x -component is reversed, whereas the other components are the same as for wave vector of the incident wave. The default value for the User defined phase for the second wave,   , represents a wave propagating in the opposite direction to the first wave. | 
    
    
    
      
      
        |  | For an example using the User defined Type of phase specification, see Gaussian Beam Incident at the Brewster Angle : Application Library path Wave_Optics_Module/Optical_Scattering/brewster_interface . | 
    
    
    This section is available when the Type of phase specification is set to 
User defined. Expand the section and enter values or expressions for the 
Wave vector, first wave k1 (SI unit: rad/m) and, if 
Bidirectional is selected, for 
Wave vector, second wave k2 (SI unit: rad/m).
 
    
    
      
      
        |  | For an example using the User Defined Wave Vector section with a user defined wave vector setting, see Tapered Waveguide : Application Library path Wave_Optics_Module/Waveguides_and_Couplers/tapered_waveguide | 
    
    
    Select the Activate port sweep check box to switch on the port sweep. When selected, this invokes a parametric sweep over the ports in addition to the automatically generated frequency or wavelength sweep.
 
    For Activate port sweep enter a 
Sweep parameter name to assign a specific name to the variable that controls the port number solved for during the sweep.
 
    For this physics interface, the S-parameters are subject to Touchstone file export. Click 
Browse to locate the file, or enter a filename and path. Select an 
Parameter format (value pairs) — 
Magnitude angle, 
Magnitude (dB) angle, or 
Real imaginary.
 
    Select an option from the If file exists list — 
Overwrite (the default) or 
Create new.
 
    Enter a Reference impedance, Touchstone file export. The default is 50 
Ω.
 
    
    To display this section, click the Show More Options button (

) and select 
Advanced Physics Options in the 
Show More Options dialog box.
 
    Select Weak formulation (the default) or 
Constraint-based from the 
Port formulation list. For a more detailed discussion of these options, see 
Port Options in the documentation of 
The Electromagnetic Waves, Frequency Domain Interface.
 
    
    Select the Use averaged loss calculation check box to remove cross terms between the two waves, when calculating the electromagnetic loss (and heat source) in the bidirectional formulation. This setting can be useful when the cross terms create a beating field that is not resolved by the mesh. If this spatially fast varying heat source distribution anyhow is washed out by the heat transfer, it can be advantageous to not include the cross terms when calculating the electromagnetic loss (and heat source). If the cross terms are of importance when solving the associated heat transfer problem, use a mesh that is fine enough to resolve the fast spatial variations of the heat source.
 
    
    Select the shape order for the Electric field envelopes dependent variables — 
Linear, 
Linear type 2, 
Quadratic (the default), 
Quadratic type 2, 
Cubic, or 
Cubic type 2. For more information about the 
Discretization section, see 
Settings for the Discretization Sections in the 
COMSOL Multiphysics Reference Manual.
 
    
    
    
    
    
      
        
          | • | Electric field envelope, second wave E2 and its components (in the Electric field envelope components, second wave  fields). The second wave is applicable if the Wave Vectors are bidirectional. |