Main Content

nav.StateSampler Class

Namespace: nav

Create state sampler for path planning

Since R2023b

Description

The nav.StateSampler class is an interface for state samplers used in sampling-based path planners like plannerRRT, plannerRRTStar, plannerBiRRT, and plannerPRM. This representation allows for implementing sampling strategies on top of existing functions like sampleUniform and sampleGaussian available in the StateSpace interface.

To create a sample template for generating your own state sampler class, call createPlanningTemplate.

The nav.StateSampler class is a handle class.

Class Attributes

Abstract
true

For information on class attributes, see Class Attributes.

Creation

Description

sampler = nav.StateSampler(StateSpace) creates a state sampler object using the specified state space object.

Properties

expand all

State space definition, specified as an object of a subclass from nav.StateSpace class.

Attributes:

GetAccess
public
SetAccess
immutable

Methods

expand all

Extended Capabilities

C/C++ Code Generation
Generate C and C++ code using MATLAB® Coder™.

Version History

Introduced in R2023b