add_eddy_current_sweep#
- SetupMaxwell.add_eddy_current_sweep(sweep_type='LinearStep', start_frequency=0.1, stop_frequency=100, step_size=0.1, units='Hz', clear=True, save_all_fields=True)#
Create a Maxwell Eddy Current Sweep.
- Parameters:
- sweep_type
str
Type of the subrange. Options are
"LinearCount"
,"LinearStep"
,"LogScale"
and"SinglePoints"
.- start_frequency
float
Starting frequency.
- stop_frequency
float
,optional
Stopping frequency. Required for
range_type="LinearCount"|"LinearStep"|"LogScale"
.- step_size
int
orfloat
,optional
Frequency count or frequency step. Required for
range_type="LinearCount"|"LinearStep"|"LogScale"
.- units
str
,optional
Unit of the frequency. For example,
"Hz
or"MHz"
. The default is"Hz"
.- clearbool,
optional
If set to
True
, all other subranges will be suppressed except the current one under creation. Default value isFalse
.- save_all_fieldsbool,
optional
Save fields at all frequency points to save fields for the entire set of sweep ranges. Default is
True
.
- sweep_type
- Returns:
ansys.aedt.core.modules.solve_sweeps.SweepMaxwellEC
Sweep object.
Examples
>>> import ansys.aedt.core >>> from ansys.aedt.core.generic.constants import SolutionsMaxwell2D >>> m2d = ansys.aedt.core.Maxwell2d(version="2025.2") >>> m2d.solution_type = SolutionsMaxwell2D.EddyCurrentXY >>> setup = m2d.create_setup() >>> sweep = setup.add_eddy_current_sweep( ... sweep_type="LinearStep", start_frequency=1, stop_frequency=20, step_size=2, units="Hz", clear=False ... ) >>> sweep.props["RangeStart"] = "0.1Hz" >>> sweep.update() >>> m2d.release_desktop()