Factory function to initialize a gate from configuration string.
Creates and returns a pointer to the appropriate Gate subclass based on the target specification string.
- Parameters
-
| target_gate | target_gate Type of gate to initialize. |
| file | Path to the file containing gate matrix data (if applicable). |
| nlevels | Number of levels per oscillator. |
| nessential | Number of essential levels per oscillator. |
| total_time | Total time for gate operation. |
| decoherence_type | Type of Lindblad operators for open system dynamics. |
| gate_rot_freq | Frequencies of gate rotation. |
| quietmode | Flag to suppress output messages. |
- Returns
- Gate* Pointer to the initialized gate object.