[Matthew Louis Sheila]
This alog was motivated by trying to understand how CHETA intensity noise will affect the ESD, where we are interested in the open loop gain of DARM (explained more in future alog).
Measuring the open loop gain of DARM
A sample script can be found at the bottom as well as these notebook style instructions.
First you will need to activate the appropriate conda environment
conda activate /ligo/groups/cal/conda/pydarm
Then enter into an ipython shell, then enter the following commands
from pydarm.cmd import Report
import numpy as np
r = Report.find("last")
# create frequency array over which you want the olg
freqs = np.geomspace( 0.1, 1e5, 7000)
olg = r.model.compute_darm_olg(freqs)
olg_gain, olg_phase = np.abs(olg), np.angle(olg)
To write to a file, you can use the numpy command
filename = ""# /path/of/savefile.txt
comments = "" # make sure you put the date in and the report string
data = np.array([np.array([freq[i], olg_gain[i], olg_phase[i]]) for i in range(len(freq))])
np.savetxt(filename, data, header= comments, delimiter=',', fmt='%.10e')