6.12 Vegetation Index Computation

In remote sensing, the Normalized Difference Vegetation Index (NDVI) is a widely used vegetation index, enabling users to quickly identify vegetated areas and monitor the growth and "condition" of plants.

Using Landsat TM imagery, the standard NDVI computation formula is: (TM4 - TM3) / (TM4 + TM3).

Example 6-14 Vegetation Index Computation

Example 6-14takes a Landsat 7 ETM+ image and computes the NDVI with parallelism. The result is stored as another raster of floating number data type. Note that in the GeoRaster algebra language, band numbering starts with 0, so the formula translates into the expression: ({3}-{2})/({3}+{2}).

DECLARE 
  geor1    SDO_GEORASTER; 
  geor2    SDO_GEORASTER; 
EBGIN
  -- Source ETM+ image
  select georaster into geor1 from georaster_table where georid = 2; 
  -- Store NDVI 
  select georaster into geor2 from georaster_table where georid = 3 for update; 
  sdo_geor_ra.rasterMathOp(geor1,
       SDO_STRING2_ARRAY('({3}-{2})/({3}+{2})'),
       'celldepth=32bit_real',geor2, null, null, ‘parallel=4’);
  update georaster_table set georaster = geor2 where georid = 3;
  commit;
end;
/

In addition to NDVI, there are many other vegetation indexes in the area of remote sensing. Many of these can be similarly computed using the GeoRaster raster algebra.