Skip to content

Latest commit

 

History

History
41 lines (31 loc) · 979 Bytes

Linearweightsemployees.md

File metadata and controls

41 lines (31 loc) · 979 Bytes

D-Wave Systems Quantum Computing Project

Workforce Optimization with DQM

Table of Contents

  1. Objective
  2. DQM Implementation

Objective

Optimizing workforce distribution using Discrete Quadratic Models (DQM) on D-Wave Systems.

DQM Implementation

Initialize DQM Object
from dimod import DiscreteQuadraticModel
dqm = DiscreteQuadraticModel()
Add Variables for Employees
for name in employees:
    dqm.add_variable(num_shifts, label=name)
Set Employee Preferences
dqm.set_linear("Anna", [1,2,3,4])
dqm.set_linear("Bill", [3,2,1,4])
dqm.set_linear("Chris", [4,2,3,1])
dqm.set_linear("Diane", [4,1,2,3])
Run
python main.py