# Problem to wave using the high-order waveform approximant

**URL:** <https://ask.igwn.org/t/problem-to-wave-using-the-high-order-waveform-approximant/1162>\
**Category:** Data Analysis\
**Created:** [January 15, 2025, 5:19am UTC](https://ask.igwn.org/t/problem-to-wave-using-the-high-order-waveform-approximant/1162 "2025-01-15T05:19:29Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![lupinlin](https://avatars.discourse-cdn.com/v4/letter/l/f05b48/32.png) [@lupinlin](https://ask.igwn.org/u/lupinlin)\
**Post date:** [January 15, 2025, 5:19am UTC](https://ask.igwn.org/t/problem-to-wave-using-the-high-order-waveform-approximant/1162/1 "2025-01-15T05:19:29Z")

</div>

To simply check the frequency evolution of the high-order time-domain (TD) waveform (i.e., SEOBNRv4HM\_ROM), I performed the following code by the google colab:

```auto
import matplotlib.pyplot as pp
from pycbc import waveform

import warnings
warnings.filterwarnings("ignore", "Wswiglal-redir-stdio")
import lal
hp, hc = waveform.get_td_waveform(approximant='SEOBNRv4HM_ROM',
                                  mass1=7, mass2=40,
                                  delta_t=1.0/4096,
                                  mode_array=[(2,2)],
                                  f_lower=20.0,
                                  spin1z=0.1, 
                                  spin2z=0.1,
                                  inclination=1.0,
                                  duration=10,
                                  distance=1.0,
                                  f_ref=20.0)
hp, hc = hp.trim_zeros(), hc.trim_zeros()
f = waveform.utils.frequency_from_polarizations(hp,hc)
pp.legend(loc='best')
pp.plot(f.sample_times, f, label="PN Order = %s" % phase_order)

```

However, I obtained the following error messages:

```auto
RuntimeError Traceback (most recent call last)

<ipython-input-3-678f316ce859> in <cell line: 2>()
      1 from pycbc import waveform
----> 2 hp, hc = waveform.get_td_waveform(approximant='SEOBNRv4HM_ROM',
      3 mass1=7, mass2=40,
      4 delta_t=1.0/4096,
      5 #mode_array=[(2,2)],

12 frames

/usr/local/lib/python3.10/dist-packages/pycbc/pnutils.py in _get_imr_duration(m1, m2, s1z, s2z, f_low, approximant)
    541 elif approximant == "SEOBNRv4":
    542 # NB for no clear reason this function has f_low as first argument
--> 543 time_length = lalsim.SimIMRSEOBNRv4ROMTimeOfFrequency(
    544 f_low, m1 * lal.MSUN_SI, m2 * lal.MSUN_SI, s1z, s2z)
    545 elif approximant == 'SEOBNRv5_ROM':

RuntimeError: Internal function call failed: Generic failure

```

Since I cannot find useful indications from the website of LAL or pyCBC, does anyone who has the experience to generate the high-order waveform provide me some suggestions?

---

<div class="post-metadata">

**Author:** ![lupinlin](https://avatars.discourse-cdn.com/v4/letter/l/f05b48/32.png) [@lupinlin](https://ask.igwn.org/u/lupinlin)\
**Post date:** [January 31, 2025, 5:51am UTC](https://ask.igwn.org/t/problem-to-wave-using-the-high-order-waveform-approximant/1162/2 "2025-01-31T05:51:07Z")

</div>

In the current PyCBC package, it seems that the “SEOBNRv4HM\_ROM” connects to the lal simulation of the non-HM code (LALSimIMRSEOBNRv4ROM.c); however, it should connect to “LALSimIMRSEOBNRv4HMROM.c”.  
If you remove the mode\_array in your code, then it should be worked.  
Two similar approximants (“SEOBNRv4\_ROM” and “SEOBNRv4HM”) can be applied to generate the waveform with the parameter of “mode\_array.”  
However, even though we tune the different values, “SEOBNRv4\_ROM” can only generate the waveform in mode (2,2).  
We can only obtain the specific behavior in the generation of the waveform by the “SEOBNRv4HM” of different modes.  
Please note that an approximant name with the suffix “\_ROM” has the problem to be performed via google colab now.
