Class Vgate

Inheritance Relationships

Base Type

Class Documentation

class Vgate : public blackbird::Operation

Represents the cubic phase gate. For more details, see the Strawberry Fields convention page.

Phase shift parameter \(s\) accessible via:

  • \(s\): Vgate->f1

Public Functions

Vgate(complexvec s, intvec m)

Constructor that throws an error if complex parameters are provided.

Parameters
  • s: vector<complex<double>> parameters
  • m: mode gate acts on
Exceptions
  • invalid_argument: Operation must have real arguments

Vgate(intvec s, intvec m)

Constructor that throws an error if integer parameters are provided.

Parameters
  • s: vector<int> parameters
  • m: mode gate acts on
Exceptions
  • invalid_argument: Operation must have real arguments

Vgate(floatvec s, intvec m)

Constructor to initialize a Vgate acting on mode m

Parameters
  • s: vector<double> of length 1 containing the phase shift
  • m: mode gate acts on