create_single_point_sweep#
- SetupHFSS.create_single_point_sweep(unit: str = 'GHz', freq: int = 1, name: str | None = None, save_single_field: bool = True, save_fields: bool = False, save_rad_fields: bool = False)#
Create a Sweep with a single frequency point.
- Parameters:
- unit
str Unit of the frequency. For example,
"MHzor"GHz".- freq
float,list Frequency of the single point or list of frequencies to create distinct single points.
- name
str,optional Name of the sweep. The default is
None, in which case a name is automatically assigned.- save_single_fieldbool,
list,optional Whether to save the fields of the single point. The default is
True. If a list is specified, the length must be the same as the frequency length.- save_fieldsbool,
optional Whether to save the fields for all points and subranges defined in the sweep. The default is
False.- save_rad_fieldsbool,
optional Whether to save only the radiating fields. The default is
False.
- unit
- Returns:
ansys.aedt.core.modules.solve_sweeps.SweepHFSSor boolSweep object if successful,
Falseotherwise.
References
>>> oModule.InsertFrequencySweep
Examples
Create a setup named
"LinearStepSetup"and use it in a single point sweep named"SinglePointSweep".>>> setup = hfss.create_setup("LinearStepSetup") >>> single_point_sweep = setup.create_single_point_sweep(name="SinglePointSweep", unit="MHz", freq=1.1e3) >>> type(single_point_sweep) <class 'from ansys.aedt.core.modules.setup_templates.SweepHFSS'>