Example FERS Simulation
Introduction
You are designing a sonar system for a small robot. The system is
designed to use a low power 0.2W isotropic transmitter, and an
isotropic receiver (yes, this is impossible, we will introduce other
models later in the example). The transmitter and receiver are spaced
5cm apart on the robot. Your sonar transducer has a center frequency of
40kHz, and you have chosen a 0.5ms pulse at 40kHz as your signal.
You would like to know how receiver noise limits the range of the sonar
system.
1. Generating the Pulse
In this example, we will generate the pulse to be transmitted with
MATLAB. Other tools, such as IDL and Octave can be used with equal
success.
Generating the pulse in MATLAB is extremely simple.
%Generate a 0.5ms rect pulse at Fs = 48000
g=zeros(1,48);
g(12, 36)=1;
%Use the ferscsvwrite function, included with FERS to make a pulse file
ferscsvwrite('rect.csv', g, 48e3);
The code above will create the pulse in a csv file, ready to be
imported into FERS. The pulse is created at a sample frequency of 48kHz
- for correct simulation, the sample frequency of all imported pulses
must be equal, and must be greater than twice the system bandwidth.
Here, the bandwidth is fairly small, and 48kHz is sufficient as a
sample rate.
2. Writing the FERS script
The next step is to create a FERS XML script to tell the simulator the parameters of the system to be simulated.
In the first part of the file, the start and end time of the simulation
is specified, the propagation speed is set and the sample rate of the
simulation is set. Finally the simulator is told to export the raw
responses in CSV format, and the parameters of each response in XML
format.
<simulation name="sim1">
<parameters>
<starttime>0</starttime>
<endtime>0.1</endtime>
<c>340.29</c>
<rate>48000</rate>
<export csv="true" binary="true" csvbinary="true"/>
</parameters>
The next part of the file imports the pulse we created in step 1, sets
the power to 0.2W and the carrier frequency to 40kHz. The "timing"
block sets the jitter and frequency of timing sources used in the
system - it's not important for this system, but is extremely important
for networked and distributed radar systems. Lastly, the antenna (in
this case, a transducer) is defined, given a name and a radiation
pattern. The "isotropic" pattern is used here, for clarity.
<pulse name="trpulse" type="file" filename="pn.csv">
<power>0.2</power>
<carrier>40000</carrier>
</pulse>
<timing name="clock">
<frequency>10e6</frequency>
<jitter>1e-9</jitter>
</timing>
<antenna name="trantenna" pattern="isotropic">
</antenna>
Next, the transmitter is set up. It is attached to a platform which
controls it's motion and rotation. We are only interested in the first
pulse sent out by the system, so the Pulse Repetition Frequency (PRF)
is set to one.
<platform name="trans">
<motionpath>
<positionwaypoint>
<x>0.0</x>
<y>0.0</y>
<altitude>0.0</altitude>
<time>0</time>
</positionwaypoint>
</motionpath>
<fixedrotation>
<startazimuth>0.0</startazimuth>
<startelevation>0.0</startelevation>
<azimuthrate>0</azimuthrate>
<elevationrate>0</elevationrate>
</fixedrotation>
<transmitter name="sum_channel" type="pulsed" pulse="trpulse" antenna="trantenna" timing="clock">
<prf>1</prf>
</transmitter>
</platform>
The receiver setup is similar to the transmitter setup the range window
(or gate) is defined to give a maximum range of 17m (34m round trip)
and the beginning of the gate is set to reject the direct radiation of
the pulse from the transmitter. The receiver noise temperature is set to 100k.
<platform name="recv">
<motionpath>
<positionwaypoint>
<x>0.01</x>
<y>0.0</y>
<altitude>0.0</altitude>
<time>0</time>
</positionwaypoint>
</motionpath>
<fixedrotation>
<startazimuth>0</startazimuth>
<startelevation>0</startelevation>
<azimuthrate>0</azimuthrate>
<elevationrate>0</elevationrate>
</fixedrotation>
<receiver name="feedD" antenna="trantenna" timing="clock">
<window_skip>0</window_skip>
<window_length>0.1</window_length>
<prf>1</prf>
<noise_temp>100</noise_temp>
</receiver>
</platform
Finally, three targets are defined - one at 0.5m from the transmitter, one at 5m and one at 15m.
<platform name="target">
<motionpath>
<positionwaypoint>
<x>0</x>
<y>0.5</y>
<altitude>0</altitude>
<time>0</time>
</positionwaypoint>
</motionpath>
<fixedrotation>
<startazimuth>0.0</startazimuth>
<startelevation>0.0</startelevation>
<azimuthrate>0</azimuthrate>
<elevationrate>0</elevationrate>
</fixedrotation>
<target name="wings">
<rcs type="isotropic">
<value>0.1</value>
</rcs>
</target>
</platform>
<platform name="far_target">
<motionpath>
<positionwaypoint>
<x>0</x>
<y>5</y>
<altitude>0</altitude>
<time>0</time>
</positionwaypoint>
</motionpath>
<fixedrotation>
<startazimuth>0.0</startazimuth>
<startelevation>0.0</startelevation>
<azimuthrate>0</azimuthrate>
<elevationrate>0</elevationrate>
</fixedrotation>
<target name="wings">
<rcs type="isotropic">
<value>1</value>
</rcs>
</target>
</platform>
<platform name="further_target">
<motionpath>
<positionwaypoint>
<x>0</x>
<y>15</y>
<altitude>0</altitude>
<time>0</time>
</positionwaypoint>
</motionpath>
<fixedrotation>
<startazimuth>0.0</startazimuth>
<startelevation>0.0</startelevation>
<azimuthrate>0</azimuthrate>
<elevationrate>0</elevationrate>
</fixedrotation>
<target name="wings">
<rcs type="isotropic">
<value>1</value>
</rcs>
</target>
</platform>
3. Running The Simulator
Running FERS is extremely simple - just call the executable with the script you have just defined.
./fers example.fersxml
4. Viewing the Results
The results of the simulation are exported in a CSV (comma separated
values) file format, which can be very easily imported into MATLAB,
IDL, Octave or other application. Using one of these applications, it
is simple to draw graphs of the responses and understand the
performance of the sonar system.
When FERS is complete, it will model the gain of the receiving front
end and the effects of quantization in the analogue to digital
converters.
5. Conclusion
This example shows only a few of the capabilities of FERS, but should
give an idea of what FERS is and how it can be used for design support
and investigating different properties of radar and sonar systems.