Summary: This is an example of using m-files to solve a simple engineering data analysis problem in which velocity and position of a railgun projectile are computed from acceleration data; the acceleration data is computed from the current driving the railgun.
Note: Your browser may not currently support MathML. See our browser support page for additional details. You can always view the correct math in the PDF version.
A railgun is a device that uses electrical energy to accelerate a projectile; information about railguns can be found at the Wikipedia article Railgun. The paper Effect of Railgun Electrodynamics on Projectile Launch Dynamics shows the current profile of a railgun launch. The acelleration
Download the current data set in the file Current.txt onto your computer (right click on this link). The file is formatted as two columns: the first column is time in mili-seconds, and the second column is current in kA.
The following sequence of commands will load the data, create a vector t of time values, create a vector c of current values, and plot the current as a function of time.
load Current.txt -ascii
t = Current(:,1);
c = Current(:,2);
plot(t,c)
xlabel('time (msec)')
ylabel('current (kA)')
|
Compute the projectile velocity as a function of time. Note that velocity is the integral of acceleration.