create_equationbased_surface#
- Modeler3D.create_equationbased_surface(x_uv=0, y_uv=0, z_uv=0, u_start=0, u_end=1, v_start=0, v_end=1, name=None, **kwargs)[source]#
Create an equation-based surface.
- Parameters:
- x_uv
str
orfloat
Expression for the X-component of the surface as a function of
"_u,_v"
. For example,"cos(_u) * sin(_v)"
.- y_uv
str
orfloat
Expression for the Y-component of the surface as a function of
"_u,_v"
- z_uv
str
orfloat
Expression for the Z-component of the surface as a function of
"_u,_v"
- u_start
str
orfloat
Starting value of the parameter
"_u"
.- u_end
str
orfloat
Ending value of the parameter
"_u"
.- v_start
str
orfloat
Starting value of the parameter
"_v"
.- v_end
str
orfloat
Ending value of the parameter
"_v"
.- name
str
,optional
Name of the created surface in the 3D modeler. The default is
None
, in which case the default name is assigned.- **kwargs
optional
Additional keyword arguments may be passed when creating the primitive to set properties. See
ansys.aedt.core.modeler.cad.object_3d.Object3d
for more details.
- x_uv
- Returns:
References
>>> oEditor.CreateEquationSurface
Examples
The optional parameter
matname
allows you to set the material name. The optional parametername
allows you to assign a name to the surface.This method applies to all 3D applications: HFSS, Q3D, Icepak, Maxwell 3D, and Mechanical.
>>> from ansys.aedt.core import Hfss >>> aedtapp = Hfss() >>> surf = aedtapp.modeler.create_equationbased_surface(x_uv='(cos(_v)+2)*cos(_u)', ... y_uv='(cos(_v)+2)*sin(_u)', ... z_uv='sin(_v)', ... u_start=0, ... u_end='2*pi', ... v_start=0, ... v_end='2*pi' ... )