== EM.Cube's Python Functions for Simulation-Related Functions & Operations ==
====select_module({{ArgTypeString}} module_name)====
''ExampleSYNTAX: select_module("[[EM.Tempo]]"{{ArgTypeString}} module_name)''
DescriptionEXAMPLE: Selects and sets ''select_module("[[EM.CubeTempo]]")''s active module.
====set_units({{ArgTypeString}} units)====DESCRIPTION: Selects and sets [[EM.Cube]]'s active module.
''Example: ====set_units("meter")''====
DescriptionSYNTAX: Sets [[EM.Cube]]'s project length set_units({{ArgTypeString}} units.)
====set_frequencyEXAMPLE: ''set_units({{ArgTypeAny}} value"meter")====''
''ExampleDESCRIPTION: set_frequency(2Sets [[EM.4e9)'Cube]]'s project length units.
Description: Sets [[EM.Cube]]'s center frequency.====set_frequency====
====set_bandwidthSYNTAX: set_frequency({{ArgTypeAny}} value)====
EXAMPLE: ''Example: set_bandwidthset_frequency(1e92.4e9)''
DescriptionDESCRIPTION: Sets [[EM.Cube]]'s center frequency bandwidth.
====background_layer({{ArgTypeString}} label, {{ArgTypeAny}} eps, {{ArgTypeAny}} sigma, {{ArgTypeAny}} mu, {{ArgTypeAny}} thickness)set_bandwidth====
''ExampleSYNTAX: background_layerset_bandwidth("Mid_Layer",3.3,0.001,1,1.5{{ArgTypeAny}} value)''
DescriptionEXAMPLE: Adds a new substrate layer to [[EM.Picasso]]'s background layer stackup.'set_bandwidth(1e9)''
====delete_background_layer({{ArgTypeString}} label)====DESCRIPTION: Sets [[EM.Cube]]'s frequency bandwidth.
''Example: delete_background_layer("Mid_Layer")''====background_layer====
DescriptionSYNTAX: Deletes a finite-background_layer({{ArgTypeString}} label, {{ArgTypeAny}} eps, {{ArgTypeAny}} sigma, {{ArgTypeAny}} mu, {{ArgTypeAny}} thickness substrate layer from [[EM.Picasso]]'s background layer stackup.)
====set_stackup_orderEXAMPLE: ''background_layer("THSMid_Layer", {{ArgTypeString}} label_1, {{ArgTypeString}} label_23.3, 0...001, {{ArgTypeString}} label_n1, "BHS"1.5)====''
''ExampleDESCRIPTION: background_layer("THS","Top_Layer","Mid_Layer","Bottom_Layer","BHS")'Adds a new substrate layer to [[EM.Picasso]]'s background layer stackup.
Description: Sets the hierarchy of [[EM.Picasso]]'s background layer stackup from top to bottom. The sequence should always start with "THS" standing for the top half-space and must end in "BHS" standing for the bottom half-space. All the intermediate finite-thickness substrate layers must be included and listed in the right order. ====delete_background_layer====
====global_groundSYNTAX: delete_background_layer({{ArgTypeAnyArgTypeString}} ground_on, {{ArgTypeAny}} eps, {{ArgTypeAny}} sigmalabel)====
EXAMPLE: ''Example: global_grounddelete_background_layer(1,3.3,0.001"Mid_Layer")''
DescriptionDESCRIPTION: Set the state of Deletes a finite-thickness substrate layer from [[EM.TerranoPicasso]]'s global ground and its material properties. A zero value for ground_on means to no global ground assumed at Z = 0background layer stackup.
====delete({{ArgTypeString}} node_name)set_stackup_order====
''ExampleSYNTAX: deleteset_stackup_order("Box_1THS", {{ArgTypeString}} label_1, {{ArgTypeString}} label_2, ..., {{ArgTypeString}} label_n, "BHS")''
DescriptionEXAMPLE: Deletes a node name from the navigation tree. The node can be any geometric object''background_layer("THS", source"Top_Layer", observable or material group. "Mid_Layer","Bottom_Layer","BHS")''
====rename({{ArgTypeString}} new_label, {{ArgTypeString}} old_label)====DESCRIPTION: Sets the hierarchy of [[EM.Picasso]]'s background layer stackup from top to bottom. The sequence should always start with "THS" standing for the top half-space and must end in "BHS" standing for the bottom half-space. All the intermediate finite-thickness substrate layers must be included and listed in the right order.
''Example: rename("Box_2","Box_1")''====global_ground====
DescriptionSYNTAX: Deletes a node name from the navigation tree. The node can be any geometric objectglobal_ground({{ArgTypeAny}} ground_on, source{{ArgTypeAny}} eps, observable or material group. {{ArgTypeAny}} sigma)
====zoom_extentsEXAMPLE: ''global_ground(1,3.3,0.001)====''
DescriptionDESCRIPTION: Zooms to fit Set the extents state of the physical structure into the screen[[EM.Terrano]]'s global ground and its material properties. A zero value for ground_on means to no global ground assumed at Z = 0.
====get_domain_extent({{ArgTypeString}} coordinate)delete====
''ExampleSYNTAX: get_domain_extentdelete("x"{{ArgTypeString}} node_name)''
DescriptionEXAMPLE: Returns the size of the computational domain along the specified direction.''delete("Box_1")''
====set_domain_offset({{ArgTypeAny}} dxn_offsetDESCRIPTION: Deletes a node name from the navigation tree. The node can be any geometric object, {{ArgTypeAny}} dxp_offsetsource, {{ArgTypeAny}} dyn_offset, {{ArgTypeAny}} dyp_offset, {{ArgTypeAny}} dzn_offset, {{ArgTypeAny}} dzp_offset)====observable or material group.
''Example: set_domain_offset(20,20,20,20,0,10)''====rename====
DescriptionSYNTAX: Sets the domain offset values along the ±Xrename({{ArgTypeString}} new_label, ±Y and ±Z directions in project units.{{ArgTypeString}} old_label)
====set_domain_offset_lambdaEXAMPLE: ''rename({{ArgTypeAny}} dxn_offset"Box_2", {{ArgTypeAny}} dxp_offset, {{ArgTypeAny}} dyn_offset, {{ArgTypeAny}} dyp_offset, {{ArgTypeAny}} dzn_offset, {{ArgTypeAny}} dzp_offset"Box_1")====''
''ExampleDESCRIPTION: set_domain_offset_lambda(0Deletes a node name from the navigation tree.1The node can be any geometric object,0.1,0.1,0.1,0source,0observable or material group.25)''
Description: Sets the domain offset values along the ±X, ±Y and ±Z directions in free-space wavelengths.====zoom_extents====
====set_boundary_conditionsSYNTAX: zoom_extents({{ArgTypeString}} xn_type, {{ArgTypeString}} xp_type, {{ArgTypeString}} yn_type, {{ArgTypeString}} yp_type, {{ArgTypeString}} zn_type, {{ArgTypeString}} zp_type)====
''ExampleDESCRIPTION: set_domain_offset_lambda("pml","pml","pml","pml","pec","pml")''Zooms to fit the extents of the physical structure into the screen.
Description: Sets [[EM.Tempo]]'s domain boundary conditions domain offset on the ±X, ±Y and ±Z boundary walls. The options are "pec", "pmc" and "pml".====get_domain_extent====
====add_variableSYNTAX: get_domain_extent({{ArgTypeString}} var_name, {{ArgTypeAny}} valuecoordinate)====
EXAMPLE: ''Example: add_variableget_domain_extent("MyVarx",1)''
DescriptionDESCRIPTION: Adds a new variable to [[EM.Cube]]'s variable listReturns the size of the computational domain along the specified direction.
====run_analysis()set_domain_offset====
DescriptionSYNTAX: Runs a simulation in the current active [[EM.Cube]] computational module.set_domain_offset({{ArgTypeAny}} dxn_offset, {{ArgTypeAny}} dxp_offset, {{ArgTypeAny}} dyn_offset, {{ArgTypeAny}} dyp_offset, {{ArgTypeAny}} dzn_offset, {{ArgTypeAny}} dzp_offset)
====set_periodicEXAMPLE: ''set_domain_offset({{ArgTypeAny}} is_periodic20, {{ArgTypeAny}} spacingX20, {{ArgTypeAny}} spacingY20,20,0,10) ====''
''ExampleDESCRIPTION: set_periodic(1Sets the domain offset values along the ±X,50,50)''±Y and ±Z directions in project units.
Description: Designates the physical structure as periodic and sets the periods along the X and Y directions.====set_domain_offset_lambda====
====get_standard_outputSYNTAX: set_domain_offset_lambda({{ArgTypeStringArgTypeAny}} output_namedxn_offset, {{ArgTypeAny}} dxp_offset, {{ArgTypeAny}} dyn_offset, {{ArgTypeAny}} dyp_offset, {{ArgTypeAny}} dzn_offset, {{ArgTypeAny}} dzp_offset) ====
EXAMPLE: ''Example: get_standard_outputset_domain_offset_lambda("S11M"0.1,0.1,0.1,0.1,0,0.25)''
DescriptionDESCRIPTION: Returns Sets the computed value of domain offset values along the specified standard output parameter at the end of a simulation±X, ±Y and ±Z directions in free-space wavelengths.
====save_data({{ArgTypeString}} directory_name) set_boundary_conditions====
''ExampleSYNTAX: save_dataset_boundary_conditions("Simulation_Data"{{ArgTypeString}} xn_type, {{ArgTypeString}} xp_type, {{ArgTypeString}} yn_type, {{ArgTypeString}} yp_type, {{ArgTypeString}} zn_type, {{ArgTypeString}} zp_type)''
DescriptionEXAMPLE: Saves [[EM.Cube]]'s output simulation data files under the specified directory.'set_domain_offset_lambda("pml","pml","pml","pml","pec","pml")''
====plot_file({{ArgTypeString}} filename) ====DESCRIPTION: Sets [[EM.Tempo]]'s domain boundary conditions domain offset on the ±X, ±Y and ±Z boundary walls. The options are "pec", "pmc" and "pml".
''Example: plot_file("D0.DAT")''====add_variable====
DescriptionSYNTAX: Plots the contents of a specified data file in EM.Grid.add_variable({{ArgTypeString}} var_name, {{ArgTypeAny}} value)
====meshEXAMPLE: ''add_variable("MyVar",1)====''
DescriptionDESCRIPTION: Generates and displays the mesh of the physical structureAdds a new variable to [[EM.Cube]]'s variable list.
====emtempo_mesh_settings({{ArgTypeAny}} cells_per_lambda, {{ArgTypeAny}} ratio_contour, {{ArgTypeAny}} ratio_thin, {{ArgTypeAny}} ratio_abs)run_analysis====
''ExampleSYNTAX: emtempo_mesh_settingsrun_analysis(30,0.1,0.1,0.02)''
DescriptionDESCRIPTION: Sets Runs a simulation in the parameters of current active [[EM.TempoCube]]'s adaptive mesh generatorcomputational module.
====emillumina_mesh_settings({{ArgTypeAny}} cells_per_lambda)set_periodic====
''ExampleSYNTAX: emillumina_mesh_settingsset_periodic(30{{ArgTypeAny}} is_periodic, {{ArgTypeAny}} spacingX, {{ArgTypeAny}} spacingY)''
DescriptionEXAMPLE: Sets the parameters of [[EM.Illumina]]'s mesh generator.'set_periodic(1,50,50)''
====empicasso_mesh_settings({{ArgTypeAny}} cells_per_lambda)====DESCRIPTION: Designates the physical structure as periodic and sets the periods along the X and Y directions.
''Example: empicasso_mesh_settings(30)''====get_standard_output====
DescriptionSYNTAX: Sets the parameters of [[EM.Picasso]]'s planar hybrid mesh generator.get_standard_output({{ArgTypeString}} output_name)
====emlibera_mesh_settingsEXAMPLE: ''get_standard_output({{ArgTypeAny}} cells_per_lambda"S11M")====''
''ExampleDESCRIPTION: emlibera_mesh_settings(30)''Returns the computed value of the specified standard output parameter at the end of a simulation.
Description: Sets the parameters of [[EM.Libera]]'s mesh generator.====save_data====
====emferma_mesh_settingsSYNTAX: save_data({{ArgTypeAnyArgTypeString}} cell_size_x, {{ArgTypeAny}} cell_size_y, {{ArgTypeAny}} cell_size_zdirectory_name)====
EXAMPLE: ''Example: emferma_mesh_settingssave_data(0.5,0.5,0.5"Simulation_Data")''
DescriptionDESCRIPTION: Sets the parameters of Saves [[EM.FermaCube]]'s fixed-cell mesh generatoroutput simulation data files under the specified directory.
====emterrano_mesh_settings({{ArgTypeAny}} edge_length, {{ArgTypeAny}} angle_tol)plot_file====
''ExampleSYNTAX: emterrano_mesh_settingsplot_file(5,10{{ArgTypeString}} filename)''
DescriptionEXAMPLE: Sets the parameters of [[EM.Terrano]]'s facet mesh generator'plot_file("D0.DAT")''
====cubecad_mesh_settings({{ArgTypeAny}} edge_length, {{ArgTypeAny}} angle_tol)====DESCRIPTION: Plots the contents of a specified data file in EM.Grid.
''Example: cubecad_mesh_settings(5,10)''====mesh====
DescriptionSYNTAX: Sets the parameters of CubeCAD's mesh generator.()
====emtempo_engine_settings({{ArgTypeString}} engine, {{ArgTypeAny}} power_threshhold, {{ArgTypeAny}} max_timesteps)====DESCRIPTION: Generates and displays the mesh of the physical structure.
''Example: emtempo_engine_settings("single-precision",-50,20000)''====emtempo_mesh_settings====
DescriptionSYNTAX: Sets the parameters of [[EM.Tempo]]'s FDTD simulation engine.emtempo_mesh_settings({{ArgTypeAny}} cells_per_lambda, {{ArgTypeAny}} ratio_contour, {{ArgTypeAny}} ratio_thin, {{ArgTypeAny}} ratio_abs)
====emterrano_engine_settingsEXAMPLE: ''emtempo_mesh_settings({{ArgTypeAny}} bounce_count30, {{ArgTypeAny}} do_edge_diffraction0.1, {{ArgTypeAny}} angular_resolution0.1, {{ArgTypeAny}} ray_threshhold0.02)====''
''ExampleDESCRIPTION: emterrano_engine_settings(5,1,1,-100)'Sets the parameters of [[EM.Tempo]]'s adaptive mesh generator.
Description: Sets the parameters of [[EM.Terrano]]'s SBR simulation engine.====emillumina_mesh_settings====
====empicasso_engine_settingsSYNTAX: emillumina_mesh_settings({{ArgTypeString}} matrix_solver, {{ArgTypeAny}} error_tol, {{ArgTypeAny}} max_iterationscells_per_lambda)====
EXAMPLE: ''Example: empicasso_engine_settingsemillumina_mesh_settings("bicg",1e-3,100030)''
DescriptionDESCRIPTION: Sets the parameters of [[EM.PicassoIllumina]]'s planar MoM simulation enginemesh generator.
====emillumina_engine_settings({{ArgTypeString}} engine, {{ArgTypeAny}} is_fixed_iteration, {{ArgTypeAny}} error_tol, {{ArgTypeAny}} max_iterations)empicasso_mesh_settings====
''ExampleSYNTAX: emillumina_engine_settingsempicasso_mesh_settings("ipo",0,1e-2,20{{ArgTypeAny}} cells_per_lambda)''
DescriptionEXAMPLE: Sets the parameters of [[EM.Illumina]]'s Physical Optics simulation engine.'empicasso_mesh_settings(30)''
====emferma_engine_settings({{ArgTypeString}} matrix_solver, {{ArgTypeAny}} error_tol, {{ArgTypeAny}} max_iterations)====DESCRIPTION: Sets the parameters of [[EM.Picasso]]'s planar hybrid mesh generator.
''Example: emferma_engine_settings("bicg-stab",1e-3,100)''====emlibera_mesh_settings====
DescriptionSYNTAX: Sets the parameters of [[EM.Ferma]]'s electrostatic and magnetostatic simulation engines.emlibera_mesh_settings({{ArgTypeAny}} cells_per_lambda)
====emlibera_engine_settings_wmomEXAMPLE: ''emlibera_mesh_settings({{ArgTypeString}} matrix_solver, {{ArgTypeAny}} error_tol, {{ArgTypeAny}} max_iterations30)====''
''ExampleDESCRIPTION: emlibera_engine_settings_wmom("bicg",1e-3,1000)'Sets the parameters of [[EM.Libera]]'s mesh generator.
Description: Sets the parameters of [[EM.Libera]]'s wire MoM simulation engines.====emferma_mesh_settings====
====emlibera_engine_settings_smomSYNTAX: emferma_mesh_settings({{ArgTypeString}} matrix_solver, {{ArgTypeAny}} error_tolcell_size_x, {{ArgTypeAny}} max_iterations, {{ArgTypeAny}} ncpus, {{ArgTypeString}} formulationcell_size_y, {{ArgTypeAny}} alphacell_size_z)====
EXAMPLE: ''Example: emlibera_engine_settings_smomemferma_mesh_settings("bicg"0.5,1e-3,1000,4,"efie"0.5,0.45)''
DescriptionDESCRIPTION: Sets the parameters of [[EM.Ferma]]'s fixed-cell mesh generator. ====emterrano_mesh_settings==== SYNTAX: emterrano_mesh_settings({{ArgTypeAny}} edge_length, {{ArgTypeAny}} angle_tol) EXAMPLE: ''emterrano_mesh_settings(5,10)'' DESCRIPTION: Sets the parameters of [[EM.Terrano]]'s facet mesh generator. ====cubecad_mesh_settings==== SYNTAX: cubecad_mesh_settings({{ArgTypeAny}} edge_length, {{ArgTypeAny}} angle_tol) EXAMPLE: ''cubecad_mesh_settings(5,10)'' DESCRIPTION: Sets the parameters of CubeCAD's mesh generator. ====emtempo_engine_settings==== SYNTAX: emtempo_engine_settings({{ArgTypeString}} engine, {{ArgTypeAny}} power_threshhold, {{ArgTypeAny}} max_timesteps) EXAMPLE: ''emtempo_engine_settings("single-precision",-50,20000)'' DESCRIPTION: Sets the parameters of [[EM.Tempo]]'s FDTD simulation engine. ====emterrano_engine_settings==== SYNTAX: emterrano_engine_settings({{ArgTypeAny}} bounce_count, {{ArgTypeAny}} do_edge_diffraction, {{ArgTypeAny}} angular_resolution, {{ArgTypeAny}} ray_threshhold) EXAMPLE: ''emterrano_engine_settings(5,1,1,-100)'' DESCRIPTION: Sets the parameters of [[EM.Terrano]]'s SBR simulation engine. ====empicasso_engine_settings==== SYNTAX: empicasso_engine_settings({{ArgTypeString}} matrix_solver, {{ArgTypeAny}} error_tol, {{ArgTypeAny}} max_iterations) EXAMPLE: ''empicasso_engine_settings("bicg",1e-3,1000)'' DESCRIPTION: Sets the parameters of [[EM.Picasso]]'s planar MoM simulation engine. ====emillumina_engine_settings==== SYNTAX: emillumina_engine_settings({{ArgTypeString}} engine, {{ArgTypeAny}} is_fixed_iteration, {{ArgTypeAny}} error_tol, {{ArgTypeAny}} max_iterations) EXAMPLE: ''emillumina_engine_settings("ipo",0,1e-2,20)'' DESCRIPTION: Sets the parameters of [[EM.Illumina]]'s Physical Optics simulation engine. ====emferma_engine_settings==== SYNTAX: emferma_engine_settings({{ArgTypeString}} matrix_solver, {{ArgTypeAny}} error_tol, {{ArgTypeAny}} max_iterations) EXAMPLE: ''emferma_engine_settings("bicg-stab",1e-3,100)'' DESCRIPTION: Sets the parameters of [[EM.Ferma]]'s electrostatic and magnetostatic simulation engines. ====emlibera_engine_settings_wmom==== SYNTAX: emlibera_engine_settings_wmom({{ArgTypeString}} matrix_solver, {{ArgTypeAny}} error_tol, {{ArgTypeAny}} max_iterations) EXAMPLE: ''emlibera_engine_settings_wmom("bicg",1e-3,1000)'' DESCRIPTION: Sets the parameters of [[EM.Libera]]'s wire MoM simulation engines. ====emlibera_engine_settings_smom==== SYNTAX: emlibera_engine_settings_smom({{ArgTypeString}} matrix_solver, {{ArgTypeAny}} error_tol, {{ArgTypeAny}} max_iterations, {{ArgTypeAny}} ncpus, {{ArgTypeString}} formulation, {{ArgTypeAny}} alpha) EXAMPLE: ''emlibera_engine_settings_smom("bicg",1e-3,1000,4,"efie",0.4)'' DESCRIPTION: Sets the parameters of [[EM.Libera]]'s surface MoM simulation engines.
<p> </p>