Questions tagged [qutip]

For questions about code which makes some use of QuTiP (Quantum Toolbox in Python). It is an open-source software library for simulating the dynamics of closed and open quantum systems. Please don't use the programming tag unless you absolutely think it is related to your question. Basically, questions which involve calculating physical quantities, by doing numerical computations on a computer are suited for this tag.

For more about QuTiP best place is Ref.
"The QuTiP library depends on the excellent Numpy, Scipy, and Cython numerical packages. It produces plots using the backends provided by matplotlib. QuTiP aims to provide user-friendly and efficient numerical simulations of a wide variety of quantum mechanical problems, including those with Hamiltonians and/or collapse operators with arbitrary time-dependence, commonly found in a wide range of physics applications. QuTiP is freely available for use and/or modification, and it can be used on all Unix-based platforms and on Windows. Being free of any licensing fees, QuTiP is ideal for exploring quantum mechanics in research as well as in the classroom." This tag is not related to writing programs (or any related software like qiskit) which can be run on a quantum computer. In fact these programs would most probably be written in python.

82 questions
6
votes
1 answer

Drawing tangent vectors to the Bloch sphere with qutip

I need to plot drawings of qubit dynamics on the Bloch sphere. I know QuTip allows to do such drawings but I specifically need to represent evolution velocities on the Bloch sphere so I need to draw tangent vectors. Is there a way I can do it with…
MrRobot
  • 263
  • 2
  • 7
6
votes
4 answers

Measuring qubits in QuTiP

How can you measure qubits in QuTiP? As far as I have seen you can define a Hamiltonian and let it evolve in time. It is also possible to define a quantum circuit, however, measuring and running it is not possible. Does anyone know how to do this?…
nippon
  • 1,609
  • 9
  • 23
5
votes
1 answer

Python shorthand for tensor product (Kronecker product)

When using numpy or tensorflow in Python, we can simply write C = A @ B for matrix multiplication C = np.matmul(A,B). I wonder if there is a shorthand for tensor product (Kronecker product), $C=A\otimes B$ . Now I can only do this by using…
Neo
  • 171
  • 5
4
votes
1 answer

Plotting Bloch sphere in QuTiP

Is there anyone who reproduced the Bloch sphere given in the paper QuTiP: An open-source Python framework for the dynamics of open quantum systems by J. R. Johansson, P. D. Nation, Franco Nori? I am trying to reproduce the Figure 10: Bloch sphere…
4
votes
1 answer

How to calculate Quantum Discord for two qubit system using Qutip?

Quantum discord of a bipartite system can be determined as: $${D_A}({\rho _{AB}}) = I({\rho _{AB}}) - {J_A}({\rho _{AB}}),$$ The subscript of $A$ denotes that the measurement has been performed on the subsystem $A$. The mutual information is defined…
Paranoid
  • 141
  • 2
4
votes
0 answers

Computing Majorana "Stars"

I'm trying to implement Majorana's "stellar representation" of a spin-$j$ system as $2j$ points on the $2$-sphere in python. Consulting papers including Extremal quantum states and their Majorana constellations (Bjork et al., 2015), I convert a…
4
votes
1 answer

Trying to simulate Weak Value Amplification using QuTiP

Weak Value Amplification is a procedure in which one consider a bipartite Hamiltonian of the form $H = g A \otimes B$, where $A$ is called system, $B$ is called meter and $g$ is the extremely small parameter we are interested to measure by…
FearlessVirgo
  • 179
  • 1
  • 7
3
votes
0 answers

How to define initial state $\rvert \Psi(0) \rangle \equiv \rvert 1, -1 \rangle \otimes \rvert 0 \rangle_{\text{cav}} $ of a system in QuTiP?

Say, we have a $\require{mhchem}\ce{^87Rb}$ atom having an electric dipole transition on the $D_{1}$ line and we have two hyperfine ground states, one on $F = 1$ and one on $F = 2$ level. So, we take two pair of states $|F=2, m=-2\rangle$ and $…
Mun
  • 31
  • 2
3
votes
0 answers

How to add states on the Bloch sphere from a master equation?

Can you please help me to find an answer to this question: I am using qutip for the study of quantum systems. suppose I have calculated the solution of the master equation using the mcsolve function and let it be output =…
Jack
  • 71
  • 3
3
votes
1 answer

How do I stepwise rotate a qubit on a Bloch sphere using $SO(3)$ and $SU(2)$ group?

Let us first introduce two fundamental functions for coordinate transformations: def to_spherical(state): r0 = np.abs(state[0]) ϕ0 = np.angle(state[0]) r1 = np.abs(state[1]) ϕ1 = np.angle(state[1]) r = np.sqrt(r0 ** 2 + r1 ** 2) …
Eldar Sultanow
  • 298
  • 2
  • 9
3
votes
1 answer

Qutip choi_to_kraus and to_kraus functions are not returning list of Kraus representation

I am trying to find my kraus representation from my process matrix. Suppose that, I have these process matrix: proces_matrix = [[ 1. 0. 0. 0. ] [-0. 0.537 -0.004 -0.005] [ 0.023 0.014 0.635 -0.03 ] [ 0.011 -0.009 0.017 …
quest
  • 704
  • 4
  • 11
2
votes
1 answer

Strange Behaviour of MeSolve, McSolve

I'm using Qutip to plot some basic two level dynamics using hamiltonians with a temporal envelope defined as the sum of two error functions, designed to make it more representative of experimental conditions. I'm using the following code. import…
2
votes
0 answers

Is the analytical solution right?

This question requires the knowledge of GRAPE. More info can be found here and in this short presentation. In the following jupyter notebook is the analytical solution as in this image right? Because on trying (g = pi/ 4* T = 1/8) as in this figure…
Tejas Shetty
  • 399
  • 2
  • 13
2
votes
0 answers

What is the need of convolution here?

This jupyter notebook implements GRAPE for the synthesisizing a CNOT gate. More info can be found here and in this short presentation. In the following jupyter notebook at In[8] 1 the starting guess for the control field is prepared as…
Tejas Shetty
  • 399
  • 2
  • 13
2
votes
0 answers

Modifying GRAPE for open quantum systems

This question requires the knowledge of GRAPE. More info can be found here and in this short presentation. I have tried to modify the grape_unitary() function in grape.py also to accommodate open quantum systems. One can use it to generate time…
Tejas Shetty
  • 399
  • 2
  • 13
1
2 3 4 5 6