Aerodynamics in SFS

Fwgunner

Project Builder
Air density formula:
ρ(h) = ρ0 * exp(-curve * h/h_max) - ρ0 * exp(-curve)

And this is what i found experimentally:
v=53,7541*ρ^(-0,2457)
v: velocity
ρ: air density

What this empirical formula says that if your rocket is at a point where air density equals to ρ, rocket will heat. For instance, lets say our rocket is at the height of 5 km. According to the air density formula, density at 5 km is 0,000944. We will use this density value in the empirical formula i found.
v=53,7541*0,000944^(-0,2457)=297,6m/s. So it means that my rocket will start heating at the velocity of 297,6m/s, if the rocket is 5 km above the ground level.
 

Fwgunner

Project Builder
Air density formula:
ρ(h) = ρ0 * exp(-curve * h/h_max) - ρ0 * exp(-curve)

And this is what i found experimentally:
v=53,7541*ρ^(-0,2457)
v: velocity
ρ: air density

What this empirical formula says that if your rocket is at a point where air density equals to ρ, rocket will heat. For instance, lets say our rocket is at the height of 5 km. According to the air density formula, density at 5 km is 0,000944. We will use this density value in the empirical formula i found.
v=53,7541*0,000944^(-0,2457)=297,6m/s. So it means that my rocket will start heating at the velocity of 297,6m/s, if the rocket is 5 km above the ground level.
I forgot to replace first sentence. It actually starts with "I'll explain the formula with an example. Lets say our rocket is...
 

Fwgunner

Project Builder
Altaïr Its me again. I have 2 questions.
Question 1: When there is atmospheric drag, is there another force that effects rocket while engines on? I can simulate lift-off and re-entry separately with no atmospheric drag wight highly accurate results.. Also, I can simulate free fall and get highly accurate results as well when engines off. But when simulate lift-off and re-entry and atmospheric drag included, simulation fails and gets into an infinite loop, because it seems like drag becomes too high and math isnt mathing anymore.
Yellow: drag
Orange: thrust
Blue: gravity

1720036998801.jpg

Apparently, drag drastically overcame thrust and gravity.

Formulas I used:
thrust=T/W*9.8

g=-g0/(1+h/R)^2

rho=rho0*(exp(-curve*h/hmax)-exp(-curve))
F=1/2*C*rho*A*v^2
drag=F/W*9.8

Question 2: Is there a formula that gives you the maximum velocity that rocket experiences without temperature rise for a specific altitude or air density. Its important to prevent rocket from temperature rise in the re-entry stage.
 

Axiom

The Didact
Recruit
Under Pressure
Swingin' on a Star
Atlas
Question 2: Is there a formula that gives you the maximum velocity that rocket experiences without temperature rise for a specific altitude or air density. Its important to prevent rocket from temperature rise in the re-entry stage.
finally a question I can answer
So that is determined by the min heating multipler of the planet. The default is 1 where the minimum velocity needed to trigger aerodynamic heating is 250m/s. The multiplier multiplied that value
 

Fwgunner

Project Builder
finally a question I can answer
So that is determined by the min heating multipler of the planet. The default is 1 where the minimum velocity needed to trigger aerodynamic heating is 250m/s. The multiplier multiplied that value
I did too many test and noted every velocity that caused temperature rise at that altitude and created an empirical formula.

a1=1.6743e+04;b1=3.1148e+04;c1=3.5120e+03;
a2=-1.6125e+03;b2=2.8305e+04;c2=1.5836e+03;
a3=-2.9570e+03;b3=2.7943e+04;c3=2.3925e+03;
a4=0;b4=2.6845e+04;c4=28.8564;
a5=-1.2482e+04;b5=3.0441e+04;c5=1.9674e+03;
a6=341.1624;b6=2.5640e+04;c6=1.3938e+04;

v_reentry=a1*exp(-((h-b1)/c1)^2)+a2*exp(-((h-b2)/c2)^2)+a3*exp(-((h-b3)/c3)^2)+a4*exp(-((h-b4)/c4)^2)+a5*exp(-((h-b5)/c5)^2)+a6*exp(-((h-b6)/c6)^2);

Blue: my formula
Orange: experimental data
1720040017406.png


According to what you said, velocity should be constant and equal to 250, right? And while i run the tests, also i noticed that if altitude is lower than something like 17.5km, velocity is consant and equal to 250.3 which is exactly what you said but if altitude is above 17.5km, velocity increases as altitude increases.
 

Fwgunner

Project Builder
finally a question I can answer
So that is determined by the min heating multipler of the planet. The default is 1 where the minimum velocity needed to trigger aerodynamic heating is 250m/s. The multiplier multiplied that value
i got you wrong though. You didnt say its constant
 

Axiom

The Didact
Recruit
Under Pressure
Swingin' on a Star
Atlas
I did too many test and noted every velocity that caused temperature rise at that altitude and created an empirical formula.

a1=1.6743e+04;b1=3.1148e+04;c1=3.5120e+03;
a2=-1.6125e+03;b2=2.8305e+04;c2=1.5836e+03;
a3=-2.9570e+03;b3=2.7943e+04;c3=2.3925e+03;
a4=0;b4=2.6845e+04;c4=28.8564;
a5=-1.2482e+04;b5=3.0441e+04;c5=1.9674e+03;
a6=341.1624;b6=2.5640e+04;c6=1.3938e+04;

v_reentry=a1*exp(-((h-b1)/c1)^2)+a2*exp(-((h-b2)/c2)^2)+a3*exp(-((h-b3)/c3)^2)+a4*exp(-((h-b4)/c4)^2)+a5*exp(-((h-b5)/c5)^2)+a6*exp(-((h-b6)/c6)^2);

Blue: my formula
Orange: experimental data
View attachment 121685

According to what you said, velocity should be constant and equal to 250, right? And while i run the tests, also i noticed that if altitude is lower than something like 17.5km, velocity is consant and equal to 250.3 which is exactly what you said but if altitude is above 17.5km, velocity increases as altitude increases.
That's... odd
Do you track when the heating starts (like reaches 1 degree C) or when it destroys a part?
 

Altaïr

Space Stig, Master of gravity
Staff member
Head Moderator
Moderator
Veteran
Modder
Deja Vu
Under Pressure
Atlas
Forum Legend
From what I remember, in addition to the min heating velocity, there's also a cooling process, which is what allows the temperature to go down over time. I don't remember exactly how it works, but the fact that what you measured was not constant could come from this: as long as the cooling process is stronger than the heating, the ship won't start heating.
 

Fwgunner

Project Builder
From what I remember, in addition to the min heating velocity, there's also a cooling process, which is what allows the temperature to go down over time. I don't remember exactly how it works, but the fact that what you measured was not constant could come from this: as long as the cooling process is stronger than the heating, the ship won't start heating.
That make sense. And do you have any idea about the first question?
 

Altaïr

Space Stig, Master of gravity
Staff member
Head Moderator
Moderator
Veteran
Modder
Deja Vu
Under Pressure
Atlas
Forum Legend
Question 1: When there is atmospheric drag, is there another force that effects rocket while engines on? I can simulate lift-off and re-entry separately with no atmospheric drag wight highly accurate results.. Also, I can simulate free fall and get highly accurate results as well when engines off. But when simulate lift-off and re-entry and atmospheric drag included, simulation fails and gets into an infinite loop, because it seems like drag becomes too high and math isnt mathing anymore.
Not as far as I know, what do you mean by "math isn't mathing anymore"?
 

Fwgunner

Project Builder
Not as far as I know, what do you mean by "math isn't mathing anymore"?
Then the problem comes from my code. Although, i've checked it many times and couldnt find anything wrong.

And about the math isnt mathing part, if you've never heard of it, its some kind of a slang i heard on internet
 

Altaïr

Space Stig, Master of gravity
Staff member
Head Moderator
Moderator
Veteran
Modder
Deja Vu
Under Pressure
Atlas
Forum Legend
Then the problem comes from my code. Although, i've checked it many times and couldnt find anything wrong.
Maybe some sort of numerical instability, it's a typical cause of divergence in extreme situations. For example, what's called catastrophic cancellation, when you substract two quantities that are closed to eachother, but normally not equal. Because of numerical imprecision the result happens to be evaluated to 0. If this quantity is at the denominator in a larger calculation you can expect some really weird things.
Just to illustrate the principle, if you calculate:
(1 + 10^(-15)) - 1
You will obtain 0.
Maybe something like that happens?


And about the math isnt mathing part, if you've never heard of it, its some kind of a slang i heard on internet
Oh ok thanks. It's about me being french and not englishing then :p
 

Fwgunner

Project Builder
Maybe some sort of numerical instability, it's a typical cause of divergence in extreme situations. For example, what's called catastrophic cancellation, when you substract two quantities that are closed to eachother, but normally not equal. Because of numerical imprecision the result happens to be evaluated to 0. If this quantity is at the denominator in a larger calculation you can expect some really weird things.
Just to illustrate the principle, if you calculate:
(1 + 10^(-15)) - 1
You will obtain 0.
Maybe something like that happens?
i keep results for each time interval and it shows that drag is unnecessarily high :(

Oh ok thanks. It's about me being french and not englishing then :p
You got the point :D