File size: 2,224 Bytes
5ab75a9 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 | function [maxLUPI] = MaximumLUPIDetermination(EDRBin,ecc,period)
%
% MaximumLUPIDetermination - Determines the maximum LUPI span for an object
% given a few of its OD qualities
%
% Syntax: [maxLUPI] = MaximumLUPIDetermination(EDRBin,ecc,period)
%
% Inputs:
% EDRBin - Energy Dissipation Rate Bin (dimensionless)
% ecc - Eccentricity (dimensionless)
% period - Period of the Object's Orbit (Minutes)
%
% Outputs:
% MaxLUPI - Maximum LUPI Span for which to determine OD for an object
% (days)
%
% Other m-files required: None
% Subfunctions: None
% MAT-files required: None
%
% See also:
%
% Author: Travis Lechtenberg
% September 2018; Last revision: 17-Sep-2018
%
% ----------------- BEGIN CODE -----------------
% Period in minutes
EDRBin = abs(EDRBin);
maxLUPI = nan(size(EDRBin));
% If Period is imaginary, set period to value which forces MaxLUPI to 30
% Days
period(~(imag(period)==0)) = 2000;
period = real(period);
idxs = EDRBin == 0;
periodSubset = period(idxs);
calcLUPISubset = (0.0098 .* periodSubset) + 14.009;
calcLUPISubset(calcLUPISubset > 30.0) = 30.0;
calcLUPISubset(calcLUPISubset < 14.0) = 14.0;
maxLUPI(idxs) = calcLUPISubset;
idxs = EDRBin == 1 & ecc > 0.25;
periodSubset = period(idxs);
calcLUPISubset = (0.0098 .* periodSubset) + 14.009;
calcLUPISubset(calcLUPISubset > 30.0) = 30.0;
calcLUPISubset(calcLUPISubset < 14.0) = 14.0;
maxLUPI(idxs) = calcLUPISubset;
maxLUPI(EDRBin == 1 & ecc <= 0.25) = 18;
maxLUPI(EDRBin == 2) = 17;
maxLUPI(EDRBin == 3) = 15;
maxLUPI(EDRBin == 4) = 14;
maxLUPI(EDRBin == 5) = 12;
maxLUPI(EDRBin == 6) = 11;
maxLUPI(EDRBin == 7) = 10;
maxLUPI(EDRBin == 8) = 8;
maxLUPI(EDRBin == 9) = 8;
maxLUPI(EDRBin == 10) = 7;
end
% ----------------- END OF CODE ------------------
%
% Please record any changes to the software in the change history
% shown below:
%
% ----------------- CHANGE HISTORY ------------------
% Developer | Date | Description
% ---------------------------------------------------
% T. Lechtenberg | 07-25-2019 | Formatting Older Code to Prescribed Format
% conventions |