\documentclass[doublecol]{epl2} 
%\documentclass[page-classic]{epl2}

\usepackage{amsmath}
\usepackage{graphicx}
\usepackage{url}

\title{A2\_5 The Use of the Bittorrent Protocol in Space Computer Networks} %Full Title
\shorttitle{Space Computer Networks} %Insert here a short version of the title if it exceeds 70 characters

\author{C. J. Meredith, D. Boulderstone and S. Clapton}
\shortauthor{Meredith et al}
\paperpub{Feb 16th, 2011.} % publication date

\institute{Department of Physics and Astronomy, University of Leicester.
Leicester, LE1 7RH.}

\abstract{
The applications and benefits of the use of a peer-to-peer networking protocol, such as the Bittorrent protocol, are investigated. It is found that an Earth-Mars distributed network can be entirely updated within 35.6 minutes. 
}


\begin{document}


\maketitle

\section{Introduction}
As of 2010, it is estimated that there are five billion devices connected to the internet\cite{numdevices}. The number of these devices underlies the importance of the internet in the modern era and how it has become integrated in to society. With the eventual colonisation of the solar system, it would only be natural to extend such a useful and ubiquitous network to the entirety of the solar system, effectively turning the world wide web into a solar system wide web. There are obvious problems with such a network, particular pertaining to persistency of connections and lag times. NASA's attempts to establish such a network for space missions have been somewhat successful with the introduction of the DTN (delay tolerent network) protocol\cite{nasa}. This protocol replaces TCP/IP, the traditional internet protocol, and is better suited to space situations, however it does not resolve all of the problems. It is currently being tested on the International Space Station. One of the main problems that still arises is due to the large distances in space and the long time period that requested data would take to be received. This is an unsurmountable barrier in many ways, however the issues caused by these long data transmission times may be somewhat lessoned. The use of peer-to-peer networks is suggested as a possible solution to this problem, particular the use of the Bittorrent protocol. 


\section{The Bittorrent Protocol}

A peer-to-peer network works by utilising the nature of the internet as a distributed network usually to perform file sharing by distributing the bandwidth load across multiple network nodes. One advantage of such a network is that it reduces bandwidth costs to a distributor by its distributed nature. Additionally it has multiple redundancy presuming a large number of peers have a full copy of the file to be distributed. The network can be broken by the removal of a sufficient number of these peers. Peer connecting without a copy of the file will receive a copy and will then join a part of the collective. The Bittorrent protocol breaks the file to be transmitted in to several pieces of the same bit length. The network also requires a so-called `tracker' to coordinate the network, to inform the network which peers are available for connection and also to coordinate the size of the pieces of the file. Also included in the tracker is a SHA-1 hash for each piece of the file in order to check for errors. The major criticism of this method of transmission of data is essentially the random nature of how pieces of file are received. For instance, it is difficult to use a Bittorrent network for streaming of video or audio data due to the end-user potentially receiving end pieces before start pieces. However, in space the latencies involved in real-time activities mean that this issue becomes irrelevant. Any live stream can not be near instantaneous, at least at a great distance to Earth. The use of Bittorrent, together with NASA's DTN protocol would give space communication robustness and also the potential for increased speed. The nature of the distributed network would enhance data propagation across distances and allow a near-real-time access to the world wide web (or other static content). Email services could be provided via the use of push email and the use of the Bittorrent network as a transfer protocol. 

\section{A Hypothetical Network}

To see how this would directly aid networking over large distance such as in the solar system we look at the problem and apply mathematics to observe the benefits. This network consists of the Earth and Mars orbiting the Sun, in between these two planets there are a series of relay and storage satellites orbiting the Sun. A three layer model with 32 satellites in each layer is chosen, although this can be optimised. The furthest distance between Mars and the first layer of the constellation towards Earth can be estimated as,  

\begin{equation}
d_{1}^2 = [(r_{mars} - r_{sat_{1}})+ h_c]^{2} + [c/2]^{2},
\end{equation}

where $ h_c = r_{sat_1}(1 - cos(\theta/2))$, the height of the orbital chord between satellites in orbit; $ c = 2r_{sat_1}sin(\theta/2) $, the length of the chord; $d_{1}^2$ is the maximum distance from Mars to the first relay satellite in the constellation; $\theta$ is the angular separation between satellites; $r_{mars}$ is the radial distance to Mars from the Sun; and $ r_{sat_{1}}$ is the radial distance from the sun to the relay satellite. We find a similar equation for relay satellites at different radii from the Sun. Additionally a distance is required from the Earth to the first relay satellite, similarly to above, this is found below,

\begin{equation}
d_{earth}^2 = [(r_{sat_{1}} - r_{earth})  - h_c]^2 + [c/2]^2,
\end{equation}
where $d_{earth}^2$ is the distance from the Earth to the first relay satellite towards Mars and $r_{earth}$ is the average radius of the Earth's orbit around the Sun. Also to be considered is if the Earth and Mars are not aligned and a transmission around the relay satellites at the lowest radius. This will add an additional distance calculated as:

\begin{equation}
d_{circ} = \frac{\theta}{\Delta \theta}2r_{sat_{3}}sin(\theta/2),
\end{equation}

where $\Delta \theta$ is the angular distance between the Earth and Mars. These distances are concatenated together to produce a total data distance. The data is mostly traveling at the speed of light except for processing through the nodes of the network, we can therefore work out a time for data transmission through the network from Earth to Mars.

\begin{equation}
t = \frac{d_{total}}{c} = \frac{(d_{1} + d_{2} + d_{3} +  d_{circ} + d_{earth})}{c}  
\end{equation}
$$ = \frac{6.40 \times 10^{11} m}{3 \times 10^{8}} = 2133s = 35.6 minutes$$

This is a worse case scenario whereby the nearest relay satellite is the farthest away in each link in the system, additionally the Earth and Mars have been placed on opposites sides of the Sun. The minimal distance would be simply the Earth-Mars distance, $7.84 \times 10^{10}km$, a time of 4.36 minutes. In addition, the further straight line distance between the Earth and Mars takes roughly 19 minutes. The problem with this simplistic approach is that in a Bittorrent network the data would be propagating through the nodes uniformly opposed to having any direction, thus the destination can receive from more than more node at one time. Such as two equidistant nodes or one node closer and one node further away. An extension to the circular network would be to expand the network in towards the centre of the solar system. Obviously when Mars is further away the data will take longer to propagate, however an inner network of satellites in the solar system closer to the sun can reduce the physical distance compared to the method used above. This also resolves any problem related to the Sun blocking the signal from Earth. In a distributed network any node that fails is of no consequence so long as there is a network route around the failed node. In the case of radio communication the relay node is simply skipped and the next node, or an adjacent node is selected instead. 

\section{The Advantages of Bittorrent}

The discussion above is important but the advantages of using such a network is the availability of data roughly on demand. In a standard communication between Earth and Mars, a piece of data must be requested (taking up to 19 minutes), then this piece of data must be sent back taking the same time again. The use of a propagating Bittorent network would be the availability of peers closer to Mars than the Earth itself thus reducing the time taken to receive any requested file. There are many obvious problems to this suggestion, firstly the choice of data must be determined before hand. However with the growing availability of high capacity data storage, vast quantities of information could be stored containing substantial prearranged sections of the world wide web. To work this would require some form of change tracker to be produced, although this would be no more difficult than the use of a search engine crawler. However, this would mean that changes could be made to the data available at Mars long before any request is made for it. In fact every node in the system would be updated and available for use within 35.6 minutes for a given number of bits per second capacity. The use of the distributed network allows solar system coverage to any device from any orbital location, increased signal gain by using the relays as boosters, a reduction in support from Earth and also exceptional redundancy. It is noted that this method cannot of course update content in Earth real-time for the information still cannot travel faster than the speed of light. 

\section{Conclusion}
The use of Bittorrent on distributed networks across the solar system allows near-instantaneous access to data while allowing continuous updating via a series of constellation peer relay satellites. It was found that the maximum time delay for updating the entire network would be 35.6 minutes per given bit rate capacity. This would have enormous advantages for the establishment of a solar system internet network. 

\begin{thebibliography}{0}

\bibitem{numdevices} Hackenberg, S. \textit{Internet Connected Devices Pass 5 Billion Milestone.} August 2010. \ \url{http://www.businesswire.com/news/home/  20100816005081/en/}
\url{Internet-  Connected-Devices-Pass-5-Billion-} 
\url{Milestone} . Accessed 17/02/2011.

\bibitem{nasa} NASA. \textit{Delay Tolerant Network (DTN) Factsheet}. January 2011. \url{http://www.nasa.gov/mission_pages/station/research/experiments/DTN.html}. Accessed 17/02/2011. 

\end{thebibliography}

\end{document}
