help-glpk
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Help-glpk] Fwd: Defining a subset of a multi dimension set


From: glpk xypron
Subject: Re: [Help-glpk] Fwd: Defining a subset of a multi dimension set
Date: Fri, 01 Oct 2010 22:44:44 +0200

Hello Aly,

> 'SELECT DISTINCT FacilityID, ResourceID FROM
> TransformerTypePeriodResources' :
> Facilities_Resources_IN_FacilityResourcePeriod <-[FacilityID, ResourceID];
> 
> Then, would that set have all combinations of FacilityID and ResourceID
> independently, or just the combinations that were there in the table? The
> latter is the needed one not the former, but I just wanna make sure that the
DISTINCT will remove all duplicate entries from the result set.
Hence you get all combinations that exist in the queried table.

> 2. Isn't there any other way that is less memory intensive? I mean, isn't
> there a way to access 1 or 2 indices in a 3 indexed set, without defining
> and storing a set for that??
set A, dimen 3;
set B, dimen 2 := setof{ (a1, a2, a3) in A} (a1, a2);
See glpk-4.44/doc/gmpl.pdf

Best regards

Xypron


-- 
GRATIS: Spider-Man 1-3 sowie 300 weitere Videos!
Jetzt freischalten! http://portal.gmx.net/de/go/maxdome



reply via email to

[Prev in Thread] Current Thread [Next in Thread]