Tensor.Add Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
Add<T>(ReadOnlyTensorSpan<T>, ReadOnlyTensorSpan<T>) |
Adds each element of |
Add<T>(ReadOnlyTensorSpan<T>, T) |
Adds |
Add<T>(ReadOnlyTensorSpan<T>, ReadOnlyTensorSpan<T>, TensorSpan<T>) |
Adds each element of |
Add<T>(ReadOnlyTensorSpan<T>, T, TensorSpan<T>) |
Adds |
Add<T>(ReadOnlyTensorSpan<T>, ReadOnlyTensorSpan<T>)
- Source:
- TensorExtensions.cs
- Source:
- TensorExtensions.cs
Adds each element of x
to each element of y
and returns a new Tensor<T> with the result.
public:
generic <typename T>
where T : System::Numerics::IAdditionOperators<T, T, T>, System::Numerics::IAdditiveIdentity<T, T> static System::Numerics::Tensors::Tensor<T> ^ Add(System::Numerics::Tensors::ReadOnlyTensorSpan<T> % x, System::Numerics::Tensors::ReadOnlyTensorSpan<T> % y);
public static System.Numerics.Tensors.Tensor<T> Add<T> (in System.Numerics.Tensors.ReadOnlyTensorSpan<T> x, in System.Numerics.Tensors.ReadOnlyTensorSpan<T> y) where T : System.Numerics.IAdditionOperators<T,T,T>, System.Numerics.IAdditiveIdentity<T,T>;
static member Add : ReadOnlyTensorSpan * ReadOnlyTensorSpan -> System.Numerics.Tensors.Tensor<'T (requires 'T :> System.Numerics.IAdditionOperators<'T, 'T, 'T> and 'T :> System.Numerics.IAdditiveIdentity<'T, 'T>)> (requires 'T :> System.Numerics.IAdditionOperators<'T, 'T, 'T> and 'T :> System.Numerics.IAdditiveIdentity<'T, 'T>)
Public Function Add(Of T As {IAdditionOperators(Of T, T, T), IAdditiveIdentity(Of T, T)}) (ByRef x As ReadOnlyTensorSpan(Of T), ByRef y As ReadOnlyTensorSpan(Of T)) As Tensor(Of T)
Type Parameters
- T
Parameters
The ReadOnlyTensorSpan<T> of values to add.
The second ReadOnlyTensorSpan<T> of values to add.
Returns
Applies to
Add<T>(ReadOnlyTensorSpan<T>, T)
- Source:
- TensorExtensions.cs
- Source:
- TensorExtensions.cs
Adds y
to each element of x
and returns a new Tensor<T> with the result.
public:
generic <typename T>
where T : System::Numerics::IAdditionOperators<T, T, T>, System::Numerics::IAdditiveIdentity<T, T> static System::Numerics::Tensors::Tensor<T> ^ Add(System::Numerics::Tensors::ReadOnlyTensorSpan<T> % x, T y);
public static System.Numerics.Tensors.Tensor<T> Add<T> (in System.Numerics.Tensors.ReadOnlyTensorSpan<T> x, T y) where T : System.Numerics.IAdditionOperators<T,T,T>, System.Numerics.IAdditiveIdentity<T,T>;
static member Add : ReadOnlyTensorSpan * 'T -> System.Numerics.Tensors.Tensor<'T (requires 'T :> System.Numerics.IAdditionOperators<'T, 'T, 'T> and 'T :> System.Numerics.IAdditiveIdentity<'T, 'T>)> (requires 'T :> System.Numerics.IAdditionOperators<'T, 'T, 'T> and 'T :> System.Numerics.IAdditiveIdentity<'T, 'T>)
Public Function Add(Of T As {IAdditionOperators(Of T, T, T), IAdditiveIdentity(Of T, T)}) (ByRef x As ReadOnlyTensorSpan(Of T), y As T) As Tensor(Of T)
Type Parameters
- T
Parameters
The ReadOnlyTensorSpan<T> of values to add.
- y
- T
The T
to add to each element of x
.
Returns
Applies to
Add<T>(ReadOnlyTensorSpan<T>, ReadOnlyTensorSpan<T>, TensorSpan<T>)
- Source:
- TensorExtensions.cs
- Source:
- TensorExtensions.cs
Adds each element of x
to each element of y
and returns a new ReadOnlyTensorSpan<T> with the result.
public:
generic <typename T>
where T : System::Numerics::IAdditionOperators<T, T, T>, System::Numerics::IAdditiveIdentity<T, T> static System::Numerics::Tensors::TensorSpan<T> ^ Add(System::Numerics::Tensors::ReadOnlyTensorSpan<T> % x, System::Numerics::Tensors::ReadOnlyTensorSpan<T> % y, System::Numerics::Tensors::TensorSpan<T> % destination);
public static ref readonly System.Numerics.Tensors.TensorSpan<T> Add<T> (scoped in System.Numerics.Tensors.ReadOnlyTensorSpan<T> x, scoped in System.Numerics.Tensors.ReadOnlyTensorSpan<T> y, in System.Numerics.Tensors.TensorSpan<T> destination) where T : System.Numerics.IAdditionOperators<T,T,T>, System.Numerics.IAdditiveIdentity<T,T>;
static member Add : ReadOnlyTensorSpan * ReadOnlyTensorSpan * TensorSpan -> TensorSpan (requires 'T :> System.Numerics.IAdditionOperators<'T, 'T, 'T> and 'T :> System.Numerics.IAdditiveIdentity<'T, 'T>)
Public Function Add(Of T As {IAdditionOperators(Of T, T, T), IAdditiveIdentity(Of T, T)}) (ByRef x As ReadOnlyTensorSpan(Of T), ByRef y As ReadOnlyTensorSpan(Of T), ByRef destination As TensorSpan(Of T)) As TensorSpan(Of T)
Type Parameters
- T
Parameters
The ReadOnlyTensorSpan<T> of values to add.
The second ReadOnlyTensorSpan<T> of values to add.
- destination
- TensorSpan<T>
Returns
Applies to
Add<T>(ReadOnlyTensorSpan<T>, T, TensorSpan<T>)
- Source:
- TensorExtensions.cs
- Source:
- TensorExtensions.cs
Adds y
to each element of x
and returns a new TensorSpan<T> with the result.
public:
generic <typename T>
where T : System::Numerics::IAdditionOperators<T, T, T>, System::Numerics::IAdditiveIdentity<T, T> static System::Numerics::Tensors::TensorSpan<T> ^ Add(System::Numerics::Tensors::ReadOnlyTensorSpan<T> % x, T y, System::Numerics::Tensors::TensorSpan<T> % destination);
public static ref readonly System.Numerics.Tensors.TensorSpan<T> Add<T> (scoped in System.Numerics.Tensors.ReadOnlyTensorSpan<T> x, T y, in System.Numerics.Tensors.TensorSpan<T> destination) where T : System.Numerics.IAdditionOperators<T,T,T>, System.Numerics.IAdditiveIdentity<T,T>;
static member Add : ReadOnlyTensorSpan * 'T * TensorSpan -> TensorSpan (requires 'T :> System.Numerics.IAdditionOperators<'T, 'T, 'T> and 'T :> System.Numerics.IAdditiveIdentity<'T, 'T>)
Public Function Add(Of T As {IAdditionOperators(Of T, T, T), IAdditiveIdentity(Of T, T)}) (ByRef x As ReadOnlyTensorSpan(Of T), y As T, ByRef destination As TensorSpan(Of T)) As TensorSpan(Of T)
Type Parameters
- T
Parameters
The ReadOnlyTensorSpan<T> of values to add.
- y
- T
The T
to add to each element of x
.
- destination
- TensorSpan<T>