diff options
author | dhebeha <dhebeha.mj71@wipro.com> | 2020-04-30 16:12:32 +0530 |
---|---|---|
committer | dhebeha <dhebeha.mj71@wipro.com> | 2020-04-30 16:35:30 +0530 |
commit | e07bb7a6bce3fa331c3e556395663dd77bc02676 (patch) | |
tree | 3fb75972940303b79cf237caa034824d96b9758c /apps/pci/optimizers/solver/min_confusion_inl.mzn | |
parent | d4a0085a8f75c62912d19613459ad1bc3dce3e73 (diff) |
Change to support PCI unchangeable cells
Issue-ID: OPTFRA-678
Signed-off-by: dhebeha <dhebeha.mj71@wipro.com>
Change-Id: Ib7620cb19850d77e80b2baea5ef318e8b0182d7c
Diffstat (limited to 'apps/pci/optimizers/solver/min_confusion_inl.mzn')
-rw-r--r-- | apps/pci/optimizers/solver/min_confusion_inl.mzn | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/apps/pci/optimizers/solver/min_confusion_inl.mzn b/apps/pci/optimizers/solver/min_confusion_inl.mzn index 0f0fc91..e677e27 100644 --- a/apps/pci/optimizers/solver/min_confusion_inl.mzn +++ b/apps/pci/optimizers/solver/min_confusion_inl.mzn @@ -52,6 +52,14 @@ int: NUM_IGNORABLE_NEIGHBOR_LINKS; % of the links, like the previous structures. array[1..NUM_IGNORABLE_NEIGHBOR_LINKS, 1..2] of int: IGNORABLE_NEIGHBOR_LINKS; +% ids of cells for which the pci should remain unchanged +set of int: PCI_UNCHANGEABLE_CELLS; + +% This array has the original pcis of all the cells. array is indexed by the ids +% of the cell. eg. ORIGINAL_PCIS[3] returns the pci of cell whose id is 3. +% ids start from 0 +array[1..NUM_NODES] of 0..NUM_PCIS-1: ORIGINAL_PCIS; + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % Decision variables %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% @@ -65,6 +73,14 @@ array[1..NUM_IGNORABLE_NEIGHBOR_LINKS] of var 0..1: used_ignorables; % Constraints %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +% fixed pci cells +constraint +if(length(PCI_UNCHANGEABLE_CELLS) !=0) then +forall(i in PCI_UNCHANGEABLE_CELLS)( + pci[i] == ORIGINAL_PCIS[i+1] +) +endif; + % Direct neighbors must have different PCIs for avoid **COLLISION**. % Forced links. constraint |