To LUGNET HomepageTo LUGNET News HomepageTo LUGNET Guide Homepage
 Help on Searching
 
Post new message to lugnet.robotics.handyboardOpen lugnet.robotics.handyboard in your NNTP NewsreaderTo LUGNET News Traffic PageSign In (Members)
 Robotics / Handy Board / 4431
  Multi dimentional Arrays
 
Hi All, I am trying to write a code for fuzzy logic and using Matrix havig a size of 10X10, but it gives an error (stack overflow). When i reduce the size of matrix to 6X6 it works perfectly.I am using IC 3.0. Can I use a matrix having a size (...) (26 years ago, 29-Sep-98, to lugnet.robotics.handyboard)
 
  Re: Multi dimentional Arrays
 
(...) <snip> You might try using a one-dimensional array of size 100, along with a simple indexing function to simulate a two-dimensional array: int myarray[ 100 ]; int index( int row, int col ) { return 10 * row + col; } void main() { int i = 0, j (...) (26 years ago, 29-Sep-98, to lugnet.robotics.handyboard)
 
  Re: Multi dimentional Arrays
 
(...) I don't know how big the IC stack is, but I suspect you are overflowing it because you're allocating the array on the stack. If it's an array of floating point the 10x10 array will be at least 400 bytes, and most likely larger. Try allocating (...) (26 years ago, 29-Sep-98, to lugnet.robotics.handyboard)

©2005 LUGNET. All rights reserved. - hosted by steinbruch.info GbR