title: Pyomo Cannot index a component with an indexed set
body: <p>I have a Pyomo model that has a sparse set of values but I get the error <code>Cannot index a component with an indexed set</code> when I try to index a binary variable according to this sparse set. For a simplified example:</p>
  
  <pre><code>model = ConcreteModel()
  
  model.S = Set([1, 4, 6])
  model.V = Var(model.S, within=Binary)
  </code></pre>