bluemira.plasma_physics.scaling_laws ==================================== .. py:module:: bluemira.plasma_physics.scaling_laws .. autoapi-nested-parse:: A collection of common 0-D plasma physics scaling laws. Classes ------- .. autoapisummary:: bluemira.plasma_physics.scaling_laws.PowerLawScaling Functions --------- .. autoapisummary:: bluemira.plasma_physics.scaling_laws.lambda_q bluemira.plasma_physics.scaling_laws.P_LH bluemira.plasma_physics.scaling_laws.IPB98y2 Module Contents --------------- .. py:class:: PowerLawScaling(constant: float, constant_err: float, exponents: collections.abc.Iterable[float], exp_errs: numpy.ndarray | list | None = None) Simple power law scaling object, of the form: :math:`c~\pm~cerr \times {a_{1}}^{n1\pm err1}{a_{2}}^{n2\pm err2}...` :param constant: The constant of the equation :type constant: float :param constant_err: The error on the constant :type constant_err: float :param exponents: The ordered list of exponents :type exponents: Iterable :param exp_errs: The ordered list of errors of the exponents :type exp_errs: Union[np.ndarray, List, None] .. py:attribute:: c .. py:attribute:: constant_err .. py:attribute:: exponents .. py:method:: __call__(*args) Call the PowerLawScaling object for a set of arguments. :returns: power law scaling :raises ValueError: Number of arguments not equal to number of exponents .. py:method:: calculate(*args, constant=None, exponents=None) Call the PowerLawScaling object for a set of arguments. :returns: power law scaling .. py:method:: calculate_range(*args) -> tuple[float, float] Calculate the range of the PowerLawScaling within the specified errors for a set of arguments :returns: * *min_value* -- Minimum value of the power law according to the specified errors * *max_value* -- Maximum value of the power law according to the specified errors :raises ValueError: No constant error or error ranges .. py:method:: __len__() -> int Get the length of the PowerLawScaling object. :returns: length of PowerLawScaling object .. py:function:: lambda_q(B_t: float, q_cyl: float, p_sol: float, R_0: float, *, error: bool = False) -> float | tuple[float, float, float] Scrape-off layer power width scaling (Eich et al., 2011) [4] :param B_t: Toroidal field [T] :param q_cyl: Cylindrical safety factor :param p_sol: Power in the scrape-off layer [W] :param R_0: Major radius [m] :param error: Whether or not to report the value with +/- errors :returns: * *value* -- Scrape-off layer width at the outboard midplane [m] * *min_value* -- (if error) Minimum value of the power law according to the specified errors * *max_value* -- (if error) Maximum value of the power law according to the specified errors .. rubric:: Notes [4] :doi:`Eich et al., 2011 <10.1103/PhysRevLett.107.215001>` :math:`\lambda_q=(0.73\pm0.38)B_t^{-0.78\pm0.25}q_{95}^{1.2\pm0.27}P_{SOL}^{0.1\pm0.11}R_{0}^{0.02\pm0.2}` .. py:function:: P_LH(n_e: float, B_t: float, A: float, R_0: float, *, error: bool = False) -> float | tuple[float, float, float] Power requirement for accessing H-mode, Martin scaling [3] :param n_e: Electron density [1/m^3] :param B_t: Toroidal field at the major radius [T] :param A: Plasma aspect ratio :param R_0: Plasma major radius [m] :param error: Whether or not to return error bar values :returns: * *value* -- Power required to access H-mode [W] * *min_value* -- (if error) Minimum value of the power law according to the specified errors * *max_value* -- (if error) Maximum value of the power law according to the specified errors .. rubric:: Notes [3] Martin et al., 2008, :doi:`10.1088/1742-6596/123/1/012033` equation (3) :math:`P_{LH}=2.15e^{\pm 0.107}n_{e20}^{0.782 \pm 0.037}` :math:`B_{T}^{0.772 \pm 0.031}a^{0.975 \pm 0.08}R_{0}^{0.999 \pm 0.101}` .. py:function:: IPB98y2(I_p: float, B_t: float, p_sep: float, n: float, mass: float, R_0: float, A: float, kappa: float) -> float ITER IPB98(y, 2) Confinement time scaling for ELMy H-mode [2] :param I_p: Plasma current [A] :param B_t: Toroidal field at R_0 [T] :param p_sep: Separatrix power [W] (a.k.a. loss power (corrected for charge exchange and orbit losses)) :param n: Line average plasma density [1/m^3] :param mass: Average ion mass [a.m.u.] :param R_0: Major radius [m] :param A: Aspect ratio :param kappa: Plasma elongation :returns: Energy confinement time [s] .. rubric:: Notes [2] :doi:`ITER Physics Expert Group, Nucl. Fus. 39, 12 <10.1088/0029-5515/39/12/302>` :math:`\tau_{E}=0.0562I_p^{0.93}B_t^{0.15}P_{sep}^{-0.69}n^{0.41}M^{0.19}R_0^{1.97}A^{-0.58}\kappa^{0.78}`