How do you get explosive Temp?

  • Videogamer555
    21st Sep 2011 Member 0 Permalink
    As you can see here https://powdertoy.co.uk/Discussions/Thread/View.html?Thread=10493 I am making a program that sets various constants in TPT. Explosive temperature (the temperature of the flame that results from the detonation of C-4 for example) has eluded me. I can figure out explosive pressure, and various other temperatures. However the method used to derive the explosive temperature 922 degC has eluded me. Unlike other temperatures it is not stored in a single precision floating point constant. Please help me figure out how that 922 degC is calculated for explosives.
  • alecnotalex
    21st Sep 2011 Member 0 Permalink
    @Videogamer555 (View Post)
    I'm kind of sure that there is no variable or anything for that. I think changing the constant for fire will change the explosive temp. I'm not sure though.
  • plead-for-destruction
    21st Sep 2011 Member 0 Permalink
    @alecnotalex (View Post)
    but it uses a different constant
  • alecnotalex
    21st Sep 2011 Member 0 Permalink
    @plead-for-destruction (View Post)
    Then I guess I'm incorrect.

    @videogamer555 Completely disregard my above post.
  • Videogamer555
    21st Sep 2011 Member 0 Permalink
    Anyone have any idea on this?
  • jacobrb
    21st Sep 2011 Member 0 Permalink
    tpt is a bloody mysterious program, isnt it?
  • me4502
    21st Sep 2011 Member 0 Permalink
    @Videogamer555 (View Post)
    its not a constant

    you cant change it
  • Videogamer555
    22nd Sep 2011 Member 0 Permalink
    How is the temperature for burning C4 determined then? The equation must use some kind of constant.
  • BloodLust
    22nd Sep 2011 Member 0 Permalink
    Perhaps it is with the coding that makes it explode faster than the fire moves

    like with a good size blob of c4 when one pixel is lit it sets off a chunk of the c4 every frame instead of having the c4 become a pixel of fire and that pixel sets off the others touching it and so on 


  • jacksonmj
    22nd Sep 2011 Developer 0 Permalink
    The equation for fire temperature is:
    parts[r>>8].temp = ptypes[PT_FIRE].heat + (ptypes[rt].flammable/2)

    Some relevant constants:
    ptypes[PT_FIRE].heat = R_TEMP+400.0f+273.15f = 695.15
    ptypes[PT_C4].flammable = 1000; (stored as integer not float)

    Example:
    695.15+1000/2 = 1195.15 K = 922 deg C