
- #CST MICROWAVE STUDIO SCRIPT VBA FULL#
- #CST MICROWAVE STUDIO SCRIPT VBA CODE#
- #CST MICROWAVE STUDIO SCRIPT VBA WINDOWS#
Waveguide Port Details Port must be large enough to cover the fields of the port mode of interest.
#CST MICROWAVE STUDIO SCRIPT VBA FULL#
Waveguide Port Definition In addition to pick point, Full Plane or Free Coordinates can also be specifiedįor Separation of Degenerate Modes in Circular Waveguides Coaxial Pick Edge Also possible: any combination of pick points, edges, faces The wires attach the port to the structure Pick 2 points (or) 1 point and a face (or) enter coordinates (not recommended)ġ.
#CST MICROWAVE STUDIO SCRIPT VBA CODE#
This code creates simple geometry contain 18 wires equally distributed on create_cst_project ( name = "circular_geometry", path_to_CST_DE = path_to_CST_DE, path_to_geometry_folder = route_to_folder, path_to_CST_project = route_to_folder )

#CST MICROWAVE STUDIO SCRIPT VBA WINDOWS#
get_circular_geometry ( radius = radius, lengths_of_wires = lengths, wire_radius = 1e-3, delta_angle = 0 ) return circular_geometry # During using scripts or notebooks for creating projects # all the CST Microwave studio windows must be closed !!! # Creating an array of 18 vertical aligned wires with length 2 # on of imaginary cylinder with radius 4 circular_geometry = circular_geometry_equal_wires ( 2, 18, 4 ) output = circular_geometry. txt geometries and CST projects route_to_folder = r "Absolute\Path\To\FOLDER" def circular_geometry_equal_wires ( length, number_of_wires, radius ): lengths = circular_geometry = simple_geometries. append ( wire ) return Geometry ( wires )Įxamples from cst_geometry import simple_geometries # Path to CST DESIGN ENVIRONMENT.exe path_to_CST_DE = r "Absolute\Path\To\CST DESIGN ENVIRONMENT.exe" # Route to folder with. sin ( phi ), length / 2 ), radius = wire_radius ) wires. sin ( phi ), - length / 2 ), point1 = ( radius * np. pi, number_of_wires, endpoint = False ) + delta_angle wires = for i, length in enumerate ( lengths_of_wires ): phi = angles wire = Wire ( point0 = ( radius * np. import numpy as np from cst_geometry import Wire, Geometry def get_circular_geometry ( radius, lengths_of_wires, wire_radius = 1e-3, delta_angle = 0 ): number_of_wires = len ( lengths_of_wires ) angles = np. To create your own geometry use Wire and Geometry classes. append ( wire ) return wires wires = create_wires_by_rule () geometry = geometry ( wires ) from cst_geometry import Wire, Geometry def create_wires_by_rule (): wires = #. export_geometry is a method for exporting geometry as. create_cst_project is a method for creating a. For initializing Geometry object you should pass a list of Wire objects. Geometry object allows to easily export geometry to CST Microwave Studio or just export.
