Project

General

Profile

Bug #683

Merge gap interp not working correctly

Added by Chad Trabant over 9 years ago. Updated almost 9 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Start date:
04/15/2015
Due date:
% Done:

100%

Estimated time:
1.00 h
Resolution:
Fixed

Description

Issue reported by user is that "merge gap interp" does not work correctly. The same user offered the following fix:

I have fix the problem, in the program xmerge.c at line 341, I make this change
    //  y[i] = yb + i *(ye-yb)/(e-b);  //old
    y[i] = yb + (i-b) *(ye-yb)/(e-b);  //new 

The proposed fix needs evaluation.

2007.117.08.01.48.8100.IA.TSI..BHZ.D.SAC (1.71 KB) 2007.117.08.01.48.8100.IA.TSI..BHZ.D.SAC Chad Trabant, 04/15/2015 10:51 AM
2007.117.08.02.02.9299.IA.TSI..BHZ.D.SAC (5.41 KB) 2007.117.08.02.02.9299.IA.TSI..BHZ.D.SAC Chad Trabant, 04/15/2015 10:51 AM
sac_merge.png (12.5 KB) sac_merge.png Chad Trabant, 04/15/2015 10:51 AM

History

#1 Updated by Chad Trabant over 9 years ago

For context here is the full user report:

Dear all;

Firstly thank for your very help full program sac. 
Now I am using sac on ubuntu 14.04. 

 SEISMIC ANALYSIS CODE [12/22/2014 (Version 101.6)]
 Copyright 1995 Regents of the University of California

But I find problem to merge data with GAP INTERP, the result not correct. 
Please kindly find the sac file and the plotting in attachment file. 

The command I run 

SAC> r 2007.117.08.01.48.8100.IA.TSI..BHZ.D.SAC 2007.117.08.02.02.9299.IA.TSI..BHZ.D.SAC 
SAC> merge gap zero
merge: Gap zero fill
SAC> w zero.sac
SAC> r 2007.117.08.01.48.8100.IA.TSI..BHZ.D.SAC 2007.117.08.02.02.9299.IA.TSI..BHZ.D.SAC 
SAC> merge gap interp 
merge: Gap interp fill
SAC> w interp.sac
SAC> r 2007.117.08.01.48.8100.IA.TSI..BHZ.D.SAC 2007.117.08.02.02.9299.IA.TSI..BHZ.D.SAC zero.sac interp.sac
SAC> p1

Could you help me how to fix the problem about using merge gap inter?

Thank you for your help and collaboration.

Best regards,
Irwandi

#2 Updated by Brian Savage over 9 years ago

  • Assignee set to Brian Savage

#3 Updated by Brian Savage almost 9 years ago

  • Resolution set to Fixed
  • Estimated time set to 1.00 h
  • % Done changed from 0 to 100
  • Status changed from New to Resolved

The fix provided in the email fixed the issue. Thanks !

#4 Updated by Brian Savage almost 9 years ago

  • Status changed from Resolved to Closed

Also available in: Atom PDF