API Reference#

This is the complete public API for MAPTOR.

Important

If a class, function, or module is not listed here, it’s an internal implementation detail and should not be used directly in your code.

The public API consists of only 5 modules that provide everything you need to define and solve optimal control problems.

Quick Start#

import maptor as mtor

# Define problem
problem = mtor.Problem("My Problem")

# Define variables and dynamics
t = problem.time()
x = problem.state("position")
u = problem.control("thrust")
problem.dynamics({x: u})
problem.minimize(u**2)

# Set mesh and solve
problem.mesh([5], [-1, 1])
solution = mtor.solve_fixed_mesh(problem)
solution.plot()

Main Package#

The primary MAPTOR interface with all public exports.

Problem Definition#

Classes for defining optimal control problems.

Solution Interface#

Classes for working with optimization results.

Solver Functions#

Functions for solving optimal control problems.

Exceptions#

Exception classes for error handling.