Octave 的 rref(简化行梯队形式)等效于 C++ API

Octave's rref (reduced row echelon form) equivalent in C++ API

本文关键字:API C++ rref Octave      更新时间:2023-10-16

我使用为Visual Studio 2008编译的Octave 3.6.1在C++中开发了一段代码。我的程序运行良好。现在,我必须在C++代码中使用rref(缩减行梯队形式),但我找不到任何等效的rref命令的C++实现。

在以下链接中,rref命令列在Octave的核心命令中:

http://octave.sourceforge.net/octave/overview.html

但是我在下面的Octave C++API中找不到任何等价于rref的类或方法:

http://octave.sourceforge.net/doxygen/html/annotated.html

如果你能帮我,我将不胜感激。

大多数Octave函数都是在Octave本身中实现的,不能作为C++方法使用。事实上,如果你尝试which rref(在Octave 3.8.2中),你会得到这样的东西:

octave-cli-3.8.2> man rref 
'rref' is a function from the file /usr/local/share/octave/3.8.2/m/linear-algebra/rref.m

它显示了实现它的.m文件。Octave手册中解释了如何在C++中使用这些函数。感兴趣的确切文档取决于你是在写oct函数,还是在写一个独立的程序,这从你的问题中是不清楚的。