bluemira.equilibria.shapes ========================== .. py:module:: bluemira.equilibria.shapes .. autoapi-nested-parse:: Useful parameterisations for plasma flux surface shapes. Classes ------- .. autoapisummary:: bluemira.equilibria.shapes.ZakharovLCFS bluemira.equilibria.shapes.CunninghamLCFS bluemira.equilibria.shapes.ManickamLCFS bluemira.equilibria.shapes.KuiroukidisLCFS bluemira.equilibria.shapes.JohnerLCFS Functions --------- .. autoapisummary:: bluemira.equilibria.shapes.flux_surface_hirshman bluemira.equilibria.shapes.flux_surface_zakharov bluemira.equilibria.shapes.flux_surface_cunningham bluemira.equilibria.shapes.flux_surface_manickam bluemira.equilibria.shapes.flux_surface_kuiroukidis bluemira.equilibria.shapes.flux_surface_johner Module Contents --------------- .. py:function:: flux_surface_hirshman(r_0: float, z_0: float, a: float, kappa: float, n: int = 20) -> bluemira.geometry.coordinates.Coordinates Hirshman and Neilson flux surface parameterisation. :param r_0: Plasma magnetic axis radius [m] :param z_0: Plasma magnetic axis height [m] :param a: Plasma geometric minor radius [m] :param kappa: Plasma elongation :param n: Number of points :rtype: Plasma flux surface shape .. rubric:: Notes .. doi:: 10.1063/1.865934 :title: Hirshman and Neilson, "External inductance of an axisymmetric plasma", 1986 .. py:function:: flux_surface_zakharov(r_0: float, z_0: float, a: float, kappa: float, delta: float, n: int = 20) -> bluemira.geometry.coordinates.Coordinates As featured in Zakharov's EMEQ :param r_0: Plasma magnetic axis radius [m] :param z_0: Plasma magnetic axis height [m] :param a: Plasma geometric minor radius [m] :param kappa: Plasma elongation :param delta: Plasma triangularity :param n: Number of points :rtype: Plasma flux surface shape .. rubric:: Notes https://inis.iaea.org/collection/NCLCollectionStore/_Public/17/074/17074881.pdf?r=1 Shafranov shift should be included in the r_0 parameter, as R_0 is defined in the above as the magnetic axis. The Shafranov shift is not subtracted to the r coordinates, contrary to the above equation (4). This is because benchmarking with EMEQ shows this does not appear to occur. .. py:class:: ZakharovLCFS(var_dict: bluemira.utilities.opt_variables.VarDictT | None = None) Bases: :py:obj:`bluemira.geometry.parameterisations.GeometryParameterisation`\ [\ :py:obj:`ZakharovLCFSOptVariables`\ ] .. autoapi-inheritance-diagram:: bluemira.equilibria.shapes.ZakharovLCFS :parts: 1 :private-bases: Zakharov last closed flux surface geometry parameterisation. .. py:attribute:: __slots__ :value: () .. py:method:: create_shape(label: str = 'LCFS', n_points: int = 1000) -> bluemira.geometry.wire.BluemiraWire Make a CAD representation of the Zakharov LCFS. :param label: Label to give the wire :param n_points: Number of points to use when creating the Bspline representation :rtype: CAD Wire of the geometry .. py:function:: flux_surface_cunningham(r_0: float, z_0: float, a: float, kappa: float, delta: float, delta2: float = 0.0, n: int = 20) -> bluemira.geometry.coordinates.Coordinates As featured in Geof Cunningham's FIESTA (shape_fun) :param r_0: Plasma geometric major radius [m] :param z_0: Plasma geometric vertical height [m] :param a: Plasma geometric minor radius [m] :param kappa: Plasma elongation :param delta: Plasma triangularity :param delta2: Plasma "delta2" curliness? :param n: Number of points :rtype: Plasma flux surface shape .. rubric:: Notes This parameterisation does not appear to match delta perfectly for abs(delta) > 0 and delta2=0. .. py:class:: CunninghamLCFS(var_dict: bluemira.utilities.opt_variables.VarDictT | None = None) Bases: :py:obj:`bluemira.geometry.parameterisations.GeometryParameterisation`\ [\ :py:obj:`CunninghamLCFSOptVariables`\ ] .. autoapi-inheritance-diagram:: bluemira.equilibria.shapes.CunninghamLCFS :parts: 1 :private-bases: Cunningham last closed flux surface geometry parameterisation. .. py:attribute:: __slots__ :value: () .. py:method:: create_shape(label: str = 'LCFS', n_points: int = 1000) -> bluemira.geometry.wire.BluemiraWire Make a CAD representation of the Cunningham LCFS. :param label: Label to give the wire :param n_points: Number of points to use when creating the Bspline representation :rtype: CAD Wire of the geometry .. py:function:: flux_surface_manickam(r_0: float, z_0: float, a: float, kappa: float = 1.0, delta: float = 0.0, indent: float = 0.0, n: int = 20) -> bluemira.geometry.coordinates.Coordinates J. Manickam, Nucl. Fusion 24 595 (1984) :param r_0: Plasma geometric major radius [m] :param z_0: Plasma geometric vertical height [m] :param a: Plasma geometric minor radius [m] :param kappa: Plasma elongation :param delta: Plasma triangularity :param indent: Plasma indentation (beaniness) :param n: Number of points :rtype: Plasma flux surface shape .. rubric:: Notes This parameterisation does not appear to match delta perfectly for abs(delta) > 0 and indent=0. .. py:class:: ManickamLCFS(var_dict: bluemira.utilities.opt_variables.VarDictT | None = None) Bases: :py:obj:`bluemira.geometry.parameterisations.GeometryParameterisation`\ [\ :py:obj:`ManickamLCFSOptVariables`\ ] .. autoapi-inheritance-diagram:: bluemira.equilibria.shapes.ManickamLCFS :parts: 1 :private-bases: Manickam last closed flux surface geometry parameterisation. .. py:attribute:: __slots__ :value: () .. py:method:: create_shape(label: str = 'LCFS', n_points: int = 1000) -> bluemira.geometry.wire.BluemiraWire Make a CAD representation of the Manickam LCFS. :param label: Label to give the wire :param n_points: Number of points to use when creating the Bspline representation :rtype: CAD Wire of the geometry .. py:function:: flux_surface_kuiroukidis(r_0: float, z_0: float, a: float, kappa_u: float, kappa_l: float, delta_u: float, delta_l: float, n_power: int = 8, n_points: int = 100) -> bluemira.geometry.coordinates.Coordinates Make an up-down asymmetric flux surface with a lower X-point. .. doi:: 10.1088/0741-3335/57/7/078001 :title: Ap. Kuiroukidis and G. N. Throumoulopoulos, Plasma Phys. Control. Fusion 57 (2015) :param r_0: Plasma geometric major radius [m] :param z_0: Plasma geometric vertical height [m] :param a: Plasma geometric minor radius [m] :param kappa_u: Upper plasma elongation :param kappa_l: Lower plasma elongation :param delta_u: Upper plasma triangularity :param delta_l: Lower plasma triangularity :param n_power: Exponent related to the steepness of the triangularity :param n_points: Number of points :rtype: Plasma flux surface shape .. rubric:: Notes As far as I can tell, the reference parameterisation is either flawed in two places or is insufficiently specified to reproduce properly. I've included two workarounds here, which actually result in a very decent shape description. Furthermore, the grad_rho term does not appear to behave as described, given that it is just an offset. The key may lie in understand what "relative to the X-point" means but it's not enough for me to go on at the moment. .. py:class:: KuiroukidisLCFS(var_dict: bluemira.utilities.opt_variables.VarDictT | None = None) Bases: :py:obj:`bluemira.geometry.parameterisations.GeometryParameterisation`\ [\ :py:obj:`KuiroukidisLCFSOptVariables`\ ] .. autoapi-inheritance-diagram:: bluemira.equilibria.shapes.KuiroukidisLCFS :parts: 1 :private-bases: Kuiroukidis last closed flux surface geometry parameterisation (adjusted). .. py:attribute:: __slots__ :value: () .. py:method:: create_shape(label: str = 'LCFS', n_points: int = 1000) -> bluemira.geometry.wire.BluemiraWire Make a CAD representation of the Kuiroukidis LCFS. :param label: Label to give the wire :param n_points: Number of points to use when creating the Bspline representation :rtype: CAD Wire of the geometry .. py:function:: flux_surface_johner(r_0: float, z_0: float, a: float, kappa_u: float, kappa_l: float, delta_u: float, delta_l: float, psi_u_neg: float, psi_u_pos: float, psi_l_neg: float, psi_l_pos: float, n: int = 100) -> bluemira.geometry.coordinates.Coordinates Initial plasma shape parameterisation from HELIOS author J. Johner (CEA). Sets initial separatrix shape for the plasma core (does not handle divertor target points or legs). Can handle: - DN (positive, negative delta) [TESTED] - SN (positive, negative delta) (upper, lower) [TESTED] :param r_0: Major radius [m] :param z_0: Vertical position of major radius [m] :param a: Minor radius [m] :param kappa_u: Upper elongation at the plasma edge (psi_n=1) :param kappa_l: Lower elongation at the plasma edge (psi_n=1) :param delta_u: Upper triangularity at the plasma edge (psi_n=1) :param delta_l: Lower triangularity at the plasma edge (psi_n=1) :param psi_u_neg: Upper inner angle [°] :param psi_u_pos: Upper outer angle [°] :param psi_l_neg: Lower inner angle [°] :param psi_l_pos: Lower outer angle [°] :param n: Number of point to generate on the flux surface :rtype: Plasma flux surface shape .. py:class:: JohnerLCFS(var_dict: bluemira.utilities.opt_variables.VarDictT | None = None) Bases: :py:obj:`bluemira.geometry.parameterisations.GeometryParameterisation`\ [\ :py:obj:`JohnerLCFSOptVariables`\ ] .. autoapi-inheritance-diagram:: bluemira.equilibria.shapes.JohnerLCFS :parts: 1 :private-bases: Johner last closed flux surface geometry parameterisation. .. py:attribute:: __slots__ :value: () .. py:method:: create_shape(label: str = 'LCFS', n_points: int = 1000) -> bluemira.geometry.wire.BluemiraWire Make a CAD representation of the Johner LCFS. :param label: Label to give the wire :param n_points: Number of points to use when creating the Bspline representation :rtype: CAD Wire of the geometry