Skip to content

Soy Supply Sheds

View or edit on GitHub

This page is synchronized from trase/models/brazil/soy_supply_sheds/README.md. Last modified on 2026-06-20 06:32 CEST by GitHub Actions. Please view or edit the original file there; changes should be reflected here after a midnight build (CET time), or manually triggering it with a GitHub action (link).

Brazil soy supply sheds

This model identifies a supply shed—a set of geographic points or regions from which an entity sources its supply—for the soy sector in Brazil. Specifically, we are identifying supply sheds of storage infrastructure. Our plan for how this model should progress is in the Google Doc "Brazilian soy supply sheds".

Implementation

The model follows the workflow in the following diagram

Untitled Diagram drawio (7)

Soy is transported from municipalities of production to silos. These flows are computed using a first LP, called LP1. Maximum farm-silo distances are computed per region using transportation statistics from CONAB. Due to those distance cutoffs, it is possible that some municipalities are not within range of silos. In this case, their production is removed from the available production in the LP, and their destination is set to unknown.

Silos include "aggregator" silos from the list of facilities, and municipalities for which CNPJ numbers from the Bills of Lading point to soy storage activities with their CNAE codes.

The demand applied in LP1 for CNPJ silos is exactly the demand required to meet the exports.

For aggregator silo municipalities which are not also CNPJ silo municipalities, the demand is computed by allocating the share of the remaining production in proportion of the silo capacities.

In early versions of the model with short distance cutoffs that were applied nationally, demand was difficult to meet in some regions, and and iterative process whereby areas with deficit (i.e. unmet demand) in the LP solution had their aggregator silos demand reduced, and areas without deficit had their demand increased for the next iteration, until the deficit was acceptable. In the later versions of the model, this is not required, but the mechanics of iterative LP haven't been removed from the code as they may become necessary if the list of silos or the distance cutoffs are modified.

The solution of LP1 determines the supply sheds of aggregator and CNPJ silos: the municipalities of production and the quantities of soy that they supply to the silos.

The results of LP1 are stitched to the exports to solve the exports of soybeans.

The remaining volumes are sent to a second LP, called LP2, where they travel between the aggregator silos and crushing facilities or hubs. No distance cutoff is applied at this step. The amount of soybeans crushed in the crushing facilities is calculated using national statistics for crushing and the share of capacity of each facility. Note that the crushing capacity data used in the model is for 2022, but all other datasets are for 2023. The national soy balances from CONAB are hard-coded in the preparation file, and will have to be replace by a year-specific file to run other years.

Since the paths between aggregator silos and crushing facilities or hubs can be long, they are not always present in the cost matrix. Therefore, the LP with the initial demand is not exactly solvable, and an iterative process where areas with deficit (i.e. unmet demand) in the LP solution have their hub silos demand reduced, and areas without deficit have their hub demand increased for the next iteration, until the deficit is acceptable. Note that crushing demand is not modified in the iterations.

The solution of LP2 determines the supply sheds of crushing facilities and hubs: the aggregator silos and the quantities of soy that they supply to the crushing facilities and hubs.

The results of LP2 are stitched to the exports to solve the exports of crushed products.

The remaining volumes that were not matched to exports are the following: - unmatched production, which was not within range of aggregator/CNPJ silos, or which was not required by the LP1 solution; - soybeans in hubs and crushing products not matched to exports at the end of LP2, which are destined to either meet domestic demand or unknown exports (branches not solved in this model).

Solving these remaining volumes would require an additional step of LP, with supply at hubs/crushing facilities, and competing demand at ports for unknown exports and at domestic demand centers (to be defined).