Hohmann transfer to Mars.

This is the most fuel efficient way to get to Mars. Assumes Mars and Earth are coplanar. Creates a plot showing the transfer orbit.

Since version 2014.1
-------------------------------------------------------------------------
See also DVHoh, Constant, Period
-------------------------------------------------------------------------
%--------------------------------------------------------------------------
%   Copyright (c) 2013 Princeton Satellite Systems, Inc.
%   All Rights Reserved.
%--------------------------------------------------------------------------

aU                      = Constant('au');
muSun                   = Constant('mu sun');
v1                      = sqrt(muSun/aU);
[dV, dV1, dV2, eT, aT]	= DVHoh( aU, 1.5*aU, v1, muSun );
tOF                     = Period(aT,muSun)/2;
t                       = linspace(0,tOF);
el                      = [aT 0 0 0 eT 0];

rT                      = RVFromKepler( el, t, muSun );
a                       = linspace(0,2*pi);

NewFig('Hohmann Transfer')
plot(rT(1,:)/aU,rT(2,:)/aU,'--g','linewidth',2);
hold on
plot(cos(a),sin(a),'b');
plot(1.5*cos(a),1.5*sin(a),'r');
plot(0,0,'oy','linewidth',4)
text(0,0,'     Sun')
text(1.02,0,' Earth')
text(-1.49,0,'  Mars')
title(sprintf('Total Delta-V: %.2g km/s; Duration: %.1f days',dV,tOF/86400))

grid
axis image


%--------------------------------------
% PSS internal file version information
%--------------------------------------
grid =
     0     0     1     0     0     0     1     0
     0     0     0     1     0     1     0     0
     0     0     0     0     0     0     0     0
     0     0     0     0     0     1     1     0
     0     0     0     0     0     0     0     1
     0     0     0     0     0     0     0     0
     0     0     0     0     0     1     0     0
     0     1     0     0     0     1     1     1