during the time between my last post and yours j-th managed to call the j-th element of x[i].solutie using the "clone" method but i was still getting the NullPointerExce ption,that after printed me the (length(x[i].solutie)-1)th element and i figured it out;you were not quite right but absolutely right :in the first loop i should take values between 0 and nr_pasi(meaning i should have right
blazedaces ,you were quite right; i in the second loop should have values between 0 and (nr_pasi-1);now i got another problem,which i suppose has to do exactly with what i have asked in my second post :about the j-th element of the y[i].solutie array;
what i get is:
Error in thread "main" NullPointerExce ption
at SolutiiDeTe.mai n(SolutiiDeTe.j ava:115)
meaning here
i am sure it`s not about the fact that those 2 arrays would have different lenghts; and,yeah i`ve read a thousand times that an object doesn`t exist unless you make exist by using " new something" but i still don`t understand what i should in my case;what i would like to know is wheather the error has to something with this:
i`m developind my second program using java which is supposed to solve a system of ordinary differential equations(S'=-beta*S*I-alfa*I;I'=beta* S*I+alfa*I) using runge kutta method;my first program was supposde to solve a single eq and worked just great(after a initial nullpointer exception error ,which reading some things on the internet i managed to eliminate).now i get the same error and i figure it has something to do with dereferencing ,but...
i`m developind my second program using java which is supposed to solve a system of ordinary differential equations(S'=-beta*S*I-alfa*I;I'=beta* S*I+alfa*I) using runge kutta method;my first program was supposde to solve a single eq and worked just great(after a initial nullpointer exception error ,which reading some things on the internet i managed to eliminate).now i get the same error and i figure it has something to do with dereferencing ,but...
Leave a comment: