Sets and 3D tables Matlab to GAMS IWGDX
Sets and 3D tables Matlab to GAMS IWGDX
Dear all,
My problem is with getting a main set generated randomly in Matlab with other data including 3D table as GDX using IWGDX in Matlab.
set
x /1*5/,
y /1*3/,
t; 'Randomly generated in Matlab'
parameter
A; ' Randomly generated in Matlab'
$GDXIN gdxdata
$LOADIDX t A
$GDXIN
Now A is a table [A(x,y,t)] which 3D
I tried transferring by
iwgdx('C:\gamsdir\projdir\gdxdata','t','A') and
,'A:3')
still getting errors
I was getting errors with the 2D but after using 'a:d' |d--> dimension solved it.
Thanks
--
To unsubscribe from this group and stop receiving emails from it, send an email to gamsworld+unsubscribe@googlegroups.com.
To post to this group, send email to gamsworld@googlegroups.com.
Visit this group at https://groups.google.com/group/gamsworld.
For more options, visit https://groups.google.com/d/optout.
Re: Sets and 3D tables Matlab to GAMS IWGDX
I was thinking if having the upper bpund of the set (t) as a scalar (tt) and then set t/1*tt/; but getting error 764 Could not extract number in * list
Any suggestions?
Thanks
On Monday, April 4, 2016 at 10:28:23 AM UTC+3, thefooox1 wrote:
Dear all,
My problem is with getting a main set generated randomly in Matlab with other data including 3D table as GDX using IWGDX in Matlab.
set
x /1*5/,
y /1*3/,
t; 'Randomly generated in Matlab'
parameter
A; ' Randomly generated in Matlab'
$GDXIN gdxdata
$LOADIDX t A
$GDXIN
Now A is a table [A(x,y,t)] which 3D
I tried transferring by
iwgdx('C:\gamsdir\projdir\gdxdata','t','A') and
,'A:3')
still getting errors
I was getting errors with the 2D but after using 'a:d' |d--> dimension solved it.
Thanks
--
To unsubscribe from this group and stop receiving emails from it, send an email to gamsworld+unsubscribe@googlegroups.com.
To post to this group, send email to gamsworld@googlegroups.com.
Visit this group at https://groups.google.com/group/gamsworld.
For more options, visit https://groups.google.com/d/optout.
Re: Sets and 3D tables Matlab to GAMS IWGDX
Getting error 832 Can only load parameters and scalars.
Also getting 833 Can only load parameters with proper domain for the tables
Now I'm using WGDX to write sets. Better but still getting error 832 Can only load parameters and scalars
Although writing it as follows in Matlab:
tt.name='t';
tt.uels={1:T};
tt.type='set';
and parameter A then
wgdx('C:\M2G',tt,AA)
and
set t;
parameter A(t);
$if not set gdxin $set gdxin M2G
$GDXIN %gdxin%
$LOADIDX t A ...
$GDXIN
Please show me the proper way.
Thanks all
On Tuesday, April 5, 2016 at 12:44:12 PM UTC+3, thefooox1 wrote:
I was thinking if having the upper bpund of the set (t) as a scalar (tt) and then set t/1*tt/; but getting error 764 Could not extract number in * list
Any suggestions?
Thanks
On Monday, April 4, 2016 at 10:28:23 AM UTC+3, thefooox1 wrote:
Dear all,
My problem is with getting a main set generated randomly in Matlab with other data including 3D table as GDX using IWGDX in Matlab.
set
x /1*5/,
y /1*3/,
t; 'Randomly generated in Matlab'
parameter
A; ' Randomly generated in Matlab'
$GDXIN gdxdata
$LOADIDX t A
$GDXIN
Now A is a table [A(x,y,t)] which 3D
I tried transferring by
iwgdx('C:\gamsdir\projdir\gdxdata','t','A') and
,'A:3')
still getting errors
I was getting errors with the 2D but after using 'a:d' |d--> dimension solved it.
Thanks
--
To unsubscribe from this group and stop receiving emails from it, send an email to gamsworld+unsubscribe@googlegroups.com.
To post to this group, send email to gamsworld@googlegroups.com.
Visit this group at https://groups.google.com/group/gamsworld.
For more options, visit https://groups.google.com/d/optout.