<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic How to define one binary variable value explicitely among a group of binary variables in Mathematical Optimization, Discrete-Event Simulation, and OR</title>
    <link>https://communities.sas.com/t5/Mathematical-Optimization/How-to-define-one-binary-variable-value-explicitely-among-a/m-p/352507#M1771</link>
    <description>&lt;P&gt;I need to explicitely define binary variable openstatus for WH1&amp;nbsp; as 1 (in the below code)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;how to define that&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;Proc optmodel;
set WH= {"WH1","WH2","WH3","WH4","WH5"};
set WS= {"WS1","WS2","WS3"};
Number FixedCost {WH}=[
10000&amp;nbsp; 20000&amp;nbsp; 15000&amp;nbsp; 17000&amp;nbsp; 13000];
Number TransCost {WH}=[
9&amp;nbsp; 7&amp;nbsp; 8&amp;nbsp; 7.5&amp;nbsp; 8.5];
Number Distance{WH,WS}=[
85&amp;nbsp; 120&amp;nbsp; 90
45&amp;nbsp; 150&amp;nbsp; 85
75&amp;nbsp; 120&amp;nbsp; 95
60&amp;nbsp; 80&amp;nbsp;&amp;nbsp; 90
110 65&amp;nbsp;&amp;nbsp; 95];
var openstatus{WH1}=1;
var openstatus{WH} binary;
minimize operatingCost=
&amp;nbsp;sum{w in WH}(FixedCost[W]+40*TransCost[w]*sum{s in WS}distance[w,s])*openstatus[w];
constraint sum{w in WH}openstatus[w]=2;
solve;
print OperatingCost openstatus;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Sat, 22 Apr 2017 22:27:49 GMT</pubDate>
    <dc:creator>pmoovala0</dc:creator>
    <dc:date>2017-04-22T22:27:49Z</dc:date>
    <item>
      <title>How to define one binary variable value explicitely among a group of binary variables</title>
      <link>https://communities.sas.com/t5/Mathematical-Optimization/How-to-define-one-binary-variable-value-explicitely-among-a/m-p/352507#M1771</link>
      <description>&lt;P&gt;I need to explicitely define binary variable openstatus for WH1&amp;nbsp; as 1 (in the below code)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;how to define that&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;Proc optmodel;
set WH= {"WH1","WH2","WH3","WH4","WH5"};
set WS= {"WS1","WS2","WS3"};
Number FixedCost {WH}=[
10000&amp;nbsp; 20000&amp;nbsp; 15000&amp;nbsp; 17000&amp;nbsp; 13000];
Number TransCost {WH}=[
9&amp;nbsp; 7&amp;nbsp; 8&amp;nbsp; 7.5&amp;nbsp; 8.5];
Number Distance{WH,WS}=[
85&amp;nbsp; 120&amp;nbsp; 90
45&amp;nbsp; 150&amp;nbsp; 85
75&amp;nbsp; 120&amp;nbsp; 95
60&amp;nbsp; 80&amp;nbsp;&amp;nbsp; 90
110 65&amp;nbsp;&amp;nbsp; 95];
var openstatus{WH1}=1;
var openstatus{WH} binary;
minimize operatingCost=
&amp;nbsp;sum{w in WH}(FixedCost[W]+40*TransCost[w]*sum{s in WS}distance[w,s])*openstatus[w];
constraint sum{w in WH}openstatus[w]=2;
solve;
print OperatingCost openstatus;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 22 Apr 2017 22:27:49 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Mathematical-Optimization/How-to-define-one-binary-variable-value-explicitely-among-a/m-p/352507#M1771</guid>
      <dc:creator>pmoovala0</dc:creator>
      <dc:date>2017-04-22T22:27:49Z</dc:date>
    </item>
    <item>
      <title>Re: How to define one binary variable value explicitely among a group of binary variables</title>
      <link>https://communities.sas.com/t5/Mathematical-Optimization/How-to-define-one-binary-variable-value-explicitely-among-a/m-p/352533#M1772</link>
      <description>Use one VAR statement to declare the whole set of variables, and then use the FIX statement to fix one variable's value.&lt;BR /&gt;</description>
      <pubDate>Sun, 23 Apr 2017 01:32:09 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Mathematical-Optimization/How-to-define-one-binary-variable-value-explicitely-among-a/m-p/352533#M1772</guid>
      <dc:creator>RobPratt</dc:creator>
      <dc:date>2017-04-23T01:32:09Z</dc:date>
    </item>
    <item>
      <title>Re: How to define one binary variable value explicitely among a group of binary variables</title>
      <link>https://communities.sas.com/t5/Mathematical-Optimization/How-to-define-one-binary-variable-value-explicitely-among-a/m-p/352786#M1780</link>
      <description>&lt;P&gt;Thank You&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Partha&lt;/P&gt;</description>
      <pubDate>Mon, 24 Apr 2017 11:12:58 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Mathematical-Optimization/How-to-define-one-binary-variable-value-explicitely-among-a/m-p/352786#M1780</guid>
      <dc:creator>pmoovala0</dc:creator>
      <dc:date>2017-04-24T11:12:58Z</dc:date>
    </item>
  </channel>
</rss>

