<div dir="ltr"><div class="gmail_default" style="font-size:small">Dear Dipti,</div><div class="gmail_default" style="font-size:small"><br></div><div class="gmail_default" style="font-size:small">I was able to reproduce this problem on my Cygwin system at home, but I didn't have much time to debug it. </div><div class="gmail_default" style="font-size:small"><br></div><div class="gmail_default" style="font-size:small">Kevin tried your script on a Mac system, and I tried it on both a 32-bit and 64-bit Linux system and it worked fine. So, it seems to be limited to Cywgin.</div><div class="gmail_default" style="font-size:small"><br></div><div class="gmail_default" style="font-size:small">I will look into this over the weekend. </div><div class="gmail_default" style="font-size:small"><br></div><div class="gmail_default" style="font-size:small">Meanwhile, is your system a 64-bit system running Windows 10? If so, then you might want to consider using Window's Linux subsystem instead of Cygwin for your UNIX environment. I'm guessing that your wavelet program might work under this system.</div><div class="gmail_default" style="font-size:small"><br></div><div class="gmail_default" style="font-size:small">Please see this link for more information:</div><div class="gmail_default" style="font-size:small"><br></div><div class="gmail_default"><a href="http://www.ncl.ucar.edu/Download/windows_linux_subsystem.shtml">http://www.ncl.ucar.edu/Download/windows_linux_subsystem.shtml</a><br></div><div class="gmail_default"><br></div><div class="gmail_default"><br></div><div class="gmail_default">--Mary</div><div class="gmail_default"><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Apr 20, 2017 at 6:05 PM, Kevin Hallock <span dir="ltr"><<a href="mailto:hallock@ucar.edu" target="_blank">hallock@ucar.edu</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi Dipti,<br>
<br>
I tried to run your script on my Mac, but it ran successfully without a segfault. We will find a Windows system with cygwin to test your script on and will respond again soon.<br>
<br>
Kevin<br>
<div><div class="h5"><br>
> On Apr 19, 2017, at 12:23 PM, Dipti Sharma <<a href="mailto:sdipti596@gmail.com">sdipti596@gmail.com</a>> wrote:<br>
><br>
> Dear All,<br>
><br>
> I am trying to understand how to do the wavelet analysis using NCL. I am using ncl v6.4.0 in cygwin/x. I started using an example code and the data that are available online. But I got an error message as "segmentation fault (core dumped)" when I ran the program. I have given the code that I used as below for you to review. Also I have attached the data I used in the email.<br>
><br>
> So, could you please suggest me how I solve this problem?<br>
><br>
> Thanks in advance.<br>
><br>
> Dipti S.<br>
><br>
> THE CODE is here and the data is attached in the email,<br>
><br>
> load "$NCARG_ROOT/lib/ncarg/<wbr>nclscripts/csm/gsn_code.ncl"<br>
> load "$NCARG_ROOT/lib/ncarg/<wbr>nclscripts/csm/gsn_csm.ncl"<br>
> load "$NCARG_ROOT/lib/ncarg/<wbr>nclscripts/csm/contributed.<wbr>ncl"<br>
> load "$NCARG_ROOT/lib/ncarg/<wbr>nclscripts/csm/shea_util.ncl"<br>
> load "$NCARG_ROOT/lib/ncarg/<wbr>nclscripts/csm/shea_util.ncl"<br>
><br>
> ;-----------------------------<wbr>------------------------------<wbr>---------<br>
> ; CREATE SAME WAVELET FIGURE AS TORRENCE & COMPO using seasonal Nino3<br>
> ; from 1871-1997<br>
> begin<br>
> ninoseas = asciiread("C:\diptic\sst\sst_<wbr>nino3.dat",-1,"float")<br>
> ninoseas!0 = "time"<br>
> ntime = dimsizes(ninoseas)<br>
> timeo = fspan(1871.25,1996.,ntime)<br>
> print(ntime)<br>
> ninoseas&time = timeo<br>
> ninomam = dim_avg_Wrap(ninoseas(0::4))<br>
> ninojja = dim_avg_Wrap(ninoseas(1::4))<br>
> ninoson = dim_avg_Wrap(ninoseas(2::4))<br>
> ninodjf = dim_avg_Wrap(ninoseas(3::4))<br>
> ninoseas(0::4) = ninoseas(0::4) - ninomam<br>
> ninoseas(1::4) = ninoseas(1::4) - ninojja<br>
> ninoseas(2::4) = ninoseas(2::4) - ninoson<br>
> ninoseas(3::4) = ninoseas(3::4) - ninodjf<br>
> time = timeo<br>
> N = dimsizes(time)<br>
> ;_FillValue=1e+36<br>
> ;printMinMax(ninoseas,False)<br>
> ;return<br>
> ;*****************************<wbr>*******<br>
> ; compute wavelet<br>
> ;*****************************<wbr>*******<br>
> mother = 0<br>
> param = 6.0<br>
> dt = 0.25 ;timesteps in units of years<br>
> s0 = dt<br>
> dj = 0.25<br>
> jtot = 1+floattointeger(((log10(N*dt/<wbr>s0))/dj)/log10(2.))<br>
> npad = N<br>
> nadof = 0.0<br>
> noise = 1<br>
> siglvl = 0.05<br>
> isigtest= 0<br>
> print(nadof)<br>
> w =wavelet(ninoseas,mother,dt,<wbr>param,s0,dj,jtot,npad,noise,<wbr>isigtest,siglvl,nadof)<br>
> printVarSummary(w)<br>
> return<br>
> end<br>
> ;;; This is the output I received,<br>
><br>
> Variable: ntime<br>
> Type: integer<br>
> Total Size: 4 bytes<br>
> 1 values<br>
> Number of Dimensions: 1<br>
> Dimensions and sizes: [1]<br>
> Coordinates:<br>
> (0) 504<br>
> (0) min=-1.8504 max=2.49921<br>
><br>
> Variable: nadof<br>
> Type: float<br>
> Total Size: 4 bytes<br>
> 1 values<br>
> Number of Dimensions: 1<br>
> Dimensions and sizes: [1]<br>
> Coordinates:<br>
> (0) 0<br>
> Segmentation fault (core dumped)<br>
><br>
><br>
</div></div>> <sst_nino3.dat>_______________<wbr>______________________________<wbr>__<br>
<div class="HOEnZb"><div class="h5">> ncl-talk mailing list<br>
> <a href="mailto:ncl-talk@ucar.edu">ncl-talk@ucar.edu</a><br>
> List instructions, subscriber options, unsubscribe:<br>
> <a href="http://mailman.ucar.edu/mailman/listinfo/ncl-talk" rel="noreferrer" target="_blank">http://mailman.ucar.edu/<wbr>mailman/listinfo/ncl-talk</a><br>
<br>
______________________________<wbr>_________________<br>
ncl-talk mailing list<br>
<a href="mailto:ncl-talk@ucar.edu">ncl-talk@ucar.edu</a><br>
List instructions, subscriber options, unsubscribe:<br>
<a href="http://mailman.ucar.edu/mailman/listinfo/ncl-talk" rel="noreferrer" target="_blank">http://mailman.ucar.edu/<wbr>mailman/listinfo/ncl-talk</a><br>
</div></div></blockquote></div><br></div>