addMirror
Description
Add-On Required: This feature requires the Optical Design and Simulation Library for Image Processing Toolbox add-on.
addMirror(
also specifies properties of the mirror using one or more name-value arguments.
For example, opsys,Name=Value)Radius=-50 specifies the radius of curvature of
the mirror as -50 millimeters.
Examples
Create a default optical system and display its properties.
opsys = opticalSystem
opsys =
opticalSystem with properties:
Main properties
Name: "Optical System"
PrimaryWavelength: 587.5618
Wavelengths: [486.1340 587.5618 656.2810]
FieldPoints: [1×1 optics.fieldpoint.FieldAngle]
Components: [0×1 optics.component.Component]
FlattenedComponents: [0×1 optics.component.Component]
Materials: [0×0 opticalMaterial]
Surfaces: [0×0 optics.surface.Surface]
SurfaceTable: [1×0 table]
Extended properties
UserData: []
ObjectPlane: [1×1 optics.component.ObjectPlane]
PrimaryWavelengthIndex: 2
AmbientMaterial: [1×1 opticalMaterial]
Coatings: [0×0 opticalCoating]
ConstructionFrame: [4×4 double]
Position: [0 0 0]
TiltAngles: [0 0 0]
Add a gap using the addGap object function.
addGap(opsys,10)
To add a mirror component to the optical system, use the addMirror function. Specify a tilt angle, using the TiltAngle name-value argument, that tilts the flat mirror 45 degrees clockwise along the x-direction. Specify the center thickness of the mirror, in millimeters, using the DistanceToNext name-value argument. The function automatically adds the specified 10 millimeter gap along the reflected optical axis, which now reflects in the positive y-direction (upwards).
addMirror(opsys,SemiDiameter=4,TiltAngles=45,DistanceToNext=10)
Add another mirror with a tilt angle of the new mirror such that the rays travel parallel to the positive z-axis. This tilt angle is -45 degrees counterclockwise relative to the positive x- axis, starting from the upward-oriented optical axis.
addMirror(opsys,SemiDiameter=4,TiltAngles=-45)
Add a gap between the mirror and the next optical component using the addGap object function.
addGap(opsys,10)
Add an image plane using the addImagePlane object.
addImagePlane(opsys,SemiDiameter=2)
Trace marginal rays through the optical system using the traceMarginalRays function, and display the optical system in 2-D using the view2d function. Add the traced rays to the visualization by using the addRays function.
hv = view2d(opsys); mr = traceMarginalRays(opsys,Wavelengths=656.261); addRays(hv,mr)

Input Arguments
Optical system to which to add the mirror as the next component, specified
as an opticalSystem object.
Name-Value Arguments
Specify optional pairs of arguments as
Name1=Value1,...,NameN=ValueN, where Name is
the argument name and Value is the corresponding value.
Name-value arguments must appear after other arguments, but the order of the
pairs does not matter.
Example: addMirror(SemiDiameter=3.0) specifies the semi-diameter
of the mirror as 3.0 millimeters.
Radius of curvature of the mirror, specified as a numeric scalar. By
default, the radius of curvature is 0, which
represents a planar surface.
Aspheric coefficients of the mirror, specified as a 20-element row
vector. The aspheric coefficients describe the aspheric profile of the
mirror. By default, both even-powered and odd-powered aspheric
coefficients are equal to zero, and the mirror is a purely conic section
without any higher-order deviations. The conic surface shape depends on
the magnitude and sign of the conic constant specified by the
ConicConstant name-value argument.
Mirror optical coating, specified as an opticalCoating object. The
addMirror function applies the coating to the
front of the mirror surface where incident rays hit. By default, the
coating is a single 200 nm layer of silver (Ag).
Mirror substrate material, specified as an opticalMaterial object. By default, the substrate
material is SiO2.
Even-powered aspheric coefficients of the mirror, specified as a 10-element row vector.
Conic constant, specified as a numeric scalar. The conic constant defines the conic shape of the mirror. Depending on the value of the conic constant K, the aspheric mirror surface has these conic shapes.
ConicConstant Value | Conic Shape |
|---|---|
K =
| Sphere |
K in range | Ellipse |
K =
| Parabola |
K in range | Hyperbola |
Normalization radius, specified as a positive scalar. The
addMirror function uses the normalization
radius to non-dimensionalize the higher-order terms in the polynomial
describing the aspheric mirror surface.
Mirror semi-diameter, in millimeters, specified as a positive scalar. The semi-diameter is the distance, along the positive y axis, from the center of the mirror to the edge of the usable optical area. This quantity is half the full diameter of the mirror.
Note
For a rectangular mirror, use the
RectangleSize name-value argument to
specify the mirror surface size, instead.
Version History
Introduced in R2026a
See Also
opticalSystem | Mirror | addRefractiveSurface | addDiaphragm | addImagePlane
MATLAB Command
You clicked a link that corresponds to this MATLAB command:
Run the command by entering it in the MATLAB Command Window. Web browsers do not support MATLAB commands.
选择网站
选择网站以获取翻译的可用内容,以及查看当地活动和优惠。根据您的位置,我们建议您选择:。
您也可以从以下列表中选择网站:
如何获得最佳网站性能
选择中国网站(中文或英文)以获得最佳网站性能。其他 MathWorks 国家/地区网站并未针对您所在位置的访问进行优化。
美洲
- América Latina (Español)
- Canada (English)
- United States (English)
欧洲
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)