Assuming that warp core explosion will automatically "release" all the antimatter stored as fuel aboard the ship here some calculations:
(The Galaxy Class has thirty antimatter storage pods), each having a
volume capacity of 1,000 cubic meters. now, going from the
antihydrogen having the same mass as hydrogen, therefore weight, and
using a standard of storing it at -257.87 at 1 atmospheric pressure...
the weight of hydrogen in just one pod is 70,796 kilograms
Since the Intrepid class is much smaller compared to Galaxy class lets assume that there are like 5 storage pods.
When annihilated 5 antimatter storage pods will result in:
5 * (70796*2) * (300000000 * 300000000) = 63 716 400 000 000 000 000 000 joules
6.37164 * 10 ^ 22 joules
Assuming that the Intrepid class does not always have a "full tank" lets divide this by 2.
So this is around:
3.18582 * 10 ^ 22 joules
How much is this:
The explosion of the Little Boy atomic bomb is [estimated] (http://en.wikipedia.org/wiki/TNT_equivalent) to have a mass loss of
4.184×10 ^ 12 joules
so ignoring the antimatter in the photon torpedoes the released energy will be around equal to:
10 000 000 000 Little Boy atomic bombs
10^22 joules of energy is NOT that much on a planetary scale. The mass of the Earth is about 5.97219 × 10^24 kg so actually on the average this will be about 0.01 joules per kg - practically nothing.
Actual damage done from a 10^22 joules energy release depends mainly on the distance from the explosion to the planet. Assuming that it happens ON the surface then we have a good comparison point - the asteroid impact that is assumed to have caused the extinction of the dinosaurs is estimated to have released about 10^21 joules of energy (see Chicxulub Asteroid Impact).
Although the impact caused tremendous changes it did neither completely destroy the life on Earth, nor did it affect the planet itself. It left a 180 km wide crater though.
An antimatter explosion of the given scale will be much more focused compared to asteroid impact. However 74% of the released energy will be carried out by neutrinos which will just pass though the whole planet mass without being absorbed (see Antimatter Fuel). So we can safely assume that the antimatter explosion will cause less physical damage than an asteroid impact of the same magnitude.
Of course large amounts of radiation will be released - the gamma rays will cause lots of radioactive isotopes to be produced and spread in the atmosphere. I cannot give a good guess how much they will be but we have good proof that life can survive heavily irradiated places like in close vicinity to Chernobyl nuclear power plant.
So as a conclusion - an warp core breach ON the planet surface will likely cause lots of damage and dramatic changes in the ecosystem of the planet but is unlikely to cause complete eradication of life or any significant damage on planetary scale.
Second edit about the actual damage on the planet crust:
Taking Earth as an example (most data taken from Wikipedia article about Earth's crust)
- Earth's crust consists mainly from granite and basalt (mostly granite)
- The heat capacity of granite is 790 joules/kg (Specific heat solids). Heat capacity means how much energy does it take to increase the temperature of a certain material by 1 degrees Kelvin (or Celsius)
- Earth's crust is about 40 km thick (5 km at oceans - we'll go about that a bit later)
- The density of granite is 2750 kg/m^3
- The melting temperature of granite is 1260 degrees Celsius.
- We can assume that the average temperature of the crust is about 300 degrees Celsius - much lower close to the surface and up to 400 degrees closer to the mantle.
As I mentioned - only a fraction of the energy released will become "heat". As a start 74% of the energy will be carried away by neutrinos. From the remaining energy only about 35% will be converted to thermal energy (The Energy from a Nuclear Weapon ).
So applying these percentages we will remain at thermal energy of about:
2.899096 * 10 ^21 joules
To melt 1 cubic meter of basalt at starting temperature of 300 degrees Celsius we need about:
790 * 2600 * 960 = 2 085 600 000 = 2.0856 * 10 ^ 9 joules
So the thermal energy released from the blast will have the potential to melt around:
1.39 * 10 ^ 12 cubic meters of basalt
This sounds like a lot but is actually a cylinder that has a 6.6 km of diameter and is 40 km high.
So the blast has the potential to MELT a "hole" in the crust that is just 6.6 km wide. The real effect will actually look like a cone - a much larger area on the surface, but much smaller as we go down the crust. Just note that melting alone is not enough to break the crust. Major parts have to be evaporated. Evaporation of course takes again lot of energy.
The calculations will differ a little if the explosion happens in the ocean. Since the crust there is 10 times thinner there. So it is more likely that the crust gets broken there.
Still even there the "hole" in the crust will be relatively small and will not cause damage on planetary scale (like breaking apart the planet or significantly changing the orbit).