quantum_costs Struct Reference

Calculates the quantum costs. More...

List of all members.

Public Member Functions

 quantum_costs ()
 Standard constructor.
unsigned operator() (const gate &g, unsigned lines) const
 Returns the quantum costs for gate g.

Public Attributes

int controls_offset
 Offset for control lines.

Detailed Description

Calculates the quantum costs.

This costs class calculates the quantum costs. Thereby known optimizations for gates with few control lines or for gates with empty lines are considered.

See also:
Cost Functions
Author:
RevKit
Since:
1.0

Constructor & Destructor Documentation

quantum_costs (  ) 

Standard constructor.

Initializes default values

Author:
RevKit
Since:
1.1

Member Function Documentation

unsigned operator() ( const gate g,
unsigned  lines 
) const

Returns the quantum costs for gate g.

Parameters:
g Gate
lines Number of lines in the circuit
Returns:
Quantum Costs for gate g
Author:
RevKit
Since:
1.0

Member Data Documentation

Offset for control lines.

With this parameter the number of controls can be modified without changing the gate. This enables hypothetical costs calculations.

Note, that the offset is adjusted if it leads to impossible gates such as negative number of control lines or too many control lines for the existing gates.

The default value is 0

Author:
RevKit
Since:
1.1

The documentation for this struct was generated from the following file:

Generated on Tue Dec 21 2010 21:52:13 for RevKit by doxygen 1.7.1