C API: Reference#
GAUSS_Array#
GAUSS_ArrayAlias#
GAUSS_AssignFreeableArray#
26 Too many symbols.
91 Symbol name too long.
481 GAUSS assignment failed.
495 Workspace inactive or corrupt.
GAUSS_AssignFreeableMatrix#
GAUSS_CallProc#
GAUSS_CallProcFreeArgs#
GAUSS_CheckInterrupt#
PURPOSE |
Checks for a program interrupt request on a thread. |
FORMAT |
int GAUSS_CheckInterrupt( pthread_t tid ); ret = GAUSS_CheckInterrupt( tid ); |
INPUT |
tid thread id of thread to check. |
OUTPUT |
ret UTC time of request or 0 if there is no request. |
REMARKS |
If tid is 0, the total number of pending interrupts is returned. Interrupts are checked during certain I/O statements, not every instruction. The GAUSS language command CheckInterrupt can be used in a GAUSS program to check for interrupts and terminate if one is pending. CheckInterrupt; |
SEE ALSO |
GAUSS_SetInterrupt, GAUSS_ClearInterrupt, GAUSS_ClearInterrupts |
GAUSS_ClearGlobalInterrupt#
PURPOSE |
Clears a global interrupt request. |
FORMAT |
void GAUSS_ClearGlobalInterrupt( void); GAUSS_ClearGlobalInterrupt(); |
REMARKS |
This function will clear the global interrupt request. It must be called explicitly. |
SEE ALSO |
GAUSS_SetGlobalInterrupt, GAUSS_SetProgramInterrupt, GAUSS_SetWorkspaceInterrupt |
GAUSS_ClearInterrupt#
PURPOSE |
Clears a thread-specific interrupt request. |
FORMAT |
int GAUSS_ClearInterrupt( pthread_t tid ); ret = GAUSS_ClearInterrupt( tid ); |
INPUT |
tid thread id of thread. |
OUTPUT |
ret 0 if successful or 1 if there is no request found. |
REMARKS |
On most platforms, if tid is 0, all interrupt requests are cleared. On Windows, a pthread_t is a structure. On Windows, to clear all interrupts use: pthread_t nil = { NULL, 0 }; ret = GAUSS_ClearInterrupt(nil); Normally, this function is not necessary because the compiler and executer clear the requests when they terminate. |
SEE ALSO |
GAUSS_SetInterrupt, GAUSS_CheckInterrupt, GAUSS_ClearInterrupts |
GAUSS_ClearInterrupts#
PURPOSE |
Clears all thread-specific interrupt requests. |
FORMAT |
int GAUSS_ClearInterrupts( void ); ret = GAUSS_ClearInterrupts(); |
OUTPUT |
ret success flag, 0 if successful, otherwise: |
REMARKS |
Normally, this function is not necessary because the compiler and executer clear the requests when they terminate. |
SEE ALSO |
GAUSS_SetInterrupt, GAUSS_CheckInterrupt, GAUSS_ClearInterrupt |
GAUSS_ClearProgramInterrupt#
GAUSS_ClearWorkspaceInterrupt#
GAUSS_CompileExpression#
GAUSS_CompileFile#
GAUSS_CompileString#
GAUSS_CompileStringAsFile#
GAUSS_ComplexArray#
GAUSS_ComplexArrayAlias#
GAUSS_ComplexMatrix#
GAUSS_ComplexMatrixAlias#
GAUSS_CopyArgToArg#
GAUSS_CopyArgToArray#
GAUSS_CopyArgToMatrix#
GAUSS_CopyArgToString#
GAUSS_CopyArgToStringArray#
GAUSS_CopyArrayToArg#
GAUSS_CopyArrayToGlobal#
GAUSS_CopyGlobal#
GAUSS_CopyMatrixToArg#
GAUSS_CopyMatrixToGlobal#
GAUSS_CopyStringArrayToArg#
GAUSS_CopyStringArrayToGlobal#
GAUSS_CopyStringToArg#
GAUSS_CopyStringToGlobal#
GAUSS_CreateArgList#
GAUSS_CreateProgram#
GAUSS_CreateWorkspace#
GAUSS_DeleteArg#
GAUSS_ErrorText#
GAUSS_Execute#
GAUSS_ExecuteExpression#
GAUSS_FreeArgList#
GAUSS_FreeArray#
GAUSS_FreeMatrix#
GAUSS_FreeProgram#
GAUSS_FreeString#
GAUSS_FreeStringArray#
GAUSS_FreeWorkspace#
GAUSS_GetArgType#
GAUSS_GetArray#
GAUSS_GetArrayAndClear#
GAUSS_GetDouble#
GAUSS_GetError#
GAUSS_GetHome#
GAUSS_GetHomeVar#
GAUSS_GetLogFile#
GAUSS_GetLogStream#
GAUSS_GetMatrix#
GAUSS_GetMatrixAndClear#
GAUSS_GetMatrixInfo#
GAUSS_GetString#
GAUSS_GetStringArray#
GAUSS_CreateWorkspace#
GAUSS_DeleteArg#
GAUSS_ErrorText#
GAUSS_Execute#
GAUSS_ExecuteExpression#
GAUSS_FreeArgList#
GAUSS_FreeArray#
GAUSS_FreeMatrix#
GAUSS_FreeProgram#
GAUSS_FreeString#
GAUSS_FreeStringArray#
GAUSS_FreeWorkspace#
GAUSS_GetArgType#
GAUSS_GetArray#
GAUSS_GetArrayAndClear#
GAUSS_GetDouble#
GAUSS_GetError#
GAUSS_GetHome#
GAUSS_GetHomeVar#
GAUSS_GetLogFile#
GAUSS_GetLogStream#
GAUSS_GetMatrix#
GAUSS_GetMatrixAndClear#
GAUSS_GetMatrixInfo#
GAUSS_GetString#
GAUSS_GetStringArray#
GAUSS_GetSymbolType#
GAUSS_GetWorkspaceName#
GAUSS_HookFlushProgramOutput#
GAUSS_HookGetCursorPosition#
GAUSS_HookProgramErrorOutput#
GAUSS_HookProgramInputChar#
GAUSS_HookProgramInputCharBlocking#
GAUSS_HookProgramInputCheck#
GAUSS_HookProgramInputString#
GAUSS_HookProgramOutput#
GAUSS_Initialize#
PURPOSE |
Initializes the GAUSS Engine. |
FORMAT |
int GAUSS_Initialize( void ); ret = GAUSS_Initialize(); |
OUTPUT |
ret success flag, 0 if successful, otherwise: 85 Invalid file type. 482 GAUSS Engine already initialized. 483 Cannot determine home directory. 487 License expired. 488 Cannot stat file. 489 File has no execute permissions. 490 License manager initialization error. 491 License manager error. 492 Licensingfailure. |
REMARKS |
GAUSS_Initialize reads the configuration file.You need to call it once at the beginning of your application. If GAUSS_Initialize fails, you should terminate your application. Call GAUSS_SetHome or GAUSS_SetHomeVar before calling GAUSS_Initialize. |
SEE ALSO |
GAUSS_SetHome, GAUSS_SetHomeVar, GAUSS_Shutdown |
GAUSS_InsertArg#
GAUSS_IsMissingValue#
GAUSS_LoadCompiledBuffer#
GAUSS_LoadCompiledFile#
GAUSS_LoadWorkspace#
GAUSS_MakePathAbsolute#
GAUSS_Matrix#
GAUSS_MatrixAlias#
GAUSS_MissingValue#
PURPOSE |
Returns a GAUSS missing value. |
FORMAT |
double GAUSS_MissingValue( void ); miss = GAUSS_MissingValue(); |
OUTPUT |
miss GAUSS missing value. |
SEE ALSO |
GAUSS_IsMissingValue |
GAUSS_MoveArgToArg#
GAUSS_MoveArgToArray#
args pointer to an argument list structure.
argnum number of argument in the argument list.
GAUSS_MoveArgToMatrix#
GAUSS_MoveArgToString#
GAUSS_MoveArgToStringArray#
GAUSS_MoveArrayToArg#
GAUSS_MoveArrayToGlobal#
GAUSS_MoveMatrixToArg#
GAUSS_MoveMatrixToGlobal#
GAUSS_MoveStringArrayToArg#
GAUSS_MoveStringArrayToGlobal#
GAUSS_MoveStringToArg#
GAUSS_MoveStringToGlobal#
GAUSS_ProgramErrorOutput#
GAUSS_ProgramInputString#
GAUSS_ProgramOutput#
GAUSS_PutDouble#
GAUSS_PutDoubleInArg#
GAUSS_SaveProgram#
GAUSS_SaveWorkspace#
GAUSS_SetError#
PURPOSE |
Sets the stored error number and returns the previous error number. |
FORMAT |
int GAUSS_SetError( int newerrnum ); olderrnum = GAUSS_SetError( newerrnum ); |
INPUT |
newerrnum new error number. |
OUTPUT |
olderrnum previous error number. |
REMARKS |
The GAUSS Engine stores the error number of the most recently encountered error in a system variable. If a GAUSS Engine command fails, it automatically resets this variable with the number of the error. However, the command does not clear the variable if it succeeds. Use GAUSS_SetError to manually reset the variable. It returns the error number that was previously stored in the variable. The system variable is global to the current thread. |
SEE ALSO |
GAUSS_GetError, GAUSS_ErrorText |
GAUSS_SetGlobalInterrupt#
PURPOSE |
Sets a global interrupt request. |
FORMAT |
void GAUSS_SetGlobalInterrupt( void ); GAUSS_SetGlobalInterrupt(); GAUSS_SetHome |
REMARKS |
This affects all threads in all programs in all workspaces, including child threads spawned by a GAUSS program. This interrupt must be explicitly cleared using GAUSS_ClearGlobalInterrupt. Interrupts are checked after assignments and in certain I/O statements, not every instruction. The GAUSS language command CheckInterrupt can be used in a GAUSS program to check for interrupts and terminate if one is pending. CheckInterrupt; |
SEE ALSO |
GAUSS_SetProgramInterrupt, GAUSS_SetWorkspaceInterrupt, GAUSS_ClearGlobalInterrupt |
GAUSS_SetHome#
GAUSS_SetHomeVar#
GAUSS_SetInterrupt#
PURPOSE |
Sets an interrupt request on a thread. |
FORMAT |
int GAUSS_SetInterrupt( pthread_t tid ); ret = GAUSS_SetInterrupt( tid ); |
INPUT |
tid thread id of thread to interrupt. |
OUTPUT |
ret success code, ≥ 0 if successful. |
REMARKS |
This affects only the thread specified. If the GAUSS program spawns threads the main program will wait until all the child threads have finished. Use GAUSS_SetProgramInterrupt() or GAUSS_SetWorkspaceInterrupt() instead. In general, this command should be considered obsolete. If ret is 0, the interrupt request is successful. The program or compile may not stop immediately. If the program is executing an intrinsic function on a large matrix, such an an inverse or matrix multiply, the operation will continue until it is finished and the program will stop at the next instruction. If ret is greater than 0, the interrupt is already requested and ret is the UTC time of the original request. If ret is -1, the system is out of memory. If ret is -2, the Engine is shutdown and the interrupt request has been ignored. Interrupts are checked during certainI/Ostatements, not every instruction. The GAUSS language command CheckInterrupt can be used in a GAUSS program to check for interrupts and terminate if one is pending. CheckInterrupt; |
SEE ALSO |
GAUSS_SetGlobalInterrupt, GAUSS_SetProgramInterrupt, GAUSS_SetWorkspaceInterrupt, GAUSS_CheckInterrupt, GAUSS_ClearInterrupt |
GAUSS_SetProgramInterrupt#
GAUSS_SetWorkspaceInterrupt#
GAUSS_SetLogFile#
GAUSS_SetLogStream#
GAUSS_SetWorkspaceName#
GAUSS_Shutdown#
PURPOSE |
Shuts down the GAUSS Engine, preparatory to ending the application. |
FORMAT |
void GAUSS_Shutdown( void ); GAUSS_Shutdown(); |
REMARKS |
GAUSS_Shutdown cleans up any temporary files generated by the GAUSS Engine. It also closes any dynamic libraries used by the foreign language interface. You should call it once at the close of your application after freeing any open pointers. |
SEE ALSO |
GAUSS_Initialize |