Borrar filtros
Borrar filtros

Info

La pregunta está cerrada. Vuélvala a abrir para editarla o responderla.

Acting scalar variables on matrices while creating density plots

1 visualización (últimos 30 días)
JJH
JJH el 5 de Ag. de 2017
Cerrada: MATLAB Answer Bot el 20 de Ag. de 2021
Hi, I am trying to make a density plot in Matlab. My problem is that I want to use some Hamiltonian,
H=a*kron(PauliX,PauliZ)+b*kron(PauliZ,PauliY)
and take the unitary evolution
U=expm(-i*H*t)
over some two qubit input state
rhoe=[0.5 0; 0 0.5]
rhon=[0.5 0; 0 0.5]
rhoin=kron(rhoe,rhon)
such that
rhoout=U*rhoin*U'
The variables in my density plot will be a, t and the value given in element 1,1 of rhoout. I want to be able to vary both a and t but I am having the problem that the matrix dimensions are wrong. Ideally, I would do a for loop for a=0:n and t=0:m but I don't know how to get this to work and also save the outputs of each rhoout. I have been trying to use the pcolor function but my problem is in getting a list of rhoout values. Can anyone tell me how I could go about coding this?

Respuestas (0)

La pregunta está cerrada.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by