33 lines
787 B
Plaintext
33 lines
787 B
Plaintext
---
|
||
title: random_h1_body
|
||
description: API reference for qiskit.aqua.utils.random_h1_body
|
||
in_page_toc_min_heading_level: 1
|
||
python_api_type: function
|
||
python_api_name: qiskit.aqua.utils.random_h1_body
|
||
---
|
||
|
||
<span id="qiskit-aqua-utils-random-h1-body" />
|
||
|
||
# qiskit.aqua.utils.random\_h1\_body
|
||
|
||
<Function id="qiskit.aqua.utils.random_h1_body" isDedicatedPage={true} github="https://github.com/qiskit-community/qiskit-aqua/tree/stable/0.8/qiskit/aqua/utils/random_matrix_generator.py" signature="random_h1_body(N)">
|
||
Generate a random one body integrals.
|
||
|
||
**Parameters**
|
||
|
||
**N** (*int*) – the number of spin orbitals.
|
||
|
||
**Returns**
|
||
|
||
a 2-D matrix with complex data type.
|
||
|
||
**Return type**
|
||
|
||
np.ndarray
|
||
|
||
**Raises**
|
||
|
||
**ValueError** – invalid number of spin orbitals
|
||
</Function>
|
||
|