# How to construct a Hamiltonian containing Pauli string by qiskit?

There is a Hamiltonian I want to construct by a Python package, which is the following: $$H = 5.9I + 0.21Z_0 - 6.12 Z_1 - 2.14(X_0X_1 + Y_0Y_1) + 9.6(I-Z_2) - 3.9(X_1X_2 + Y_1Y_2)$$ It is very easy for me to create this Hamiltonian by the Python package Projectq. That is:

h = 5.9*QubitOperator('') + 0.21*QubitOperator('Z0') - 6.12*QubitOperator('Z1') - 2.14*(QubitOperator('X0 X1')+QubitOperator('Y0 Y1') )+ 9.6*(QubitOperator('')-QubitOperator('Z2')) - 3.9*(QubitOperator('X1 X2') + QubitOperator('Y1 Y2') )


However, I want to do this by qiskit. Are there any command like QubitOperator() in qiskit?

from qiskit.opflow import X, Y, Z, I

from qiskit.visualization.array import array_to_latex