Initial Commit - Copy from Altus Metrum AltOS

This commit is contained in:
2024-06-25 19:03:04 +02:00
commit 13fc49c923
2048 changed files with 1206748 additions and 0 deletions

3
ao-utils/Makefile.am Normal file
View File

@@ -0,0 +1,3 @@
dist_bin_SCRIPTS = ao-ejection
man_MANS = ao-ejection.1

64
ao-utils/ao-ejection Executable file
View File

@@ -0,0 +1,64 @@
#!/usr/bin/env nickle
void main () {
real R = 22.16 * 12; /* in lbf / lbm (gas constant for ffff powder */
real T = 3307; /* combustion temperature for BP */
real d_mm; /* diameter(mm) */
real l_mm; /* length(mm) */
real f_N; /* force(N) */
real f_lb;
real A_mm²; /* area of bulkhead (mm²) */
real A_in²;
real V_mm³; /* free volume (mm³) */
real V_in³;
real M_lb; /* mass of BP in lb */
real M_g;
real P_Nmm²; /* pressure (N/mm²) */
real P_lbin²; /* pressure (psi) */
if (dim(argv) != 4) {
File::fprintf(stderr,
"usage: %s diameter(mm) length(mm) force(N)\n",
argv[0]);
exit(1);
}
d_mm = string_to_real(argv[1]);
l_mm = string_to_real(argv[2]);
f_N = string_to_real(argv[3]);
f_lb = f_N * 0.22480894;
A_mm² = pi * (d_mm/2) ** 2;
V_mm³ = A_mm² * l_mm;
A_in² = A_mm² / (25.4**2);
V_in³ = V_mm³ / (25.4**3);
P_Nmm² = f_N / A_mm²;
P_lbin² = P_Nmm² * 0.22480894 * (25.4 ** 2);
M_lb = (P_lbin² * V_in³) / (R * T);
M_g = M_lb * 453.59237;
printf ("Input parameters:\n");
printf (" Diameter: %.1g (mm) %.3g (in)\n",
d_mm, d_mm / 25.4);
printf (" Length: %.1g (mm) %.3g (in)\n",
l_mm, l_mm / 25.4);
printf (" Force: %.1g (N) %.3g (lb)\n",
f_N, f_lb);
printf ("Chamber values:\n");
printf (" Area: %.0f (mm²) %.3g (in²)\n",
A_mm², A_in²);
printf (" Volume: %.0f (mm³) %.3g (in³)\n",
V_mm³, V_in³);
printf (" Pressure: %.2g (lb/in²) %.5g (N/mm²)\n",
P_lbin², P_Nmm²);
printf ("Results:\n");
printf (" FFFF powder: %.3g (g)\n", M_g);
}
main();

55
ao-utils/ao-ejection.1 Normal file
View File

@@ -0,0 +1,55 @@
.\"
.\" Copyright © 2009 Keith Packard <keithp@keithp.com>
.\"
.\" This program is free software; you can redistribute it and/or modify
.\" it under the terms of the GNU General Public License as published by
.\" the Free Software Foundation; either version 2 of the License, or
.\" (at your option) any later version.
.\"
.\" This program is distributed in the hope that it will be useful, but
.\" WITHOUT ANY WARRANTY; without even the implied warranty of
.\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
.\" General Public License for more details.
.\"
.\" You should have received a copy of the GNU General Public License along
.\" with this program; if not, write to the Free Software Foundation, Inc.,
.\" 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
.\"
.\"
.TH AO-EJECTION 1 "ao-ejection" ""
.SH NAME
ao-ejection \- Compute rocket ejection charges
.SH SYNOPSIS
.B "ao-ejection"
\fIdiameter(mm)\fP
\fIlength(mm)\fP
\fIforce(N)\fP
.SH DESCRIPTION
.I ao-ejection
computes the amount of black powder necessary to generate the desired
force to separate sections of a rocket airframe. It assumes a
cylindrical airspace covered by a circular cap. With that and the
force to be exerted on the cap,
.I ao-ejection
can compute the necessary pressure rise within the chamber, the volume
of gas necessary and finally the mass of BP to generate the gas.
.SH EXAMPLE
.nf
$ ao-ejection 54 300 500
Input parameters:
Diameter: 54.0 (mm) 2.126 (in)
Length: 300.0 (mm) 11.811 (in)
Force: 500.0 (N) 112.404 (lb)
Chamber values:
Area: 2290 (mm²) 3.550 (in²)
Volume: 687066 (mm³) 41.927 (in³)
Pressure: 31.66 (lb/in²) 0.21832 (N/mm²)
Results:
FFFF powder: 0.685 (g)
.fi
.P
This demonstrates that a 54mm airframe with a 300mm chamber
requires .685g of FFFF BP to generate 112lb of force on the end of the
chamber. This is usually sufficient to sever two 2x56 nylon screws.
.SH AUTHOR
Keith Packard