function CompTF(optic, exc, sens) % % ---------------------------------------------------------------------- % for KAGRA VIS % The code to compare the simulation and measurement % Coded by A Shoda on 2018/4/4 % % optic: optic, such as 'PR3', 'BS' % exc: excitation channel, such as 'LIM', 'YIP', or 'GASF1' % sens: monitor signal, such as 'LVDT_IPL', 'OSEM_IMT', or 'Oplev_PTM' % **OPTIONAL** (not yet implemented) % status = 0,1: default:0 = undamped, 1 = damped % ---------------------------------------------------------------------- % This code is for adjusting the gain_act numbers % ---------------------------------------------------------------------- %% PRELIMINARY clear all; % Clear workspace close all; % Close plot windows addpath('../../utility'); % Add path to utilities addpath('servofilter'); % Add path to servo g = 9.81; % Gravity constant freq=logspace(-2,2.5,1001); %% MODEL IMPORT load(strcat(optic,'mdl.mat')); % Import ss model DefaultParameters; % Import default servo filters %load(strcat(optic,'mdl_0params.mat')); mdlfile='typeBsimctrl'; % typeB ver.180313 st =linmod(mdlfile); % Linearize simulink model invl =strrep(st.InputName, [mdlfile,'/'],''); outvl =strrep(st.OutputName,[mdlfile,'/'],''); sysc0 =ss(st.a,st.b,st.c,st.d,'inputname',invl,'outputname',outvl); %% define signals end