Element by Element Multplication in GAMS

Hi,

I need help with the correct syntax for element by element multiplication using GAMS. My shortcode is attached.
GamsAssitance.gms (1.5 KB)

Hi
Works fine for me, when I run your code after correcting some non-related errors. But perhaps you are looking for something else.

I attach the corrected version.
Cheers
Renger
GamsAssitance.gms (1.57 KB)

GamsAssitance_Fixed.gms (1.31 KB)

Many thanks for your quick response. I want to apologize for not explaining my problem correctly. I would want to do the following.
Essentially, I would like to scale each hourly load by the factor in tscaling(ss)
So
Pd.t1 = ss1Pd.
Pd.t2 =ss2
Pd
Pd.t3=ss3Pd
Pd.t24=ss24
Pd

so I get a new Table BD(d,b,t,*) but original values scaled by tscaling(ss)

I attach my initial data set.

Hi
As both sets have the same number of elements (24), you can use a loop using the order of the elements.
For example, if you want to multiply Pd(t) with tscaling(ss), this would look like this:

loop(t, 
 loop(ss$(ord(t) = ord(ss), 
        Pd(t) = Pd(t) * tscaling(ss);
   );
);

I hope this helps
Renger

Why don’t you just index the parameter tscaling() by t instead of ss? I.e. make it

parameter tscaling(t) /
t1 0.826
blah blah
/;

The set ss is not really helping you.