Monday 3rd of April 2006, 10:16
Cable Net
![[C++ Cable net program...]](http://www.engtect.net/images/nets.png)
After much anguish with a run time error (I was inadvertently writing to the -1th element of an array and so messed up the pointers blah blah blah) I have finally got a simple C++ program that finds the static equilibrium of any 3D cable net using dynamic relaxation. The maths needs checking and the appropriate engineering values adopted but it is otherwise finished except for animating the net falling and bouncing into position using the graphics application programming interface ‘OpenGL.’ Mark is leading our group on the OpenGL side of things. Good Luck!

Play that funky music, white boy…
It’s so pretty! oh the heart-ache that run-time error caused - the joy of programming in a language with no array bound checking built in. Form finding all the way though. Nearly as good as mine! :-p
Dave, I have been wondering if I should use the assert statement. The assert statement tells C++ to abort the program in a nice way and leave us an error message.
#include <assert.h>
assert( (i>=0) && (i< =sizeof(data)/sizeof(data[0])) );
I suppose what I have learnt is that things that can “never happen” in programming happen far too often.
It looks very nice - I just wish that ours was in the finalisation stage, however, it is more in the I don’t really know what the hell to do next phase. the good news is that since you are so far ahead it means you have more time to help me!! Haha!
You are:
a) a geek
b)too clever (I need to go revise bah)
c) have too much time on your hands
miss you rob…love the blog, even though I don’t understand it all (where does theme/fufu stuff come into it?). Make sure you revise hard so you don’t have resits and we can hang out when I come up to see Han (and pray for the same for me) lol ;)