Hi guys!!!

This is my first post on daniweb & i hope i find a solution to my problem.I am developing a software that makes extensive use of Matrices.i have used dynamic memory allocation for matrices.Now this program makes lots of iterations.It works upto certain iterations say 56 after which it halts giving null pointer assignment error.Its giving the same message on same iteration regardless of teh values that i am entering.I think its happening because the memory is exhausted.but i am not sure.wht do u intelligent people think???I am very new at this field & need your help.
Plzzzzzzz help me.Is it a good idea to attach my program with this msg???soembody please help this confused soul.:sad: :?:

Hard to tell with your limited explaination. There are some things you can do to see if it is really exhausting memory.
You can check the memory pointer to which memory allocated is assigned using malloc or new. use the condition the memory pointer is NULL for malloc or in the case of new, you can use this technique. Most probably you are trying to access a invalid location. Try to use your debugger ( you know how to use it don't you ) and see at what part of your program does this occur.

Another way to determine if memory is really exhausted it by looking at the task manager if you are using windows. if you can see that the memory usage increases upto its maximum limit and fails while you execute the program, that means the memory is exhausted. If not, then you are doing something else wrong.

Hi guys!!!


Is it a good idea to attach my program with this msg???

Generally, yes. Be sure to read this about Code Tags.

Also, in English, sentences end in a period which is then followed by a space. Don't write them like a web address.

Do you have memory allocation check? Implement it then you will be shore is that your problem or not.