%% Project file for IMPACT 

% Release
iRelease = 1.000;

% Models files
path{1} = fullfile(matlabroot,'toolbox','IMPACT','demo','wec2');
file{1} = 'wec2_IMPACT_Model.m';


% Controller parameters
Data(1).name = 'controller 1';
Data(1).ptoCont = ' 7.038e07*(s+0.00589)/(s+0.00916)/(s+4.616)';
Data(1).floaterImpedance = 'zpk([-21.359 -0.220625+0.88669i -0.220625-0.88669i -0.0491108+0.79847i -0.0491108-0.79847i -0.0238276 -0.0232656 ], [-7.92444 -0.290113+1.08611i -0.290113-1.08611i -0.0528487+0.793327i -0.0528487-0.793327i -0.0234091 -0.0228607 -0.00178193 -0.00178117 ], [1.21713e-07 ])';
Data(1).sparImpedance = 'tf(0)';
Data(1).floaterFexc = 'tf(0)';
Data(1).sparFexc = 'tf(0)';

Data(1).floaterImpedanceX = 'tf(1)';
Data(1).sparImpedanceX = 'tf(1)';
Data(1).floaterFexcX = 'tf(1)';
Data(1).sparFexcX = 'tf(1)';

Data(1).ptoContX = 'tf(1)';


EKFFloater.rInitialFrequencyEkf = 0.5;
EKFFloater.rInitialPhi0 = 100000;
EKFFloater.rTimeStep = 0.01;
EKFFloater.arProcessNoiseCovariance_1 = 100000;
EKFFloater.arProcessNoiseCovariance_2 = 100000;
EKFFloater.arProcessNoiseCovariance_3 = 1e-12;
EKFFloater.arProcessNoiseCovariance_1_0 = 100000;
EKFFloater.arProcessNoiseCovariance_2_0 = 100000;
EKFFloater.arProcessNoiseCovariance_3_0 = 0.0001;
EKFFloater.arMeasurementNoiseCovariance = 1e+10;
EKFFloater.rUpperFreq = 2;

EKFSpar.rInitialFrequencyEkf = 0.5;
EKFSpar.rInitialPhi0 = 100000;
EKFSpar.rTimeStep = 0.01;
EKFSpar.arProcessNoiseCovariance_1 = 1e+06;
EKFSpar.arProcessNoiseCovariance_2 = 1e+06;
EKFSpar.arProcessNoiseCovariance_3 = 1e+06;
EKFSpar.arProcessNoiseCovariance_1_0 = 100000;
EKFSpar.arProcessNoiseCovariance_2_0 = 100000;
EKFSpar.arProcessNoiseCovariance_3_0 = 0.1;
EKFSpar.arMeasurementNoiseCovariance = 1e+10;
EKFSpar.rUpperFreq = 2;

iControlType = 1;
iAdaptiveDamping = 0;
iPtoPositionConstraint  = 1;
rDisplacementLimit = 10.000000;
rMaxForcePto = 1000000000000000.000000;
rMinForcePto = -1000000000000000.000000;
rOutputSampleTime = 0.010000;
rStartRampTime = 300.000000;
rRampTimeLength = 100.000000;
rPassiveDampingGain = -1948070.000000;
rPassiveDampingGainX = 0.000000;
rDisplacementLimitX = 10.000000;
stAddParamsFile = fullfile(matlabroot,'toolbox','IMPACT','demo','wec2','wec2AdditionalParams.m');
