User Profile

Collapse

Profile Sidebar

Collapse
TiggiePurr
TiggiePurr
Last Activity: Apr 10 '07, 12:51 PM
Joined: Mar 30 '07
Location:
  •  
  • Time
  • Show
  • Source
Clear All
new posts

  • pgCC segmentation fault when accessing 0 position in vector

    Helpppp..... I have tons of code and can't seem to figure out why I'm getting a segmentation fault on the last line...

    Code:
       int twoc;
       int i;
       twoc = count1s *2;
     // definitely init vector with dim twoc to 1?
       vector< int> hold (twoc, 1);
       :
       i = hold[0];
    Thanks a ton!!!
    See more | Go to post

  • TiggiePurr
    replied to 4-D data type
    in C
    EXCELLENT!!! Thanks a ton!!...
    See more | Go to post

    Leave a comment:


  • TiggiePurr
    replied to 4-D data type
    in C
    Sorry that was my fault when typing this into this site as I stripped the function down to this simple one - yes the variables have been declared. I'm receiving the pointer-to-object error which was because I neglected to add the fourth vector declaration. What about global declaration and initialization - any thoughts? I can do this via for loops, but this is for a fluid flow problem and is labor intensive and needs to be done many times. T...
    See more | Go to post

    Leave a comment:


  • TiggiePurr
    started a topic 4-D data type
    in C

    4-D data type

    Thank goodness for websites like this one....

    I've been out of the C++ loop for about 10 yrs - so many changes (and things I've forgotten).

    It seems that the new "vector" type may be what I want.

    I need to declare a 4 dimensional array (user specified length and to be read from file). So far, I'd like to be able to use the vector functions for manipulating and storing.

    Assuming...
    See more | Go to post
No activity results to display
Show More
Working...