NumpySeedSequence.Fill Method

Definition

Namespace: Numerics.NET.Random.Seeding
Assembly: Numerics.NET (in Numerics.NET.dll) Version: 10.3.0

Overload List

Fill(Span<UInt32>) Fills a span of 32-bit unsigned integers with entropy values.
Fill(Span<UInt64>) Fills a span of 64-bit unsigned integers with entropy values.
Fill(UInt64[]) Fills an array of 64-bit unsigned integers with entropy values.

Fill(Span<UInt32>)

Fills a span of 32-bit unsigned integers with entropy values.
C#
public override void Fill(
	Span<uint> state
)

Parameters

state  Span<UInt32>
 

Remarks

This method fills the buffer by cycling through the entropy pool and applying position-dependent mixing. The output matches NumPy's generate_state(n, dtype=np.uint32) behavior.

Fill(Span<UInt64>)

Fills a span of 64-bit unsigned integers with entropy values.
C#
public override void Fill(
	Span<ulong> state
)

Parameters

state  Span<UInt64>
 

Remarks

This method generates the required number of 32-bit values, then packs consecutive pairs into 64-bit values in little-endian order. This matches NumPy's generate_state(n, dtype=np.uint64) behavior. On little-endian systems, an optimized path uses direct memory casting for improved performance.

See Also