MPMAS Tutorial ## Overview

Overview

The MPMAS/mpmasql suite of software tools facilitates the construction of farm-level optimization and farm-agent simulation models, in which mathematical programming – specifically mixed integer programming (MIP) – is used to represent the main production and investment decision problems of farming households.

This tutorial and manual gives an overview and introduces the key features of the MPMAS/mpmasql software package. It contains step-by-step tutorials for a quick start, examples for implementation patterns and a reference of the syntax features of the software.

1. Installation and technical architecture

Installation instructions for the MPMAS/mpmasql toolbox and the software packages themselves can be found on the MPMAS homepage.

An overview of the software components can be found in the first part of the file and syntax description.

We recommend to follow the subsequent tutorial chapters for a first introduction.

2. Farm-level MP optimization models

MPMAS is quite efficient at creating and solving large numbers of farm-level MP models for scenario and uncertainy analysis. In many cases, running an in depth analysis of static representative farm-level MP models can already go along way to answer agri-economic research questions.

Even if you are mainly interested in implementing an ABM, it is essential to familiarize yourself at least with the basic concepts of MP implementation in MPMAS first, since MP decision models also form an essential component of dynamic and agent-based models implemented in MPMAS.

3. Dynamic and spatial farm agent simulation models

Making plans is good, but reality might turn out differently and not everything can be planned for or known in advance. Decision-makers have to deal with uncertainty and with adapting original plans after observing first outcomes.

MPMAS/mpmasql has been specifically designed for the dynamic simulation of farms, i.e. simulating farm managers making a plan for a longer stretch of time, implementing the immediate actions, observing the outcomes, adapting their plan, implement some more actions, observe the outcomes, adapt the plan, and so forth.

Agent-agent and agent-environment interactions can be a key part of the dynamic evolution of farming populations – leading to full fledged agent-based models (ABMs).

Familiarize yourself with the MPMAS way of turning a static farm decision problem into a dynamic farm agent simulation model.

4. Coupling with biophysical models

In many applications, MPMAS has been integrated with biophysical simulation models such as crop growth models, agroecological landscape models, hydrological or livestock herd models. While many of these integrations originally relied on project-specific integration approaches, this experience has been refined into a generic coupling interface that now allows to flexibly couple MPMAS with external simulation models.

5. File, command and syntax reference