Half 结构

定义

表示半精度浮点数。

public value class Half : IComparable<Half>, IEquatable<Half>, IParsable<Half>, ISpanParsable<Half>, IUtf8SpanParsable<Half>, System::Numerics::IAdditionOperators<Half, Half, Half>, System::Numerics::IAdditiveIdentity<Half, Half>, System::Numerics::IBinaryFloatingPointIeee754<Half>, System::Numerics::IBinaryNumber<Half>, System::Numerics::IBitwiseOperators<Half, Half, Half>, System::Numerics::IComparisonOperators<Half, Half, bool>, System::Numerics::IDecrementOperators<Half>, System::Numerics::IDivisionOperators<Half, Half, Half>, System::Numerics::IEqualityOperators<Half, Half, bool>, System::Numerics::IExponentialFunctions<Half>, System::Numerics::IFloatingPoint<Half>, System::Numerics::IFloatingPointConstants<Half>, System::Numerics::IFloatingPointIeee754<Half>, System::Numerics::IHyperbolicFunctions<Half>, System::Numerics::IIncrementOperators<Half>, System::Numerics::ILogarithmicFunctions<Half>, System::Numerics::IMinMaxValue<Half>, System::Numerics::IModulusOperators<Half, Half, Half>, System::Numerics::IMultiplicativeIdentity<Half, Half>, System::Numerics::IMultiplyOperators<Half, Half, Half>, System::Numerics::INumber<Half>, System::Numerics::INumberBase<Half>, System::Numerics::IPowerFunctions<Half>, System::Numerics::IRootFunctions<Half>, System::Numerics::ISignedNumber<Half>, System::Numerics::ISubtractionOperators<Half, Half, Half>, System::Numerics::ITrigonometricFunctions<Half>, System::Numerics::IUnaryNegationOperators<Half, Half>, System::Numerics::IUnaryPlusOperators<Half, Half>
public value class Half : IComparable, IComparable<Half>, IEquatable<Half>, IFormattable
public value class Half : IComparable, IComparable<Half>, IEquatable<Half>, ISpanFormattable
public value class Half : IComparable<Half>, IEquatable<Half>, IParsable<Half>, ISpanParsable<Half>, System::Numerics::IAdditionOperators<Half, Half, Half>, System::Numerics::IAdditiveIdentity<Half, Half>, System::Numerics::IBinaryFloatingPointIeee754<Half>, System::Numerics::IBinaryNumber<Half>, System::Numerics::IBitwiseOperators<Half, Half, Half>, System::Numerics::IComparisonOperators<Half, Half, bool>, System::Numerics::IDecrementOperators<Half>, System::Numerics::IDivisionOperators<Half, Half, Half>, System::Numerics::IEqualityOperators<Half, Half, bool>, System::Numerics::IExponentialFunctions<Half>, System::Numerics::IFloatingPoint<Half>, System::Numerics::IFloatingPointConstants<Half>, System::Numerics::IFloatingPointIeee754<Half>, System::Numerics::IHyperbolicFunctions<Half>, System::Numerics::IIncrementOperators<Half>, System::Numerics::ILogarithmicFunctions<Half>, System::Numerics::IMinMaxValue<Half>, System::Numerics::IModulusOperators<Half, Half, Half>, System::Numerics::IMultiplicativeIdentity<Half, Half>, System::Numerics::IMultiplyOperators<Half, Half, Half>, System::Numerics::INumber<Half>, System::Numerics::INumberBase<Half>, System::Numerics::IPowerFunctions<Half>, System::Numerics::IRootFunctions<Half>, System::Numerics::ISignedNumber<Half>, System::Numerics::ISubtractionOperators<Half, Half, Half>, System::Numerics::ITrigonometricFunctions<Half>, System::Numerics::IUnaryNegationOperators<Half, Half>, System::Numerics::IUnaryPlusOperators<Half, Half>
public readonly struct Half : IComparable<Half>, IEquatable<Half>, IParsable<Half>, ISpanParsable<Half>, IUtf8SpanParsable<Half>, System.Numerics.IAdditionOperators<Half,Half,Half>, System.Numerics.IAdditiveIdentity<Half,Half>, System.Numerics.IBinaryFloatingPointIeee754<Half>, System.Numerics.IBinaryNumber<Half>, System.Numerics.IBitwiseOperators<Half,Half,Half>, System.Numerics.IComparisonOperators<Half,Half,bool>, System.Numerics.IDecrementOperators<Half>, System.Numerics.IDivisionOperators<Half,Half,Half>, System.Numerics.IEqualityOperators<Half,Half,bool>, System.Numerics.IExponentialFunctions<Half>, System.Numerics.IFloatingPoint<Half>, System.Numerics.IFloatingPointConstants<Half>, System.Numerics.IFloatingPointIeee754<Half>, System.Numerics.IHyperbolicFunctions<Half>, System.Numerics.IIncrementOperators<Half>, System.Numerics.ILogarithmicFunctions<Half>, System.Numerics.IMinMaxValue<Half>, System.Numerics.IModulusOperators<Half,Half,Half>, System.Numerics.IMultiplicativeIdentity<Half,Half>, System.Numerics.IMultiplyOperators<Half,Half,Half>, System.Numerics.INumber<Half>, System.Numerics.INumberBase<Half>, System.Numerics.IPowerFunctions<Half>, System.Numerics.IRootFunctions<Half>, System.Numerics.ISignedNumber<Half>, System.Numerics.ISubtractionOperators<Half,Half,Half>, System.Numerics.ITrigonometricFunctions<Half>, System.Numerics.IUnaryNegationOperators<Half,Half>, System.Numerics.IUnaryPlusOperators<Half,Half>
public readonly struct Half : IComparable, IComparable<Half>, IEquatable<Half>, IFormattable
public readonly struct Half : IComparable, IComparable<Half>, IEquatable<Half>, ISpanFormattable
public readonly struct Half : IComparable<Half>, IEquatable<Half>, IParsable<Half>, ISpanParsable<Half>, System.Numerics.IAdditionOperators<Half,Half,Half>, System.Numerics.IAdditiveIdentity<Half,Half>, System.Numerics.IBinaryFloatingPointIeee754<Half>, System.Numerics.IBinaryNumber<Half>, System.Numerics.IBitwiseOperators<Half,Half,Half>, System.Numerics.IComparisonOperators<Half,Half,bool>, System.Numerics.IDecrementOperators<Half>, System.Numerics.IDivisionOperators<Half,Half,Half>, System.Numerics.IEqualityOperators<Half,Half,bool>, System.Numerics.IExponentialFunctions<Half>, System.Numerics.IFloatingPoint<Half>, System.Numerics.IFloatingPointConstants<Half>, System.Numerics.IFloatingPointIeee754<Half>, System.Numerics.IHyperbolicFunctions<Half>, System.Numerics.IIncrementOperators<Half>, System.Numerics.ILogarithmicFunctions<Half>, System.Numerics.IMinMaxValue<Half>, System.Numerics.IModulusOperators<Half,Half,Half>, System.Numerics.IMultiplicativeIdentity<Half,Half>, System.Numerics.IMultiplyOperators<Half,Half,Half>, System.Numerics.INumber<Half>, System.Numerics.INumberBase<Half>, System.Numerics.IPowerFunctions<Half>, System.Numerics.IRootFunctions<Half>, System.Numerics.ISignedNumber<Half>, System.Numerics.ISubtractionOperators<Half,Half,Half>, System.Numerics.ITrigonometricFunctions<Half>, System.Numerics.IUnaryNegationOperators<Half,Half>, System.Numerics.IUnaryPlusOperators<Half,Half>
type Half = struct
    interface IFormattable
    interface IParsable<Half>
    interface ISpanFormattable
    interface ISpanParsable<Half>
    interface IUtf8SpanFormattable
    interface IUtf8SpanParsable<Half>
    interface IAdditionOperators<Half, Half, Half>
    interface IAdditiveIdentity<Half, Half>
    interface IBinaryFloatingPointIeee754<Half>
    interface IBinaryNumber<Half>
    interface IBitwiseOperators<Half, Half, Half>
    interface IComparisonOperators<Half, Half, bool>
    interface IEqualityOperators<Half, Half, bool>
    interface IDecrementOperators<Half>
    interface IDivisionOperators<Half, Half, Half>
    interface IIncrementOperators<Half>
    interface IModulusOperators<Half, Half, Half>
    interface IMultiplicativeIdentity<Half, Half>
    interface IMultiplyOperators<Half, Half, Half>
    interface INumber<Half>
    interface INumberBase<Half>
    interface ISubtractionOperators<Half, Half, Half>
    interface IUnaryNegationOperators<Half, Half>
    interface IUnaryPlusOperators<Half, Half>
    interface IExponentialFunctions<Half>
    interface IFloatingPointConstants<Half>
    interface IFloatingPoint<Half>
    interface ISignedNumber<Half>
    interface IFloatingPointIeee754<Half>
    interface IHyperbolicFunctions<Half>
    interface ILogarithmicFunctions<Half>
    interface IPowerFunctions<Half>
    interface IRootFunctions<Half>
    interface ITrigonometricFunctions<Half>
    interface IMinMaxValue<Half>
type Half = struct
    interface IFormattable
type Half = struct
    interface ISpanFormattable
    interface IFormattable
type Half = struct
    interface IFormattable
    interface IParsable<Half>
    interface ISpanFormattable
    interface ISpanParsable<Half>
    interface IAdditionOperators<Half, Half, Half>
    interface IAdditiveIdentity<Half, Half>
    interface IBinaryFloatingPointIeee754<Half>
    interface IBinaryNumber<Half>
    interface IBitwiseOperators<Half, Half, Half>
    interface IComparisonOperators<Half, Half, bool>
    interface IEqualityOperators<Half, Half, bool>
    interface IDecrementOperators<Half>
    interface IDivisionOperators<Half, Half, Half>
    interface IIncrementOperators<Half>
    interface IModulusOperators<Half, Half, Half>
    interface IMultiplicativeIdentity<Half, Half>
    interface IMultiplyOperators<Half, Half, Half>
    interface INumber<Half>
    interface INumberBase<Half>
    interface ISubtractionOperators<Half, Half, Half>
    interface IUnaryNegationOperators<Half, Half>
    interface IUnaryPlusOperators<Half, Half>
    interface IExponentialFunctions<Half>
    interface IFloatingPointConstants<Half>
    interface IFloatingPoint<Half>
    interface ISignedNumber<Half>
    interface IFloatingPointIeee754<Half>
    interface IHyperbolicFunctions<Half>
    interface ILogarithmicFunctions<Half>
    interface IPowerFunctions<Half>
    interface IRootFunctions<Half>
    interface ITrigonometricFunctions<Half>
    interface IMinMaxValue<Half>
type Half = struct
    interface IFormattable
    interface IParsable<Half>
    interface ISpanFormattable
    interface ISpanParsable<Half>
    interface IAdditionOperators<Half, Half, Half>
    interface IAdditiveIdentity<Half, Half>
    interface IBinaryFloatingPointIeee754<Half>
    interface IBinaryNumber<Half>
    interface IBitwiseOperators<Half, Half, Half>
    interface IComparisonOperators<Half, Half, bool>
    interface IEqualityOperators<Half, Half, bool>
    interface IDecrementOperators<Half>
    interface IDivisionOperators<Half, Half, Half>
    interface IIncrementOperators<Half>
    interface IModulusOperators<Half, Half, Half>
    interface IMultiplicativeIdentity<Half, Half>
    interface IMultiplyOperators<Half, Half, Half>
    interface INumber<Half>
    interface INumberBase<Half>
    interface ISubtractionOperators<Half, Half, Half>
    interface IUnaryNegationOperators<Half, Half>
    interface IUnaryPlusOperators<Half, Half>
    interface IUtf8SpanFormattable
    interface IUtf8SpanParsable<Half>
    interface IExponentialFunctions<Half>
    interface IFloatingPointConstants<Half>
    interface IFloatingPoint<Half>
    interface ISignedNumber<Half>
    interface IFloatingPointIeee754<Half>
    interface IHyperbolicFunctions<Half>
    interface ILogarithmicFunctions<Half>
    interface IPowerFunctions<Half>
    interface IRootFunctions<Half>
    interface ITrigonometricFunctions<Half>
    interface IMinMaxValue<Half>
Public Structure Half
Implements IAdditionOperators(Of Half, Half, Half), IAdditiveIdentity(Of Half, Half), IBinaryFloatingPointIeee754(Of Half), IBinaryNumber(Of Half), IBitwiseOperators(Of Half, Half, Half), IComparable(Of Half), IComparisonOperators(Of Half, Half, Boolean), IDecrementOperators(Of Half), IDivisionOperators(Of Half, Half, Half), IEqualityOperators(Of Half, Half, Boolean), IEquatable(Of Half), IExponentialFunctions(Of Half), IFloatingPoint(Of Half), IFloatingPointConstants(Of Half), IFloatingPointIeee754(Of Half), IHyperbolicFunctions(Of Half), IIncrementOperators(Of Half), ILogarithmicFunctions(Of Half), IMinMaxValue(Of Half), IModulusOperators(Of Half, Half, Half), IMultiplicativeIdentity(Of Half, Half), IMultiplyOperators(Of Half, Half, Half), INumber(Of Half), INumberBase(Of Half), IParsable(Of Half), IPowerFunctions(Of Half), IRootFunctions(Of Half), ISignedNumber(Of Half), ISpanParsable(Of Half), ISubtractionOperators(Of Half, Half, Half), ITrigonometricFunctions(Of Half), IUnaryNegationOperators(Of Half, Half), IUnaryPlusOperators(Of Half, Half), IUtf8SpanParsable(Of Half)
Public Structure Half
Implements IComparable, IComparable(Of Half), IEquatable(Of Half), IFormattable
Public Structure Half
Implements IComparable, IComparable(Of Half), IEquatable(Of Half), ISpanFormattable
Public Structure Half
Implements IAdditionOperators(Of Half, Half, Half), IAdditiveIdentity(Of Half, Half), IBinaryFloatingPointIeee754(Of Half), IBinaryNumber(Of Half), IBitwiseOperators(Of Half, Half, Half), IComparable(Of Half), IComparisonOperators(Of Half, Half, Boolean), IDecrementOperators(Of Half), IDivisionOperators(Of Half, Half, Half), IEqualityOperators(Of Half, Half, Boolean), IEquatable(Of Half), IExponentialFunctions(Of Half), IFloatingPoint(Of Half), IFloatingPointConstants(Of Half), IFloatingPointIeee754(Of Half), IHyperbolicFunctions(Of Half), IIncrementOperators(Of Half), ILogarithmicFunctions(Of Half), IMinMaxValue(Of Half), IModulusOperators(Of Half, Half, Half), IMultiplicativeIdentity(Of Half, Half), IMultiplyOperators(Of Half, Half, Half), INumber(Of Half), INumberBase(Of Half), IParsable(Of Half), IPowerFunctions(Of Half), IRootFunctions(Of Half), ISignedNumber(Of Half), ISpanParsable(Of Half), ISubtractionOperators(Of Half, Half, Half), ITrigonometricFunctions(Of Half), IUnaryNegationOperators(Of Half, Half), IUnaryPlusOperators(Of Half, Half)
继承
实现
IComparable IComparable<Half> IComparable<TSelf> IEquatable<Half> IEquatable<TSelf> IFormattable IParsable<Half> IParsable<TSelf> ISpanFormattable ISpanParsable<Half> ISpanParsable<TSelf> IUtf8SpanFormattable IUtf8SpanParsable<Half> IUtf8SpanParsable<TSelf> IAdditionOperators<Half,Half,Half> IAdditionOperators<TSelf,TSelf,TSelf> IAdditiveIdentity<Half,Half> IAdditiveIdentity<TSelf,TSelf> IBinaryFloatingPointIeee754<Half> IBinaryNumber<Half> IBinaryNumber<TSelf> IBitwiseOperators<Half,Half,Half> IBitwiseOperators<TSelf,TSelf,TSelf> IComparisonOperators<Half,Half,Boolean> IComparisonOperators<TSelf,TSelf,Boolean> IDecrementOperators<Half> IDecrementOperators<TSelf> IDivisionOperators<Half,Half,Half> IDivisionOperators<TSelf,TSelf,TSelf> IEqualityOperators<Half,Half,Boolean> IEqualityOperators<TSelf,TOther,TResult> IEqualityOperators<TSelf,TSelf,Boolean> IExponentialFunctions<Half> IExponentialFunctions<TSelf> IFloatingPoint<Half> IFloatingPoint<TSelf> IFloatingPointConstants<Half> IFloatingPointConstants<TSelf> IFloatingPointIeee754<Half> IFloatingPointIeee754<TSelf> IHyperbolicFunctions<Half> IHyperbolicFunctions<TSelf> IIncrementOperators<Half> IIncrementOperators<TSelf> ILogarithmicFunctions<Half> ILogarithmicFunctions<TSelf> IMinMaxValue<Half> IModulusOperators<Half,Half,Half> IModulusOperators<TSelf,TSelf,TSelf> IMultiplicativeIdentity<Half,Half> IMultiplicativeIdentity<TSelf,TSelf> IMultiplyOperators<Half,Half,Half> IMultiplyOperators<TSelf,TSelf,TSelf> INumber<Half> INumber<TSelf> INumberBase<Half> INumberBase<TSelf> IPowerFunctions<Half> IPowerFunctions<TSelf> IRootFunctions<Half> IRootFunctions<TSelf> ISignedNumber<Half> ISignedNumber<TSelf> ISubtractionOperators<Half,Half,Half> ISubtractionOperators<TSelf,TSelf,TSelf> ITrigonometricFunctions<Half> ITrigonometricFunctions<TSelf> IUnaryNegationOperators<Half,Half> IUnaryNegationOperators<TSelf,TSelf> IUnaryPlusOperators<Half,Half> IUnaryPlusOperators<TSelf,TSelf>

注解

Half类型表示半精度 16 位数字,其值范围为负 65,504 到正 65,504,以及正或负零,PositiveInfinityNegativeInfinity而不是数字(NaN)。

这是符合 IEEE 754 标准的 float16 类型。

属性

名称 说明
E

获取数学常量 e

Epsilon

表示大于零的最小正 Half 值。

MaxValue

表示最大可能值 Half

MinValue

表示可能的最小值 Half

MultiplicativeIdentity

获取当前类型的乘法标识。

NaN

表示数字。

NegativeInfinity

表示负无穷大。

NegativeOne

获取类型的值 -1

NegativeZero

获取一个表示负 zero值的值。

One

获取类型的值 1

Pi

获取数学常量 pi

PositiveInfinity

表示正无穷大。

Tau

获取数学常量 tau

Zero

获取类型的值 0

方法

名称 说明
Abs(Half)

计算值的绝对值。

Acos(Half)

计算值的反余弦值。

Acosh(Half)

计算值的双曲反余弦值。

AcosPi(Half)

计算值的反余弦值,并将结果除以 pi

Asin(Half)

计算值的反正弦值。

Asinh(Half)

计算值的双曲反正弦值。

AsinPi(Half)

计算值的反正弦值,并将结果除以 pi

Atan(Half)

计算值的反正切值。

Atan2(Half, Half)

计算两个值的商的反正切值。

Atan2Pi(Half, Half)

计算两个值的商的反正切值,并将结果除以 pi

Atanh(Half)

计算值的双曲反正切值。

AtanPi(Half)

计算值的反正切值,并将结果除以 pi。

BitDecrement(Half)

将值递减为小于给定值的最小值。

BitIncrement(Half)

将值递增为与给定值进行比较的最小值。

Cbrt(Half)

计算值的多维数据集根。

Ceiling(Half)

计算值的上限。

Clamp(Half, Half, Half)

将值固定到非独占最小值和最大值。

ClampNative(Half, Half, Half)

使用特定于平台的行为NaNNegativeZero,将值固定到非独占的最小值和最大值。

CompareTo(Half)

将此实例与指定的半精度浮点数进行比较,并返回一个整数,该值指示此实例的值是小于、等于还是大于指定的半精度浮点数的值。

CompareTo(Object)

将此实例与指定的对象进行比较,并返回一个整数,该整数指示此实例的值是小于、等于还是大于指定对象的值。

ConvertToInteger<TInteger>(Half)

使用溢出时饱和度将值转换为指定的整数类型

ConvertToIntegerNative<TInteger>(Half)

使用特定于平台的行为在溢出时将值转换为指定的整数类型。

CopySign(Half, Half)

将值的符号复制到另一个值的符号。

Cos(Half)

计算值的余弦值。

Cosh(Half)

计算值的双曲余弦值。

CosPi(Half)

计算已由 pi其乘数的值的余弦值。

CreateChecked<TOther>(TOther)

从值创建当前类型的实例,为超出当前类型的可表示范围的任何值引发溢出异常。

CreateSaturating<TOther>(TOther)

从值创建当前类型的实例,使属于当前类型的可表示范围之外的任何值饱和。

CreateTruncating<TOther>(TOther)

从值创建当前类型的实例,截断属于当前类型的可表示范围之外的任何值。

DegreesToRadians(Half)

将给定值从度转换为弧度。

Equals(Half)

将此实例与 进行比较,以相等 other

Equals(Object)

返回一个值,该值指示此实例是否等于指定的 obj实例。

Exp(Half)

E计算提升到给定功率。

Exp10(Half)

10计算提升到给定功率。

Exp10M1(Half)

10计算提升到给定的幂并减去一个。

Exp2(Half)

2计算提升到给定功率。

Exp2M1(Half)

2计算提升到给定的幂并减去一个。

ExpM1(Half)

E计算提升到给定的幂并减去一个。

Floor(Half)

计算值的下限。

FusedMultiplyAdd(Half, Half, Half)

计算三个值的融合乘法。

GetHashCode()

返回此实例的哈希代码。

Hypot(Half, Half)

计算给定的两个值,该值表示右角三角形中较短边的长度。

Ieee754Remainder(Half, Half)

计算 IEEE 754 指定的两个值的余数。

ILogB(Half)

计算值的整数对数。

IsEvenInteger(Half)

确定值是否表示偶数。

IsFinite(Half)

确定指定的值是有限值(零、非正常值还是正常值)。

IsInfinity(Half)

返回一个值,该值指示指定的数字是否计算为正无穷大。

IsInteger(Half)

确定值是否表示整型值。

IsNaN(Half)

确定指定的值是否不是数字。

IsNegative(Half)

确定指定的值是否为负值。

IsNegativeInfinity(Half)

确定指定的值是否为负无穷大。

IsNormal(Half)

确定指定的值是否正常。

IsOddInteger(Half)

确定值是否表示奇数整数。

IsPositive(Half)

确定值是否为正值。

IsPositiveInfinity(Half)

确定指定的值是否为正无穷大。

IsPow2(Half)

确定值是否为 2 的幂。

IsRealNumber(Half)

确定值是否表示实数。

IsSubnormal(Half)

确定指定的值是否为非正常值。

Lerp(Half, Half, Half)

根据给定权重在两个值之间执行线性内插。

Log(Half, Half)

计算指定基中的值的对数。

Log(Half)

计算值的自然(base-E 对数)。

Log10(Half)

计算值的 base-10 对数。

Log10P1(Half)

计算值加 10 的 base-10 对数。

Log2(Half)

计算值的 log2。

Log2P1(Half)

计算值加 1 的 base-2 对数。

LogP1(Half)

计算值加 1 的自然(base-E) 对数。

Max(Half, Half)

比较两个值与计算值更大。

MaxMagnitude(Half, Half)

比较两个值与计算值更大。

MaxMagnitudeNumber(Half, Half)

将两个值与计算进行比较,如果输入 NaN是,则返回另一个值。

MaxNative(Half, Half)

比较两个值与使用特定于平台的行为 NaNNegativeZero更大的计算值。

MaxNumber(Half, Half)

将两个值与计算进行比较,如果输入 NaN是,则返回另一个值。

Min(Half, Half)

比较两个值与计算值较小。

MinMagnitude(Half, Half)

比较两个值与计算值较小。

MinMagnitudeNumber(Half, Half)

将两个值与计算进行比较,如果输入 NaN是,则返回另一个值。

MinNative(Half, Half)

将两个值与计算进行比较,后者使用特定于平台的行为 NaNNegativeZero

MinNumber(Half, Half)

将两个值与计算进行比较,如果输入 NaN较小,则返回另一个值。

MultiplyAddEstimate(Half, Half, Half)

计算估计值 (left * right) + 。 addend

Parse(ReadOnlySpan<Byte>, IFormatProvider)

将 UTF-8 字符的范围分析为值。

Parse(ReadOnlySpan<Byte>, NumberStyles, IFormatProvider)

将 UTF-8 字符的范围分析为值。

Parse(ReadOnlySpan<Char>, IFormatProvider)

将字符的范围分析为值。

Parse(ReadOnlySpan<Char>, NumberStyles, IFormatProvider)

将指定样式和区域性特定格式的数字的字符串表示形式转换为其等效的单精度浮点数。

Parse(String, IFormatProvider)

将指定区域性特定格式的数字的字符串表示形式转换为其等效的单精度浮点数。

Parse(String, NumberStyles, IFormatProvider)

将指定样式和区域性特定格式的数字的字符串表示形式转换为其等效的单精度浮点数。

Parse(String, NumberStyles)

将指定样式中的数字的字符串表示形式转换为其等效的单精度浮点数。

Parse(String)

将数字的字符串表示形式转换为其等效的半精度浮点数。

Pow(Half, Half)

计算提升到给定功率的值。

RadiansToDegrees(Half)

将给定值从弧度转换为度。

ReciprocalEstimate(Half)

计算值的对等值的估计值。

ReciprocalSqrtEstimate(Half)

计算值的倒数平方根的估计值。

RootN(Half, Int32)

计算值的第 n 个根。

Round(Half, Int32, MidpointRounding)

使用默认舍入模式将值舍入为指定数量的小数位数(ToEven)。

Round(Half, Int32)

使用默认舍入模式将值舍入为指定数量的小数位数(ToEven)。

Round(Half, MidpointRounding)

使用指定的舍入模式将值舍入到最接近的整数。

Round(Half)

使用默认舍入模式将值舍入到最接近的整数(ToEven)。

ScaleB(Half, Int32)

计算一个值及其基弧度升至指定功率的乘积。

Sign(Half)

计算值的符号。

Sin(Half)

计算值的正弦值。

SinCos(Half)

计算值的正弦值和余弦值。

SinCosPi(Half)

计算乘 pi以的值的正弦和余弦值。

Sinh(Half)

计算值的双曲正弦值。

SinPi(Half)

计算乘以 pi的值的正弦值。

Sqrt(Half)

计算值的平方根。

Tan(Half)

计算值的正切值。

Tanh(Half)

计算值的双曲正切值。

TanPi(Half)

计算已由 pi其乘数的值的正切值。

ToString()

将此实例的数值转换为其等效的字符串表示形式。

ToString(IFormatProvider)

使用指定的区域性特定格式信息将此实例的数值转换为其等效的字符串表示形式。

ToString(String, IFormatProvider)

使用指定的格式和区域性特定的格式信息将此实例的数值转换为其等效的字符串表示形式。

ToString(String)

使用指定的格式将此实例的数值转换为其等效的字符串表示形式。

Truncate(Half)

截断值。

TryFormat(Span<Byte>, Int32, ReadOnlySpan<Char>, IFormatProvider)

尝试将当前实例的值格式化为 UTF-8,并将其设置为提供的字节范围。

TryFormat(Span<Char>, Int32, ReadOnlySpan<Char>, IFormatProvider)

尝试将当前 Half 实例的值格式化为提供的字符范围。

TryParse(ReadOnlySpan<Byte>, Half)

尝试将包含数字字符串表示形式的 UTF-8 字符范围转换为其等效的半精度浮点数。

TryParse(ReadOnlySpan<Byte>, IFormatProvider, Half)

尝试将 UTF-8 字符的范围分析为值。

TryParse(ReadOnlySpan<Byte>, NumberStyles, IFormatProvider, Half)

尝试将 UTF-8 字符的范围分析为值。

TryParse(ReadOnlySpan<Char>, Half)

将数字的跨度表示形式转换为其等效的半精度浮点数。 返回值指示转换是成功还是失败。

TryParse(ReadOnlySpan<Char>, IFormatProvider, Half)

尝试将字符范围分析为值。

TryParse(ReadOnlySpan<Char>, NumberStyles, IFormatProvider, Half)

将数字的跨度表示形式转换为其等效的半精度浮点数。 返回值指示转换是成功还是失败。

TryParse(String, Half)

将数字的字符串表示形式转换为其等效的半精度浮点数。 返回值指示转换是成功还是失败。

TryParse(String, IFormatProvider, Half)

尝试将字符串分析为值。

TryParse(String, NumberStyles, IFormatProvider, Half)

将数字的字符串表示形式转换为其等效的半精度浮点数。 返回值指示转换是成功还是失败。

运营商

名称 说明
Addition(Half, Half)

将两个值相加以计算其总和。

CheckedExplicit(Half to Byte)

表示半精度浮点数。

Decrement(Half)

递减值。

Division(Half, Half)

将两个值相除以计算其商。

Equality(Half, Half)

返回一个值,该值指示两个指定 Half 值是否相等。

Explicit(Char to Half)

显式将值 Char 转换为最接近可表示的半精度浮点值。

Explicit(Decimal to Half)

显式将值 Decimal 转换为最接近可表示的半精度浮点值。

Explicit(Double to Half)

一个显式运算符,用于将值转换为 Double .Half

Explicit(Half to Byte)

显式将半精度浮点值转换为最接近的可 Byte 表示值。

Explicit(Half to Char)

显式将半精度浮点值转换为最接近的可 Char 表示值。

Explicit(Half to Decimal)

显式将半精度浮点值转换为最接近的可 Decimal 表示值。

Explicit(Half to Double)

一个显式运算符,用于将值转换为 Half .Double

Explicit(Half to Int128)

显式将半精度浮点值转换为最接近的可 Int128表示值。

Explicit(Half to Int16)

显式将半精度浮点值转换为最接近的可 Int16 表示值。

Explicit(Half to Int32)

显式将半精度浮点值转换为最接近的可 Int32 表示值。

Explicit(Half to Int64)

显式将半精度浮点值转换为最接近的可 Int64 表示值。

Explicit(Half to IntPtr)

显式将半精度浮点值转换为最接近的可 IntPtr 表示值。

Explicit(Half to SByte)

显式将半精度浮点值转换为最接近的可 SByte 表示值。

Explicit(Half to Single)

一个显式运算符,用于将值转换为 Half .Single

Explicit(Half to UInt128)

显式将半精度浮点值转换为最接近的可 UInt128表示值。

Explicit(Half to UInt16)

显式将半精度浮点值转换为最接近的可 UInt16 表示值。

Explicit(Half to UInt32)

显式将半精度浮点值转换为最接近的可 UInt32 表示值。

Explicit(Half to UInt64)

显式将半精度浮点值转换为最接近的可 UInt64 表示值。

Explicit(Half to UIntPtr)

显式将半精度浮点值转换为最接近的可 UIntPtr 表示值。

Explicit(Int16 to Half)

显式将值 Int16 转换为最接近可表示的半精度浮点值。

Explicit(Int32 to Half)

显式将值 Int32 转换为最接近可表示的半精度浮点值。

Explicit(Int64 to Half)

显式将值 Int64 转换为最接近可表示的半精度浮点值。

Explicit(IntPtr to Half)

显式将值 IntPtr 转换为最接近可表示的半精度浮点值。

Explicit(Single to Half)

一个显式运算符,用于将值转换为 Single .Half

Explicit(UInt16 to Half)

显式将值 UInt16 转换为最接近可表示的半精度浮点值。

Explicit(UInt32 to Half)

显式将值 UInt32 转换为最接近可表示的半精度浮点值。

Explicit(UInt64 to Half)

显式将值 UInt64 转换为最接近可表示的半精度浮点值。

Explicit(UIntPtr to Half)

显式将值 UIntPtr 转换为最接近可表示的半精度浮点值。

GreaterThan(Half, Half)

返回一个值,该值指示指定的 Half 值是否大于另一个指定 Half 值。

GreaterThanOrEqual(Half, Half)

返回一个值,该值指示是否 left 大于或等于 right

Implicit(Byte to Half)

隐式将值 Byte 转换为最接近的可表示的半精度浮点值。

Implicit(SByte to Half)

隐式将值 SByte 转换为最接近的可表示的半精度浮点值。

Increment(Half)

递增值。

Inequality(Half, Half)

返回一个值,该值指示两个指定的 Half 值是否不相等。

LessThan(Half, Half)

返回一个值,该值指示指定的 Half 值是否小于另一个指定 Half 值。

LessThanOrEqual(Half, Half)

返回一个值,该值指示指定的 Half 值是否小于或等于另一个指定 Half 值。

Modulus(Half, Half)

将两个值相除以计算其模数或余数。

Multiply(Half, Half)

将两个值相乘以计算其产品。

Subtraction(Half, Half)

减去两个值以计算其差异。

UnaryNegation(Half)

计算值的一元求反。

UnaryPlus(Half)

计算一元加值。

显式接口实现

名称 说明
IAdditiveIdentity<Half,Half>.AdditiveIdentity

获取当前类型的累加标识。

IBinaryNumber<Half>.AllBitsSet

获取在其中设置所有位的二进制类型的实例。

IBitwiseOperators<Half,Half,Half>.BitwiseAnd(Half, Half)

计算两个值的按位和两个值。

IBitwiseOperators<Half,Half,Half>.BitwiseOr(Half, Half)

计算两个值的按位或两个值。

IBitwiseOperators<Half,Half,Half>.ExclusiveOr(Half, Half)

计算独占值或两个值。

IBitwiseOperators<Half,Half,Half>.OnesComplement(Half)

计算给定值的补补表示形式。

IFloatingPoint<Half>.GetExponentByteCount()

获取将作为其一部分 TryWriteExponentLittleEndian(Span<Byte>, Int32)写入的字节数。

IFloatingPoint<Half>.GetExponentShortestBitLength()

获取最短两个指数的补数表示形式的长度(以位为单位)。

IFloatingPoint<Half>.GetSignificandBitLength()

获取当前标志的长度(以位为单位)。

IFloatingPoint<Half>.GetSignificandByteCount()

获取将作为其一部分 TryWriteSignificandLittleEndian(Span<Byte>, Int32)写入的字节数。

IFloatingPoint<Half>.TryWriteExponentBigEndian(Span<Byte>, Int32)

尝试将当前指数(采用 big-endian 格式)写入给定范围。

IFloatingPoint<Half>.TryWriteExponentLittleEndian(Span<Byte>, Int32)

尝试将当前指数(以小端格式)写入给定范围。

IFloatingPoint<Half>.TryWriteSignificandBigEndian(Span<Byte>, Int32)

尝试将当前符号(采用 big-endian 格式)写入给定范围。

IFloatingPoint<Half>.TryWriteSignificandLittleEndian(Span<Byte>, Int32)

尝试将当前符号(以小端格式)写入给定范围。

INumberBase<Half>.IsCanonical(Half)

确定某个值是否在其规范表示形式中。

INumberBase<Half>.IsComplexNumber(Half)

确定值是否表示复数。

INumberBase<Half>.IsImaginaryNumber(Half)

确定值是否表示纯虚数。

INumberBase<Half>.IsZero(Half)

确定值是否为零。

INumberBase<Half>.Radix

获取类型的基数。

INumberBase<Half>.TryConvertFromChecked<TOther>(TOther, Half)

表示半精度浮点数。

INumberBase<Half>.TryConvertFromSaturating<TOther>(TOther, Half)

表示半精度浮点数。

INumberBase<Half>.TryConvertFromTruncating<TOther>(TOther, Half)

表示半精度浮点数。

INumberBase<Half>.TryConvertToChecked<TOther>(Half, TOther)

尝试将当前类型的实例转换为另一种类型,为超出当前类型可表示范围的任何值引发溢出异常。

INumberBase<Half>.TryConvertToSaturating<TOther>(Half, TOther)

尝试将当前类型的实例转换为另一种类型,使超出当前类型的可表示范围的任何值饱和。

INumberBase<Half>.TryConvertToTruncating<TOther>(Half, TOther)

尝试将当前类型的实例转换为另一种类型,截断属于当前类型的可表示范围之外的任何值。

适用于

另请参阅