I am plotting some seismicity and focal mechanism cross-sections and I noticed that by using pscoupe and project I so not get the exact list of events. I am not able to understand why.
I use the following 2 lines to extract events 100 km on each side of the profiles:
I use exactly the same file as input (I can share and example of input file where 2 events get included in the cross-section only in the case of the 2 commands reported above).
Nope, unfortunately I’ve not found the problem. In the end I had to do it manually. i.e. I projected the hypocentral locations along the cross-sections and used the IDs of the hypocentral locations to associate the focal mechanisms to be projected in the cross-section. A little bit annoying but I haven’t found a better solution. Perhaps it is a bug in GTM (?)
I am not sure it is a bug. Out of curiosity, have you tried plotting a cross-section (distance along the profile vs depth) with both hypocenters and focal mechanisms? Because I’ve been doing as you did (i.e., using project first and then pscoupe), but if I plot both hypocenters and focal mechanisms, there’s a shift that appears to be random along the x-axis and I’m wondering if I am doing something wrong.
Yes that’s what I was doing (i.e. plotting a cross-section (distance along the profile vs depth) with both hypocenters and focal mechanisms) and I realized that there was an issue (not exactly the same events in the cross-section despite selecting the same distance range). Probably if I was using a huge number of focal mechanisms I would not have realized it. Since I was using events 100 km on both side of the cross-section profile I thought it could be due to a different projection method used between gmt project and gmt pscoupe. But unfortunately I did not find a good solution to the issue.
I am noticing the same issue. Interestingly, depending on where I define the origin for the cross-section, sometimes the project and pscoupe results coincide. Other times I see the shift like you are both describing. Below is an example (sorry it is not minimal…at least it is much shorter than the original script!). If you change the cross-section origin (lines 79 or 80), you can see what I am talking about. Figures attached below the script.
Oh, that’s interesting! How did you determine the longitude and latitude values that result in the overlapping output? Was it through trial and error?
I’ve been working with your script and made some interesting observations. By adding a couple of lines to plot the area between the profile and +PROJECT_WID (in blue, attached figure) and the area between the profile and -PROJECT_WID (in red), I discovered that the events on one side of the project profile are shifted to the right compared to pscoupe, while the events on the other side are shifted to the left.
This shift raises the possibility that either the two profiles themselves differ slightly or the event projections vary (potentially due to calculation precision?). As a result of these differences, some mechanisms/events selected with pscoupe are excluded by the project.
To include the same events, I did some tests by adjusting the width of pscoupe slightly. If I use PROJECT_WID=100 and PSCOUPE_WID=101 (attached figure), I get that the same events are picked by pscoupe and project, although the shift along the x-axis remains. Roughly speaking, a 1 km difference (to include the “escaped” mechanisms, at least within areas of this size) corresponds to approximately 1/100th of a degree. This leads me to consider the possibility of a precision problem in distance calculation and projection along the profile. Now, it would be interesting to test this hypothesis. Any suggestions or insights you can provide would be greatly appreciated.