Profile Picture of Alex Kimani

My Atlas

~Alex Kimani

RUSLE (Revised Universal Soil Loss Equation)

The Revised Universal Soil Loss Equation (RUSLE) is a widely used model designed to estimate long-term average annual soil loss caused by sheet and rill erosion from rainfall and associated overland flow. It’s especially valuable in land use planning, conservation practices, and watershed management.

RUSLE Formula:

A = R × K × LS × C × P

  • R FACTOR / Rainfall Erosivity Factor

    The R factor quantifies the erosive force of rainfall based on the energy of raindrops and the rate of precipitation. It’s a key input in understanding how rainfall contributes to soil degradation.

    Data used: I used daily rainfall raster data for the year 2024 over the Machakos region, obtained from ClimateSERV. This platform provides satellite-based climate datasets suitable for spatial environmental analysis.

    Method: Using Python, I aggregated daily rasters into a cumulative rainfall erosivity layer. Libraries like rasterio and numpy enabled efficient raster processing.

    Formula used: Since I lacked 30-minute interval rainfall data (I30), I applied the empirical formula:
    R = ∑Pi²
    Where Pi represents daily rainfall in millimeters. This empirical alternative is widely used in African contexts when high-resolution temporal data is unavailable.

    Why this formula: The original RUSLE model requires high-frequency data, which was not available. This empirical method provided a reliable and spatially consistent estimate using available daily data.

    Alternative method – Kassam scenario: Some researchers apply monthly rainfall and interpolate values using IDW in QGIS, then apply empirical constants. Although viable, I focused on the daily raster approach for higher resolution and automation.

    Comparison with KMD map: I validated the R-factor results by comparing with the Kenya Meteorological Department (KMD) erosivity maps. Despite KMD using station-based datasets, there were notable spatial similarities.

  • K FACTOR / Soil Erodibility Factor

    The K factor describes the vulnerability of soil to erosion, influenced by its physical and chemical properties such as texture, organic matter, structure, and permeability.

    Data source: I used raster datasets from SoilGrids, which provide global coverage of soil properties in TIFF format suitable for GIS or Python-based analysis.

    Formula applied: I adopted the Williams et al. (2000) equation:

    K = fsand × fclay × forgC × fsilt × 0.1317

    Each factor represents how a specific soil property contributes to erodibility:

    • fsand: contribution of sand content
    • fclay: influence of clay content
    • forgC: role of organic carbon
    • fsilt: impact of silt and textural balance

    Why this method: I chose the Williams formula due to its compatibility with raster-based processing and its pixel-level estimation capabilities. The full coverage data from SoilGrids made this approach ideal.

    Alternative approach – Kassam scenario: The Kassam method is generally used when data is collected from different field stations. K values are calculated at specific stations and interpolated (e.g., IDW) across the study area. This method suits field-sampled datasets but is less effective with raster data. Since my data was continuous and gridded, the raster-based method proved more efficient.

    QGIS vs Python: While I initially attempted implementing the formula using QGIS's raster calculator, it proved cumbersome due to its limited formula flexibility. Python offered better control and efficiency for large raster datasets.

  • LS FACTOR / Slope Length and Steepness Factor

    The LS factor in the RUSLE model quantifies the impact of topography — specifically slope length and steepness — on soil erosion. It reflects how water accumulates and flows over a landscape, gaining erosive power as slope and contributing area increase.

    Data source used: I derived the LS factor using a Digital Elevation Model (DEM) with a resolution of 30 meters. From this DEM, I generated slope, flow direction, and flow accumulation rasters.

    Formula applied: I used the Moore and Burch (1986) equation, which is widely adopted for pixel-based LS factor estimation:

    LS = ((FlowAcc × CellSize) / 22.13)m × (sin(Slope) / 0.0896)n

    • FlowAcc: Flow accumulation raster (number of upslope contributing cells)
    • CellSize: Spatial resolution of DEM (e.g., 30m)
    • Slope: Terrain slope in degrees (converted to radians for the sine function)
    • m: Exponent typically between 0.4 and 0.6 depending on land characteristics (I used 0.4)
    • n: Slope exponent, commonly 1.3

    Software used: I implemented the LS factor calculation in Python using raster processing libraries for better control over mathematical operations and to automate the pixel-wise computation. Although QGIS can perform this analysis (especially using SAGA or GRASS tools like “LS Factor” or “Slope Length and Steepness”), I preferred Python for its reproducibility and flexibility in adjusting parameters.

    Alternative using QGIS: The LS factor can also be calculated entirely within QGIS without writing code. This is done by using SAGA or GRASS GIS toolsets integrated into QGIS. The typical steps include:

    1. Filling sinks in the DEM using SAGA > Fill Sinks (Wang & Liu).
    2. Generating a Flow Accumulation raster using SAGA > Flow Accumulation (Top-Down).
    3. Calculating the slope using QGIS > Raster > Analysis > Slope or SAGA > Slope, Aspect, Curvature.
    4. Finally, computing the LS factor using SAGA > LS Factor tool, which directly applies the Moore and Burch (1986) method.
    This alternative is ideal for users preferring a GUI workflow and integrates well with other QGIS geoprocessing tools. It provides fast visual feedback and doesn't require coding skills.

    Note: The LS factor is essential in erosion modeling as it amplifies the soil loss based on terrain characteristics. Areas with long, steep slopes will have a higher LS value, indicating greater erosion potential.

  • C FACTOR / Cover Management Factor

    The C Factor in the RUSLE model represents the effect of vegetation and land cover on soil erosion rates. It reflects the degree to which land cover—such as grass, shrubs, cropland, or built-up areas—protects the soil from the erosive power of rainfall and surface runoff.

    Approach used: I computed the C Factor by assigning values to each land cover class based on the Dynamic World classification from Google Earth Engine. Each class (e.g., water, cropland, grassland, etc.) was mapped to a corresponding C Factor value ranging from 0 (no erosion risk) to 1 (maximum erosion risk).

    Code Implementation: I wrote a Python script using rasterio and numpy to map LULC values to corresponding C Factor values and export the result as a raster. The script reads the LULC GeoTIFF, replaces each pixel value based on a predefined dictionary, and writes the new raster file to disk.

    Mapping of Dynamic World LULC codes to C values:

    • Water (0) → 0.0
    • Trees (1) → 0.002
    • Grass (2) → 0.025
    • Cropland (3) → 0.75
    • Shrub & Scrub (4) → 0.125
    • Built Area (5) → 0.0
    • Bare Ground (6) → 1.0
    • Snow & Ice (7) → 0.0
    • Clouds (8) → 0.0

    Validation and comparison: I verified the assigned values by inspecting individual areas in QGIS. The assigned C Factor values from Python matched those seen when manually inspecting the raster in QGIS, ensuring consistency across platforms.

    Documentation and supporting studies: While I used class-based assignment rather than NDVI, it’s important to note that many studies use NDVI to estimate the C Factor due to its dynamic representation of vegetation. For example, the study by Benjamin K. Kogo(2020) on Western Kenya explains that:

    “The C-factor accounts for the contribution of land cover towards soil loss and is thus an essential and dynamic element of the RUSLE model. The Normalized Difference Vegetation Index (NDVI) is used to estimate the C-factor because of its dynamic nature. The C-factor has an inverse relationship with NDVI and was computed using the equation:

    C = exp[-a × (NDVI / (β − NDVI))]
    where a = 2 and β = 1.”

    Why not NDVI? I chose not to use NDVI because the Dynamic World land cover classification already captures detailed land use information suitable for estimating the C Factor. This also avoided the need for complex satellite image preprocessing.

    Software used: The computation was done in Python for automation and reproducibility. I also cross-verified the output in QGIS using the Identify Features tool to check the C values of different areas such as cropland, built-up, grassland, and bare ground.

    Conclusion: The C Factor plays a crucial role in RUSLE modeling. Its accurate estimation ensures that vegetation’s protective role is well captured. In this analysis, both automated (Python) and manual (QGIS) checks confirmed the reliability of the generated C Factor raster.

⚠️ Documentation still in progress

Comparative Topographic Analysis of Mount Kenya Ascent Routes : why there is no established climbing route via ragati near Karatina University

The topographic map of the Mount Kenya region, created using QGIS and DEM data, compares four key ascent approaches: Chogoria, Naro Moru, Sirimon, and Ragati (near Karatina University). The aim is to understand why no formal climbing route exists via Ragati, despite its proximity to the mountain and academic institutions like Karatina University.

The map highlights elevation contours, straight-line distances, and slope intensity using QGIS-based terrain analysis. Routes were digitized and measured in Google Earth Pro, with slope derived from digital elevation models (DEMs).

Topographic map comparing Mount Kenya routes

Key findings include:

  • Steep terrain near Ragati: Tight contour spacing indicates steep ascents, especially in the upper elevations near the summit zone.
  • Longer route length: The straight-line distance from Ragati to the summit is around 30 km, compared to:
    • Chogoria Gate – 15.1 km
    • Naro Moru Gate – 18 km
    • Sirimon Gate – 18.6 km
  • Absence of infrastructure: Unlike the established routes, Ragati lacks ranger stations, foot trails, and support camps, making the area less viable for recreational or guided hiking.
  • Environmental and logistical challenges: Ragati’s terrain is densely forested and ecologically sensitive, presenting obstacles for route development and conservation management.

This analysis demonstrates that viable hiking routes depend not only on elevation, but also on distance, slope conditions, infrastructure, and environmental feasibility. Despite being geographically closer to Karatina University, Ragati remains an impractical entry point to Mount Kenya’s summit due to topographic and ecological limitations.

Ragati Forest topography and route distance map
Comparison of Mount Kenya ascent distances
Comparison of Mount Kenya ascent distances

June 2, 2025

Tools Used: QGIS | Google Earth Pro | DEM Terrain Analysis

Study Area: Ragati Forest and Mount Kenya

Affiliation: Karatina University – GIS Club

Irrigation Schemes of Kenya

This irrigation map of Kenya, created using QGIS, visualizes the spatial distribution of irrigation schemes across the country. The map displays point data representing individual irrigation schemes over a land cover background. These irrigation points are symbolized using uniform brown dots and are supported by a legend for interpretation. Key base layers include administrative boundaries, rivers, and elevation-shaded relief to offer spatial context.

Tree planting event at Ngong Hills, Kenya
Participants planting trees at Ngong Hills
Community members at Ngong Hills tree planting
Environmental restoration at Ngong Hills

Key findings include:

  • High concentration around Lake Victoria: Western Kenya shows a dense cluster of irrigation schemes, likely due to proximity to Lake Victoria, high rainfall, and fertile soils.
  • Significant presence around Mount Kenya: The central highlands near Mount Kenya also host many schemes, supported by mountain-fed rivers and productive volcanic soils.
  • Strong alignment along major rivers: A notable linear pattern of irrigation schemes follows River Tana, especially in the areas of Bura, indicating dependency on permanent water sources for irrigation.
  • Sparse distribution in arid regions: Northern and northeastern Kenya have noticeably fewer irrigation points, suggesting limitations due to aridity and lack of reliable water sources.

The map includes a locator inset, north arrow, and scale bar for geographic reference. It was developed using CSV point data and base maps such as OpenStreetMap and elevation raster. The insights derived help to understand water dependency, spatial planning, and agricultural infrastructure distribution across Kenya.

june 1,2025

Maji House

Maji House is the headquarters of the Ministry of Water, Sanitation and Irrigation in Kenya. Located in Nairobi, it serves as the central administrative hub for the Ministry’s operations and policy coordination. The Ministry is mandated with the development, management, and regulation of Kenya’s water resources and sanitation services, ensuring sustainable water supply, access to clean drinking water, enhanced sanitation infrastructure, and climate-resilient irrigation systems across the country.

Projects

1.Tree Planting at Ngong Hills

A large-scale tree planting exercise was conducted at Ngong Hills as part of a collaborative environmental restoration effort, led by the Ministry of Water, Sanitation and Irrigation in collaboration with the National Water Harvesting and Storage Authority (NWHSA), the Kenya Forest Service (KFS), and local community members.

Tree planting event at Ngong Hills, Kenya
Participants planting trees at Ngong Hills
Community members at Ngong Hills tree planting
Environmental restoration at Ngong Hills
Ngong Hills reforestation initiative
Ngong Hills reforestation initiative

May 27, 2025

Key highlights include:

  • Target: To grow 11,000 indigenous trees (e.g., acacia) to support Kenya’s goal of achieving 10% forest cover.
  • Collaborators:
    1. Ministry of Water, Sanitation and Irrigation
    2. National Water Harvesting and Storage Authority (NWHSA)
    3. Kenya Forest Service (KFS)
    4. Members of the local community
  • Location: Ngong Hills, a key highland area contributing to Nairobi’s catchment.
  • Purpose: Climate action through reforestation, carbon capture, and biodiversity restoration.

This experience offered hands-on insight into how coordinated efforts between government agencies and communities can yield tangible environmental benefits.

2. Muguga Primary School Project

A research-driven sanitation and water access initiative was conducted at Muguga Primary School as part of a collaborative effort under the National Irrigation Sector Investment Plan (NISIP), led by the Ministry of Water, Sanitation, and Irrigation, the Muguga Primary School administration, and local community stakeholders.

Ablution blocks at Muguga Primary School
Borehole drilling site at Muguga Primary School

may 22,2025

Key highlights include:

  • Construction of ablution blocks and ongoing borehole drilling to enhance sanitation, hygiene, and sustainable water supply for the school community.

  • Collaborators:
    1. Ministry of Water, Sanitation and Irrigation
    2. National Irrigation Sector Investment Plan (NISIP)
    3. Muguga Primary School administration
    4. Members of the local community
  • Location: Muguga Primary School, a rural educational institution in Kenya’s Kiambu County.
  • Purpose: Advance NISIP’s objectives of improving water access, sanitation infrastructure, and climate resilience, while supporting educational environments through research-informed interventions.
  • Role: Contributed to research by assisting with project documentation, monitoring implementation progress, and evaluating outcomes for sanitation and water reliability.

This initiative provided valuable insights into how research-guided collaborations between government, international partners, and communities can deliver sustainable sanitation and water solutions, aligning with national development and climate resilience goals.

Resources and Links:

Geology of Kenya

This geological map of Kenya, created using QGIS, visually represents the country’s diverse geological formations. The map categorizes Kenya’s geology into distinct units, each marked by a unique color and label in the legend. These units correspond to different rock types and geological periods, ranging from Precambrian (PC, pCm) to Quaternary (Qe, Qp, QT, Qv) rocks, as well as Jurassic (J, JC, JT, JTr), Cretaceous (K), Miocene (Mi), and Tertiary (T, Ti, TrP) formations. The map also includes water bodies (H2O) and sea areas (SEA).

Geological map of Kenya showing rock types and periods
Geological map of Africa highlighting Kenya

april 2,2025

Key features include:

  • Precambrian Rocks (PC, pCm): Predominantly in the western and central regions, indicating ancient basement rocks.
  • Quaternary Deposits (Qe, Qp, QT, Qv): Scattered across the country, often associated with volcanic activity and recent sedimentation, especially in the Rift Valley.
  • Jurassic and Cretaceous formations (J, JC, JT, JTr, K): Found in the eastern and coastal regions, reflecting sedimentary deposits from those periods.
  • Tertiary volcanic and sedimentary rocks (T, Ti, TrP, Mi): Prominent along the central Rift Valley and parts of northern Kenya, associated with volcanic activity and rifting during the Tertiary period.

The map includes a scale bar (0–500 km) for distance reference and a north arrow for orientation. It was adapted from the U.S. Geological Survey’s World Energy Project dataset, focusing on Kenya’s geological provinces and oil/gas field potential, with data projected in Mercator using QGIS for enhanced visualization.

Resources:

...