Main Content

stlwrite

Write mesh to STL file

Description

example

stlwrite(objname,filename) writes the triangles in the mesh for an antenna or array object to an STL file in text format using the specified file name.

Examples

collapse all

Create a DipoleHelix antenna object at 2 GHz and compute the impedance.

w = design(dipoleHelix,2e9);
Z = impedance(w,2e9);

Create an STL file for DipoleHelix antenna object .

stlwrite(w,'dipoleHelix_2GHz.stl')

You will see the dipoleHelix_2GHz.stl file in your current folder.

Load dipoleHelix_2GHz.stl and visualize the platform.

plat = platform('FileName','dipoleHelix_2GHz.stl','Units','m')
plat = 
  platform with properties:

         FileName: 'dipoleHelix_2GHz.stl'
            Units: 'm'
    UseFileAsMesh: 0
             Tilt: 0
         TiltAxis: [1 0 0]

show(plat)

Figure contains an axes object. The axes object with title Platform object contains 2 objects of type patch. This object represents PEC.

Input Arguments

collapse all

Antenna or array object, specified as an antenna or array.

Name of STL file, specified as a character vector in STL format.

Introduced in R2019a