PS Processing

Hi,
In PS processing of StaMPS 5 step i have this error,
Index exceeds array bounds.

Error in llh2local (line 41)
dlambda=llh(1,z)-origin(1);

Error in ps_merge_patches (line 485)
xy=llh2local(lonlat’,ll0)*1000;

Error in stamps (line 474)
ps_merge_patches

I tried changing the parameter ‘merge_resample_size’ = 0 aslo i changed the Density to 50 but still not working