eclipse / xacc

XACC - eXtreme-scale Accelerator programming framework
https://xacc.readthedocs.io
BSD 3-Clause "New" or "Revised" License
165 stars 85 forks source link

Controlled Ry (cry) from xacc/quantum/plugins/staq/compiler/staq_compiler.cpp has a bug #491

Closed simon-ty closed 2 years ago

simon-ty commented 2 years ago

From line 64 of xacc/quantum/plugins/staq/compiler/staq_compiler.cpp:

{"cry", R"#(

gate cry(lambda) a,b

{

  u3(lambda/2,0,0) b;

  cx a,b;

  u3(-lambda/2,0,0) b;

  cx a,b;

  ry(lambda) a;

}
)#"},

There seems to be an extra ry(lambda) a; which is being applied to the control qubit?