qbraid.programs.annealing.Problem
- class Problem(problem_type, linear=<factory>, quadratic=<factory>)[source]
Represents an annealing problem, including linear and quadratic terms.
- problem_type
An instance of ProblemType indicating whether the model is QUBO or ISING.
- linear
A dictionary representing the linear coefficients.
- quadratic
A dictionary representing the quadratic coefficients.
- __init__(problem_type, linear=<factory>, quadratic=<factory>)
Methods
__init__
(problem_type[, linear, quadratic])num_variables
()Return the number of variables in the problem.
Attributes