If I showed you a compound's chemical structure will you be able to tell if it can be used as an explosive or we can only know that by conducting chemical experiments?
3$\begingroup$ Some materials you wouldn't think of as explosive (depending on your background) are very explosive under the "right" (or very wrong) circumstances. $\endgroup$– Buck Thorn ♦Jun 22, 2019 at 19:39
$\begingroup$ As @BuckThorn pointed, it depends on the conditions in which the compound has been put and for unknown or new ones, you will have to experiment. There is no known (none to me atleast) way of telling whether something's explosive. $\endgroup$– user79161Jun 22, 2019 at 22:23
$\begingroup$ chemistry.stackexchange.com/questions/7587/… $\endgroup$– MithoronJun 22, 2019 at 22:45
$\begingroup$ Looks like more precise dupe of chemistry.stackexchange.com/questions/117195/… $\endgroup$– MithoronJun 22, 2019 at 22:45
1$\begingroup$ It's not like "no way"; no, there is a way, but it is far from absolute. $\endgroup$– Ivan NeretinJun 22, 2019 at 23:35
A compound, a mixture may explode under different conditions. As an example, for some of them it is heat, other require electric discharge or mecanical impact to decompose. There are classes of compounds with known examples of explosives (azides, picrates, fulminates) so one may infer new compounds within these classes equally might be explosives, too.
Among modern explosives, increasing the number of nitrogroups or / and increase of nitrogen content over other elements present is a theme, like octanitrocubanes. See the Klapötke group in Munich / Germany working on 5,5’-azotetrazolate salts, too.
(dihydrazinium 5,5’-azotetrazolate dihydrazinate, source)
In short, things are explosive if they contain lots of nitrogen. For example, C2N14 (1-diazidocarbamoyl 5-azidotetrazole) is highly explosive because of its high nitrogen content. This is because nitrogen gas is very stable, so when compounds release it, they also release a lot of energy. The nitro group is often found in explosives because of this and because it contains oxygen, which can react and oxidize the rest of the molecule.
We can also look at bond strength. For example, in peroxides the O-O bond is weak and can easily break, releasing reactive radicals. Many peroxides, such as ascaridole, are explosive.
Also, there are steric effects, which occur when parts of a molecule are close together. Nitrogen triiodide is explosive because its three iodine atoms are very close together and are under lots of strain.
There are many exceptions to these rules. For example, urea, despite containing nitrogen, is not explosive.
Being explosive is ill defined as context matters
Part of the issue with what is explosive is the context of the situation where the substance explodes. Flour (the sort used for making bread) is not normally thought of as an explosive, but serious explosions in four mills are known and easy to recreate in the lab (finely divided flour dispersed in air is an explosive mixture).
This illustrates that "being explosive" is not an entirely simple idea.
So, even if we stick to the narrower question of whether a single pure compound is explosive, it isn't always entirely clear what we mean.
Some classes of compounds are usually explosive. Azides and fulminates often are. Highly nitrated compounds often are, but then again, circumstances matter. Guncotton, for example, is highly nitrated cellulose. It has been used as a propellant in firearms (where it deflagrates–which is an explosion travelling slower than the speed of sound in the substance). early billiard balls made from it occasionally exploded with little provocation during normal play. But as a loosely aggregated ball of cotton or a thin film of paper, it doesn't explode, it just burns quickly.
The military explosive C-4 clearly is an explosive: armies use it as a demolition charge. But they have also been known to just burn it in the field to heat rations. It will explode but needs a good detonator to trigger that behaviour.
The point it that the situation and context matters for what will explode.
So, while there are many classes of compounds that are likely to be explosive in some contexts, it is a little hard to generalise. Highly nitrated compounds are often explosive but some will explode at the slightest provocation or when there is a full moon (like nitroglycerin); others need the right context (like TNT).
Many highly nitrogen rich compounds are explosive and highly nitrated, nitrogen rich compounds are in a class of their own And Derek Lowe explains in his "Things I Won't Work With" series talking about Hexanitrohexaazaisowurtzitane:
Hexanitro? Say what? I'd call for all the chemists who've ever worked with a hexanitro compound to raise their hands, but that might be assuming too much about the limb-to-chemist ratio. Nitro groups, as even people who've never taken a chemistry class know, can lead to firey booms, and putting six of them on one molecule can only lead to such.
So, while there are classes of compounds that are very likely to be dangerous and very likely to explode given their structure, there is a big grey area where compounds can be explosive in some contexts but not others and some where it is almost inevitable that they will be dangerous.
Thank goodness there are some people who are willing to do the experiments on this rather than you.