Main Content

Document Path Storage

When you create a requirements link, the RMI stores the location of the requirements document with the link. If you use selection-based linking or browse to select a requirements document, the RMI stores the document location as specified by the Document file reference option on the Requirements Settings dialog box, Selection Linking tab. The available settings are:

  • Absolute path

  • Path relative to current folder

  • Path relative to model folder

  • Filename only (on MATLAB path)

You can also manually enter an absolute or relative path for the document location. A relative path can be a partial path or no path at all, but you must specify the file name of the requirements document. If you use a relative path, the document is not constrained to a single location in the file system. With a relative path, the RMI resolves the exact location of the requirements document in this order:

  1. The software attempts to resolve the path relative to the current MATLAB® folder.

  2. When there is no path specification and the document is not in the current folder, the software uses the MATLAB search path to locate the file.

  3. If the RMI cannot locate the document relative to the current folder or the MATLAB search path, the RMI resolves the path relative to the model file folder.

The following examples illustrate the procedure for locating a requirements document.

Relative (Partial) Path Example

Current MATLAB folder

C:\work\scratch

Model file

C:\work\models\controllers\pid.mdl

Document link

..\reqs\pid.html

Documents searched for
(in order)

C:\work\reqs\pid.html
C:\work\models\reqs\pid.html

Relative (No) Path Example

Current MATLAB folder

C:\work\scratch

Model file

C:\work\models\controllers\pid.mdl

Requirements document

pid.html

Documents searched for
(in order)

C:\work\scratch\pid.html
<MATLAB path dir>\pid.html
C:\work\models\controllers\pid.html

Absolute Path Example

Current MATLAB folder

C:\work\scratch

Model file

C:\work\models\controllers\pid.mdl

Requirements document

C:\work\reqs\pid.html

Documents searched for

C:\work\reqs\pid.html