quantrs2_tytan/solution_debugger/
analysis.rs1use super::constraint_analyzer::ConstraintViolation;
4use super::energy_analyzer::EnergyBreakdown;
5use serde::Serialize;
6
7#[derive(Debug, Clone, Serialize)]
9pub struct ConstraintAnalysis {
10 pub total_constraints: usize,
12 pub satisfied: usize,
14 pub violated: usize,
16 pub satisfaction_rate: f64,
18 pub penalty_incurred: f64,
20 pub violations: Vec<ConstraintViolation>,
22}
23
24#[derive(Debug, Clone, Serialize)]
26pub struct EnergyAnalysis {
27 pub total_energy: f64,
29 pub breakdown: EnergyBreakdown,
31 pub critical_variables: Vec<(String, f64)>,
33 pub critical_interactions: Vec<((String, String), f64)>,
35 pub improvement_potential: f64,
37}