Unable to fill 2d array

 

Can somebody tell me. Why im not able to fill tab[][] in below example ?????????

//+------------------------------------------------------------------+
//|                                                                  |
//+------------------------------------------------------------------+
#property link      ""
//+------------------------------------------------------------------+
//| expert initialization function                                   |
//+------------------------------------------------------------------+
extern int rsi_period = 14;
extern int max_vectors = 150;
extern int vector_length = 50;

int bars;
double tab[][];

int init()
{
   bars = Bars;
   return(0);
}
//+------------------------------------------------------------------+
//| expert deinitialization function                                 |
//+------------------------------------------------------------------+
int deinit()
{
   return(0);
}
//+------------------------------------------------------------------+
//| expert start function                                            |
//+------------------------------------------------------------------+

void prepare_past(int index)
{
   for(int i = 0; i < max_vectors; i++)
   {
      for(int j = 0; j < vector_length; j++)
      {
         tab[i][j] = iRSI(NULL,0,rsi_period,PRICE_CLOSE, i*vector_length + j + index); // even: tab[i][j] = 4.0; prints 0.00;
         Print( DoubleToStr( tab[i][j] , 2 ) );
      }
   }
}

int start()
{
   if(Bars > bars)
   {
      prepare_past(3);
      bars = Bars;
   }
   return(0);
}
//+------------------------------------------------------------------+
 
raniel:

Can somebody tell me. Why im not able to fill tab[][] in below example ?????????

tab is an array of zero element size . . . there is nothing to fill.
 
Even this:
double tab[150][50];
will not resolve my issue.
 
raniel:
Even this: will not resolve my issue.
What is the value of bars ?
 
Solved: There was not enough data in tester history ;-). Thank you Raptor.