Compute the payload fraction as a function of structural fraction.

The structural fraciton is a function ratio of structural mass to fuel mass. ------------------------------------------------------------------------ See also Plot2D, SS2O ------------------------------------------------------------------------

%-------------------------------------------------------------------------------
%    Copyright (c) 2009 Princeton Satellite Systems, Inc. All rights reserved.
%-------------------------------------------------------------------------------

mP     = 300; % Payload and fixed mass
h      = 390; % ISS max orbit
i      = 51.6*pi/180;
dVLoss = 2; % Losses due to gravity and drag
rE     = 6378.165;
vE     = rE*2*pi/86400;

dV     = sqrt(3.98600436e5/(rE+h))- vE*cos(i) + dVLoss;
Isp    = (339.9 +429.8)/2; % Average for aerospike engine
k      = exp(dV/(Isp*9.806e-3));

fSMax  = 1/(k-1);

fS     = linspace(0,fSMax);% Structural fraction
n      = length(fS);
e      = zeros(1,n);

for k = 1:n
    [mF, mT, mS, e(k)] = SS2O( Isp, mP, fS(k), dV );
end
Plot2D( fS, e, 'Structural Fraction', 'Payload Fraction', 'SSTO');


%--------------------------------------
% PSS internal file version information
%--------------------------------------