You are on page 1of 3

Problem 2: A high speed subsonic Boeing 707 airline is flying at a pressure altitude of 12 km.

A
pitot tube on the vertical tail measures a pressure of 29,600 Pa. At which Mach number is the
airplane flying? ( At 12 km, the pressure in a standard atmosphere is 19320 Pa).

1 1
=[1+ ( ) (2 )]
2

Value of a & b: between 0-0.8 since subsonic is at Mach number 0-0.8


Number of iteration: 30
where : P= standard atmosphere in Pa units

Po= pressure reading of pitot tube in Pa units


7
2
= = 5 = 1.4
2

M= Mach number

Analytical Solution:

29,600 1.4 1 1.41


=[1+ ( ) (2 )] 1.4
19,320 2

M= 0.805

Simplifying the equation for the program gives:


1 1
() = [1+ ( ) (2 )] = 0
2

The program for the problem is:

package regulafalsi2;
import java.util.Scanner;

public class RegulaFalsi2 {

public static void main(String[] args) {


// TODO code application logic here

Scanner input= new Scanner (System.in);

double Po,P,y,M,A,a,b,d1,d2,d3,fxa,fxb,c,fxc,fxd,xa,xb;
int n,i,j;
double weir [][]= new double [30][8];

System.out.println("Input the altitude in km at which the airplane is flying");


A=input.nextDouble();

Domagas|Faycan|Lopez|Umalla|Dacwag|Danigos|Degay,Z.|Gamboa|Piano|Ramos,E. Page 1
System.out.println(" At 12km, the pressure in a standard atmosphere is 19320 Pa");

System.out.println("Input the stagnation pressure reading of the Pitot tube in Pa");


Po=input.nextDouble();

System.out.print("Input the value of a:");


a=input.nextDouble();
System.out.print("Input the value of b:");
b=input.nextDouble();

System.out.print(" \n xa \t\t fxa\t\t b\t\tc\t fxb\t fxc\t fxd\n");

for(n=0; n<30; n++){


P=19320;
y=1.4;
d1=(1+((y-1)/2)*a*a);
d2=(1+((y-1)/2)*b*b);

fxa=((Po/P)-(Math.pow(d1,3.5)));
fxb=((Po/P)-(Math.pow(d2,3.5)));
xa= a*fxb;
xb=b*fxa;

c= ((xa-xb)/(fxb-fxa));
d3=(1+((y-1)/2)*c*c);
fxc=((Po/P)-(Math.pow(d3,3.5)));
fxd= fxa*fxb;

for (j=0; j<7; j++){

if (j==0){weir[n][j]=a;}
if (j==1){weir[n][j]=fxa;}
if (j==2){weir[n][j]=b;}
if (j==3){weir[n][j]=fxb;}
if (j==4){weir[n][j]=c;}
if (j==5){weir[n][j]=fxc;}
if (j==6){weir[n][j]=fxd;}

System.out.printf("%10.4f", weir[n][j]);
System.out.print(" ");
}

System.out.println(" ");
if(fxa*c>0){a=c;}
else {b=c;}
}}}

Domagas|Faycan|Lopez|Umalla|Dacwag|Danigos|Degay,Z.|Gamboa|Piano|Ramos,E. Page 2
The result of the program is:

The root of the problem (value of c), which is equivalent to 0.8051.

Mach number is 0.8051.

Domagas|Faycan|Lopez|Umalla|Dacwag|Danigos|Degay,Z.|Gamboa|Piano|Ramos,E. Page 3

You might also like