pwd
Returns the current working directory.
Syntax
R = pwd()
Outputs
- R
- Current working directory.
Example
Simple example:
cd('c:\tests')
R = pwd()
R = c:\tests
Discover new features and enhancements.
New to Activate? Learn the basics here.
Start using Activate with our interactive tutorials.
Learn about the components in Activate models.
Learn about modeling physical components.
Learn about modeling hydraulic systems with the Hydraulics (By Fluidon) library.
Learn about modeling electrical and electronic systems with Modelica and Spice.
Learn about modeling multibody dynamic systems.
Learn about modeling electromagnetic systems.
Learn how to set up, run, and troubleshoot simulations.
Discover options to review, display, and export results.
Learn about block libraries for building dynamic system models.
Explore the Extended Definitions, OML Guides, Block Library, API Guide and Glossary.
PDF file with in-depth information on key topics in the User's Guide.
OpenMatrix is a mathematical scripting language.
The Reference Guide contains documentation for all functions supported in the OpenMatrix language.
Returns R after copying file(s) or directories from src to dst.
Reads the values of a 2D matrix, R, from the file, f, where the values are comma-separated.
Writes the values of a 2D matrix, m, to the file, f, where the values are comma-separated.
Reads the values of a 2D matrix, R, from the file, f.
Writes the values of a 2D matrix, m, to the file, f.
Closes a file opened by fopen(). Requires the fileID returned by fopen as an argument.
Returns 1 if an end-of-file symbol is encountered.
Display the error status of fileID.
Flush buffered output to fileID to be written the file.
Reads the characters in a file until reaching request_length of characters read. Reads until a new line or end of file if request_length is not provided.
Reads the characters in a file until hitting len of characters read, a new line or end of file if len is not provided.
Returns the directory, name, and extension components of the file filepath.
Opens a file, filename, for read/write operations.
This function writes output to a file using the printf format_string capabilities. The first argument is a fileID returned from an earlier call to fopen.
Reads the binary data of the precision type from the file fileID.
Moves the file pointer to the beginning of the file fileID. Returns 0 on success.
Returns result R after reading a formatted data from file handle, f, specified by template t.
Sets the file pointer to a position in fileID. Returns 0 if successful; returns -1 if unsuccessful.
Returns the current position of the file pointer.
Returns a filename from dir1...dirN and filename fname.
Writes binary data to the file ID.
Gets information from the image, without reading pixel data, using functions defined in the omlimgtoolbox.
Returns result R after reading a file, f. Different reading mechanisms are used, based on the type of file, f.
Reads an image with the pixel data stored in a matrix R, with functions defined in the omlimgtoolbox.
Writes an image, whose pixel data comes from a matrix, m, with functions defined in the omlimgtoolbox.
Returns true if dir is a directory.
Returns true if the application is running on OSX.
Returns true if the application is running on a Windows operating system.
Returns true if the application is running on a Unix system.
Reads the content of a MAT file.
Returns the filename of the currently running script.
Displays or sets the character used to separate directories in the path.
Displays the string str to the Command window or Console prompt.
Returns the current working directory.
Updates a file name from oldname to newname. Returns 0 if successful and non-zero otherwise. An optional output argument, errormessage, can be used to retrieve any additional system error messages on failure.
Save variables into a MAT file.
Used in the fseek function to change the file position relative to the current file position.
Used in the fseek function to change the file position relative to the end of the file.
Used in the fseek function to change the file position relative to the beginning of the file.
Returns the file ID corresponding to the error stream.
Returns the numeric file ID corresponding to the standard input stream of the application console mode.
Returns the numeric file ID corresponding to the standard output stream of the application console mode.
Returns result R after reading a formatted data from a file, f, specified by an optional template, t.
Returns result R after reading a formatted data from a file stream \, f, or string, s.
Extracts file(s) from the archive, archive, and is defined in the omlziptoolbox.
Closes an Excel file opened through the command, xlsopen, and whose details are in data with functions defined in omlxlstoolbox. xlsclose is available only on Windows systems where Microsoft Excel is installed.
Provides information about Excel compatibility with the file, file, using omlxlstoolbox.
Opens an Excel compatible file, file, and stores the information in R using functions defined in omlxlstoolbox. xlsopen is available only on Windows systems where Microsoft Excel is installed.
Reads data, which is an Excel-compatible file or a structure returned from xlsopen, with functions defined in omlxlstoolbox. xlsread is available only on Windows systems where Microsoft Excel is installed.
Writes data to file, which is either an Excel-compatible file or a structure returned from xlsopen, with functions defined in omlxlstoolbox. xlswrite is available only on Windows systems where Microsoft Excel is installed.
Archives the file(s), files, and is defined in the omlziptoolbox.
Describes all of the blocks in the installed Activate library.
Key terms associated with the software.
Define shortcuts to common operations.
Explore the Extended Definitions, OML Guides, Block Library, API Guide and Glossary.
The Reference Guide contains documentation for all functions supported in the OpenMatrix language.
Returns the current working directory.
Returns the current working directory.
R = pwd()
Simple example:
cd('c:\tests')
R = pwd()
R = c:\tests
(c) Altair Engineering, Inc. All rights reserved.