Fix average
This commit is contained in:
parent
c284587105
commit
f9171aa355
@ -136,8 +136,8 @@ int lyapunov(
|
|||||||
// average lyapunov
|
// average lyapunov
|
||||||
for(i=0; i<MATSIZE; i++){
|
for(i=0; i<MATSIZE; i++){
|
||||||
// exclude inf
|
// exclude inf
|
||||||
if(! isinf(lyapunov[i])){
|
if((! isinf(lyapunov[i])) && (time>starting_time)){
|
||||||
lyapunov_avg[i]=lyapunov_avg[i]*prevtime/time+lyapunov[i]*(time-prevtime)/time;
|
lyapunov_avg[i]=lyapunov_avg[i]*(prevtime-starting_time)/(time-starting_time)+lyapunov[i]*(time-prevtime)/(time-starting_time);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user