mm.math.new_constant¶
- math.new_constant(name, dtype=None)¶
Returns a new constant with the given value.
- Parameters:
value (
ndarray
[Tuple
[int
,...
],Union
[TypeVar
(R
,float16
,float32
,float64
),TypeVar
(C
,complex64
,complex128
),TypeVar
(Z
,int16
,int32
,int64
),TypeVar
(N
,uint16
,uint32
,uint64
)]]) – The value of the new constantname (str) – name of the new constant
dtype (type) – dtype of the array
- Return type:
ndarray
[Tuple
[int
,...
],Union
[TypeVar
(R
,float16
,float32
,float64
),TypeVar
(C
,complex64
,complex128
),TypeVar
(Z
,int16
,int32
,int64
),TypeVar
(N
,uint16
,uint32
,uint64
)]]- Returns:
The new constant
code/api/mrmustard.math.new_constant
Download Python script
Download Notebook
View on GitHub