Mercurial > octave
annotate doc/interpreter/numbers.txi @ 24534:194eb4bd202b
maint: Update punctuation for GPL v3 license text.
* COPYING, Makefile.am, README,
bootstrap, bootstrap.conf, OctJavaQry.java, changelog.tmpl,
check-subst-vars.in.sh, find-defun-files.sh, find-files-with-tests.sh,
get-source-mtime.sh, mk-hg-id.sh, mk-octave-config-h.sh, mk-opts.pl,
stl_algo.h-fixed, subst-config-vals.in.sh, subst-cross-config-vals.in.sh,
subst-default-vals.in.sh, subst-script-vals.in.sh, configure.ac,
Doxyfile.in, arith.txi, audio.txi, basics.txi, bugs.txi, config-images.sh,
container.txi, cp-idx.txi, data.txi, debug.txi, diagperm.txi, diffeq.txi,
add_to_aspell_dict, mk_undocumented_list, spellcheck, errors.txi, eval.txi,
expr.txi, external.txi, fn-idx.txi, func.txi, genpropdoc.m, geometry.txi,
geometryimages.m, grammar.txi, gui.txi, image.txi, images.awk, install.txi,
interp.txi, interpimages.m, intro.txi, io.txi, linalg.txi, macros.texi,
matrix.txi, mk-doc-cache.pl, mkcontrib.awk, mkoctfile.1, munge-texi.pl,
nonlin.txi, numbers.txi, obsolete.txi, octave-cli.1, octave-config.1, octave.1,
octave.css, octave.texi, oop.txi, op-idx.txi, optim.txi, package.txi, plot.txi,
plotimages.m, poly.txi, preface.txi, quad.txi, set.txi, signal.txi, sparse.txi,
sparseimages.m, splineimages.m, stats.txi, stmt.txi, strings.txi, system.txi,
testfun.txi, var.txi, vectorize.txi, array.texi, bugs.texi, cp-idx.texi,
dae.texi, diffeq.texi, error.texi, factor.texi, fn-idx.texi, gpl.texi,
install.texi, intro.texi, liboctave.texi, matvec.texi, nleqn.texi, nlfunc.texi,
ode.texi, optim.texi, preface.texi, quad.texi, range.texi, refcard-a4.tex,
refcard-legal.tex, refcard-letter.tex, refcard.tex, HACKING.md,
octave.appdata.xml.in, Backend.cc, Backend.h, BaseControl.cc, BaseControl.h,
ButtonControl.cc, ButtonControl.h, ButtonGroup.cc, ButtonGroup.h, Canvas.cc,
Canvas.h, CheckBoxControl.cc, CheckBoxControl.h, Container.cc, Container.h,
ContextMenu.cc, ContextMenu.h, EditControl.cc, EditControl.h, Figure.cc,
Figure.h, FigureWindow.cc, FigureWindow.h, GLCanvas.cc, GLCanvas.h,
GenericEventNotify.h, KeyMap.cc, KeyMap.h, ListBoxControl.cc, ListBoxControl.h,
Logger.cc, Logger.h, Menu.cc, Menu.h, MenuContainer.h, MouseModeActionGroup.cc,
MouseModeActionGroup.h, Object.cc, Object.h, ObjectFactory.cc, ObjectFactory.h,
ObjectProxy.cc, ObjectProxy.h, Panel.cc, Panel.h, PopupMenuControl.cc,
PopupMenuControl.h, PushButtonControl.cc, PushButtonControl.h, PushTool.cc,
PushTool.h, QtHandlesUtils.cc, QtHandlesUtils.h, RadioButtonControl.cc,
RadioButtonControl.h, SliderControl.cc, SliderControl.h, TextControl.cc,
TextControl.h, TextEdit.cc, TextEdit.h, ToggleButtonControl.cc,
ToggleButtonControl.h, ToggleTool.cc, ToggleTool.h, ToolBar.cc, ToolBar.h,
ToolBarButton.cc, ToolBarButton.h, __init_qt__.cc, __init_qt__.h,
annotation-dialog.cc, annotation-dialog.h, gl-select.cc, gl-select.h,
liboctgui-build-info.h, liboctgui-build-info.in.cc,
mk-default-qt-settings.in.sh, QTerminal.cc, QTerminal.h, BlockArray.cpp,
BlockArray.h, Character.h, CharacterColor.h, Emulation.cpp, Emulation.h,
Filter.cpp, Filter.h, History.cpp, History.h, KeyboardTranslator.cpp,
KeyboardTranslator.h, QUnixTerminalImpl.cpp, QUnixTerminalImpl.h, Screen.cpp,
Screen.h, ScreenWindow.cpp, ScreenWindow.h, SelfListener.cpp, SelfListener.h,
TerminalCharacterDecoder.cpp, TerminalCharacterDecoder.h, TerminalModel.cpp,
TerminalModel.h, TerminalView.cpp, TerminalView.h, Vt102Emulation.cpp,
Vt102Emulation.h, kpty.cpp, kpty.h, kpty_p.h, QTerminalColors.cpp,
QTerminalColors.h, QWinTerminalImpl.cpp, QWinTerminalImpl.h, main.cpp,
color-picker.cc, color-picker.h, dialog.cc, dialog.h,
documentation-dock-widget.cc, documentation-dock-widget.h,
external-editor-interface.cc, external-editor-interface.h,
files-dock-widget.cc, files-dock-widget.h, find-files-dialog.cc,
find-files-dialog.h, find-files-model.cc, find-files-model.h,
history-dock-widget.cc, history-dock-widget.h, file-editor-interface.h,
file-editor-tab.cc, file-editor-tab.h, file-editor.cc, file-editor.h,
find-dialog.cc, find-dialog.h, marker.cc, marker.h, octave-qscintilla.cc,
octave-qscintilla.h, octave-txt-lexer.cc, octave-txt-lexer.h, main-window.cc,
main-window.h, octave-cmd.cc, octave-cmd.h, octave-dock-widget.cc,
octave-dock-widget.h, octave-gui.cc, octave-gui.h, octave-qt-link.cc,
octave-qt-link.h, octave-settings.h, texinfo-parser.cc, texinfo-parser.h,
webinfo.cc, webinfo.h, resource-manager.cc, resource-manager.h,
settings-dialog.cc, settings-dialog.h, shortcut-manager.cc, shortcut-manager.h,
terminal-dock-widget.cc, terminal-dock-widget.h, thread-manager.cc,
thread-manager.h, variable-editor-model.cc, variable-editor-model.h,
variable-editor.cc, variable-editor.h, welcome-wizard.cc, welcome-wizard.h,
workspace-model.cc, workspace-model.h, workspace-view.cc, workspace-view.h,
build-env.h, build-env.in.cc, builtins.h, Cell.cc, Cell.h, __contourc__.cc,
__dsearchn__.cc, __ichol__.cc, __ilu__.cc, __lin_interpn__.cc, __luinc__.cc,
__magick_read__.cc, __pchip_deriv__.cc, __qp__.cc, balance.cc,
base-text-renderer.h, besselj.cc, betainc.cc, bitfcns.cc, bsxfun.cc,
c-file-ptr-stream.cc, c-file-ptr-stream.h, call-stack.cc, call-stack.h,
cdisplay.c, cdisplay.h, cellfun.cc, coct-hdf5-types.c, colloc.cc, conv2.cc,
daspk.cc, dasrt.cc, dassl.cc, data.cc, data.h, debug.cc, default-defs.in.h,
defaults.cc, defaults.h, defun-dld.h, defun-int.h, defun.cc, defun.h, det.cc,
dirfns.cc, dirfns.h, display.cc, display.h, dlmread.cc, dot.cc, dynamic-ld.cc,
dynamic-ld.h, eig.cc, ellipj.cc, environment.cc, environment.h, error.cc,
error.h, errwarn.cc, errwarn.h, event-queue.cc, event-queue.h, fcn-info.cc,
fcn-info.h, fft.cc, fft2.cc, fftn.cc, file-io.cc, file-io.h, filter.cc,
find.cc, ft-text-renderer.cc, ft-text-renderer.h, gammainc.cc, gcd.cc,
genprops.awk, getgrent.cc, getpwent.cc, getrusage.cc, givens.cc, gl-render.cc,
gl-render.h, gl2ps-print.cc, gl2ps-print.h, graphics-handle.h,
graphics-toolkit.cc, graphics-toolkit.h, graphics.cc, graphics.in.h, gripes.cc,
gripes.h, gsvd.cc, gtk-manager.cc, gtk-manager.h, hash.cc, help.cc, help.h,
hess.cc, hex2num.cc, hook-fcn.cc, hook-fcn.h, input.cc, input.h,
interpreter-private.cc, interpreter-private.h, interpreter.cc, interpreter.h,
inv.cc, kron.cc, load-path.cc, load-path.h, load-save.cc, load-save.h,
lookup.cc, ls-ascii-helper.cc, ls-ascii-helper.h, ls-hdf5.cc, ls-hdf5.h,
ls-mat-ascii.cc, ls-mat-ascii.h, ls-mat4.cc, ls-mat4.h, ls-mat5.cc, ls-mat5.h,
ls-oct-binary.cc, ls-oct-binary.h, ls-oct-text.cc, ls-oct-text.h, ls-utils.cc,
ls-utils.h, lsode.cc, lu.cc, mappers.cc, matrix_type.cc, max.cc, mex.cc, mex.h,
mexproto.h, mgorth.cc, mk-errno-list.sh, mk-mxarray-h.in.sh, mxarray.in.h,
nproc.cc, oct-errno.h, oct-errno.in.cc, oct-fstrm.cc, oct-fstrm.h,
oct-handle.h, oct-hdf5-types.cc, oct-hdf5-types.h, oct-hdf5.h, oct-hist.cc,
oct-hist.h, oct-iostrm.cc, oct-iostrm.h, oct-map.cc, oct-map.h, oct-obj.h,
oct-opengl.h, oct-prcstrm.cc, oct-prcstrm.h, oct-procbuf.cc, oct-procbuf.h,
oct-stdstrm.h, oct-stream.cc, oct-stream.h, oct-strstrm.cc, oct-strstrm.h,
oct-tex-lexer.in.ll, oct-tex-parser.in.yy, oct.h, octave-default-image.h,
octave-link.cc, octave-link.h, ordschur.cc, pager.cc, pager.h, pinv.cc,
pr-output.cc, pr-output.h, procstream.cc, procstream.h, psi.cc, quad.cc,
quadcc.cc, qz.cc, rand.cc, rcond.cc, regexp.cc, schur.cc, sighandlers.cc,
sighandlers.h, sparse-xdiv.cc, sparse-xdiv.h, sparse-xpow.cc, sparse-xpow.h,
sparse.cc, spparms.cc, sqrtm.cc, str2double.cc, strfind.cc, strfns.cc,
sub2ind.cc, svd.cc, sylvester.cc, symrec.cc, symrec.h, symscope.cc, symscope.h,
symtab.cc, symtab.h, syscalls.cc, sysdep.cc, sysdep.h, text-renderer.cc,
text-renderer.h, time.cc, toplev.cc, toplev.h, tril.cc, tsearch.cc, txt-eng.cc,
txt-eng.h, typecast.cc, url-handle-manager.cc, url-handle-manager.h,
urlwrite.cc, utils.cc, utils.h, variables.cc, variables.h, workspace-element.h,
xdiv.cc, xdiv.h, xnorm.cc, xnorm.h, xpow.cc, xpow.h, zfstream.cc, zfstream.h,
deprecated-config.h, __delaunayn__.cc, __eigs__.cc, __fltk_uigetfile__.cc,
__glpk__.cc, __init_fltk__.cc, __init_gnuplot__.cc, __ode15__.cc,
__osmesa_print__.cc, __voronoi__.cc, amd.cc, audiodevinfo.cc, audioread.cc,
ccolamd.cc, chol.cc, colamd.cc, config-module.awk, config-module.sh,
convhulln.cc, dmperm.cc, fftw.cc, gzip.cc, oct-qhull.h, qr.cc, symbfact.cc,
symrcm.cc, liboctinterp-build-info.h, liboctinterp-build-info.in.cc,
mk-build-env-features.sh, mk-builtins.pl, mk-doc.pl, mk-pkg-add.sh,
mk-version-h.in.sh, ov-base-diag.cc, ov-base-diag.h, ov-base-int.cc,
ov-base-int.h, ov-base-mat.cc, ov-base-mat.h, ov-base-scalar.cc,
ov-base-scalar.h, ov-base-sparse.cc, ov-base-sparse.h, ov-base.cc, ov-base.h,
ov-bool-mat.cc, ov-bool-mat.h, ov-bool-sparse.cc, ov-bool-sparse.h, ov-bool.cc,
ov-bool.h, ov-builtin.cc, ov-builtin.h, ov-cell.cc, ov-cell.h, ov-ch-mat.cc,
ov-ch-mat.h, ov-class.cc, ov-class.h, ov-classdef.cc, ov-classdef.h,
ov-colon.cc, ov-colon.h, ov-complex.cc, ov-complex.h, ov-cs-list.cc,
ov-cs-list.h, ov-cx-diag.cc, ov-cx-diag.h, ov-cx-mat.cc, ov-cx-mat.h,
ov-cx-sparse.cc, ov-cx-sparse.h, ov-dld-fcn.cc, ov-dld-fcn.h, ov-fcn-handle.cc,
ov-fcn-handle.h, ov-fcn-inline.cc, ov-fcn-inline.h, ov-fcn.cc, ov-fcn.h,
ov-float.cc, ov-float.h, ov-flt-complex.cc, ov-flt-complex.h,
ov-flt-cx-diag.cc, ov-flt-cx-diag.h, ov-flt-cx-mat.cc, ov-flt-cx-mat.h,
ov-flt-re-diag.cc, ov-flt-re-diag.h, ov-flt-re-mat.cc, ov-flt-re-mat.h,
ov-int-traits.h, ov-int16.cc, ov-int16.h, ov-int32.cc, ov-int32.h, ov-int64.cc,
ov-int64.h, ov-int8.cc, ov-int8.h, ov-intx.h, ov-java.cc, ov-java.h,
ov-lazy-idx.cc, ov-lazy-idx.h, ov-mex-fcn.cc, ov-mex-fcn.h, ov-null-mat.cc,
ov-null-mat.h, ov-oncleanup.cc, ov-oncleanup.h, ov-perm.cc, ov-perm.h,
ov-range.cc, ov-range.h, ov-re-diag.cc, ov-re-diag.h, ov-re-mat.cc,
ov-re-mat.h, ov-re-sparse.cc, ov-re-sparse.h, ov-scalar.cc, ov-scalar.h,
ov-str-mat.cc, ov-str-mat.h, ov-struct.cc, ov-struct.h, ov-typeinfo.cc,
ov-typeinfo.h, ov-uint16.cc, ov-uint16.h, ov-uint32.cc, ov-uint32.h,
ov-uint64.cc, ov-uint64.h, ov-uint8.cc, ov-uint8.h, ov-usr-fcn.cc,
ov-usr-fcn.h, ov.cc, ov.h, ovl.cc, ovl.h, octave.cc, octave.h, op-kw-docs,
mk-ops.sh, op-b-b.cc, op-b-bm.cc, op-b-sbm.cc, op-bm-b.cc, op-bm-bm.cc,
op-bm-sbm.cc, op-cdm-cdm.cc, op-cdm-cm.cc, op-cdm-cs.cc, op-cdm-dm.cc,
op-cdm-m.cc, op-cdm-s.cc, op-cell.cc, op-chm.cc, op-class.cc, op-cm-cdm.cc,
op-cm-cm.cc, op-cm-cs.cc, op-cm-dm.cc, op-cm-m.cc, op-cm-pm.cc, op-cm-s.cc,
op-cm-scm.cc, op-cm-sm.cc, op-cs-cm.cc, op-cs-cs.cc, op-cs-m.cc, op-cs-s.cc,
op-cs-scm.cc, op-cs-sm.cc, op-dm-cdm.cc, op-dm-cm.cc, op-dm-cs.cc, op-dm-dm.cc,
op-dm-m.cc, op-dm-s.cc, op-dm-scm.cc, op-dm-sm.cc, op-dm-template.cc,
op-dms-template.cc, op-fcdm-fcdm.cc, op-fcdm-fcm.cc, op-fcdm-fcs.cc,
op-fcdm-fdm.cc, op-fcdm-fm.cc, op-fcdm-fs.cc, op-fcm-fcdm.cc, op-fcm-fcm.cc,
op-fcm-fcs.cc, op-fcm-fdm.cc, op-fcm-fm.cc, op-fcm-fs.cc, op-fcm-pm.cc,
op-fcn.cc, op-fcs-fcm.cc, op-fcs-fcs.cc, op-fcs-fm.cc, op-fcs-fs.cc,
op-fdm-fcdm.cc, op-fdm-fcm.cc, op-fdm-fcs.cc, op-fdm-fdm.cc, op-fdm-fm.cc,
op-fdm-fs.cc, op-fm-fcdm.cc, op-fm-fcm.cc, op-fm-fcs.cc, op-fm-fdm.cc,
op-fm-fm.cc, op-fm-fs.cc, op-fm-pm.cc, op-fs-fcm.cc, op-fs-fcs.cc, op-fs-fm.cc,
op-fs-fs.cc, op-i16-i16.cc, op-i32-i32.cc, op-i64-i64.cc, op-i8-i8.cc,
op-int-concat.cc, op-int.h, op-m-cdm.cc, op-m-cm.cc, op-m-cs.cc, op-m-dm.cc,
op-m-m.cc, op-m-pm.cc, op-m-s.cc, op-m-scm.cc, op-m-sm.cc, op-pm-cm.cc,
op-pm-fcm.cc, op-pm-fm.cc, op-pm-m.cc, op-pm-pm.cc, op-pm-scm.cc, op-pm-sm.cc,
op-pm-template.cc, op-range.cc, op-s-cm.cc, op-s-cs.cc, op-s-m.cc, op-s-s.cc,
op-s-scm.cc, op-s-sm.cc, op-sbm-b.cc, op-sbm-bm.cc, op-sbm-sbm.cc,
op-scm-cm.cc, op-scm-cs.cc, op-scm-m.cc, op-scm-s.cc, op-scm-scm.cc,
op-scm-sm.cc, op-sm-cm.cc, op-sm-cs.cc, op-sm-m.cc, op-sm-s.cc, op-sm-scm.cc,
op-sm-sm.cc, op-str-m.cc, op-str-s.cc, op-str-str.cc, op-struct.cc,
op-ui16-ui16.cc, op-ui32-ui32.cc, op-ui64-ui64.cc, op-ui8-ui8.cc, ops.h,
options-usage.h, bp-table.cc, bp-table.h, comment-list.cc, comment-list.h,
jit-ir.cc, jit-ir.h, jit-typeinfo.cc, jit-typeinfo.h, jit-util.cc, jit-util.h,
lex.h, lex.ll, oct-lvalue.cc, oct-lvalue.h, oct-parse.in.yy, octave.gperf,
parse.h, profiler.cc, profiler.h, pt-all.h, pt-arg-list.cc, pt-arg-list.h,
pt-array-list.cc, pt-array-list.h, pt-assign.cc, pt-assign.h, pt-binop.cc,
pt-binop.h, pt-bp.cc, pt-bp.h, pt-cbinop.cc, pt-cbinop.h, pt-cell.cc,
pt-cell.h, pt-check.cc, pt-check.h, pt-classdef.cc, pt-classdef.h, pt-cmd.h,
pt-colon.cc, pt-colon.h, pt-const.cc, pt-const.h, pt-decl.cc, pt-decl.h,
pt-eval.cc, pt-eval.h, pt-except.cc, pt-except.h, pt-exp.cc, pt-exp.h,
pt-fcn-handle.cc, pt-fcn-handle.h, pt-funcall.cc, pt-funcall.h, pt-id.cc,
pt-id.h, pt-idx.cc, pt-idx.h, pt-jit.cc, pt-jit.h, pt-jump.cc, pt-jump.h,
pt-loop.cc, pt-loop.h, pt-mat.cc, pt-mat.h, pt-misc.cc, pt-misc.h,
pt-pr-code.cc, pt-pr-code.h, pt-select.cc, pt-select.h, pt-stmt.cc, pt-stmt.h,
pt-tm-const.cc, pt-tm-const.h, pt-unop.cc, pt-unop.h, pt-walk.cc, pt-walk.h,
pt.cc, pt.h, token.cc, token.h, Array-jit.cc, Array-tc.cc, version.cc,
version.in.h, Array-C.cc, Array-b.cc, Array-ch.cc, Array-d.cc, Array-f.cc,
Array-fC.cc, Array-i.cc, Array-idx-vec.cc, Array-s.cc, Array-str.cc,
Array-util.cc, Array-util.h, Array-voidp.cc, Array.cc, Array.h, CColVector.cc,
CColVector.h, CDiagMatrix.cc, CDiagMatrix.h, CMatrix.cc, CMatrix.h,
CNDArray.cc, CNDArray.h, CRowVector.cc, CRowVector.h, CSparse.cc, CSparse.h,
DiagArray2.cc, DiagArray2.h, MArray-C.cc, MArray-d.cc, MArray-f.cc,
MArray-fC.cc, MArray-i.cc, MArray-s.cc, MArray.cc, MArray.h, MDiagArray2.cc,
MDiagArray2.h, MSparse-C.cc, MSparse-d.cc, MSparse.cc, MSparse.h, Matrix.h,
MatrixType.cc, MatrixType.h, PermMatrix.cc, PermMatrix.h, Range.cc, Range.h,
Sparse-C.cc, Sparse-b.cc, Sparse-d.cc, Sparse.cc, Sparse.h, boolMatrix.cc,
boolMatrix.h, boolNDArray.cc, boolNDArray.h, boolSparse.cc, boolSparse.h,
chMatrix.cc, chMatrix.h, chNDArray.cc, chNDArray.h, dColVector.cc,
dColVector.h, dDiagMatrix.cc, dDiagMatrix.h, dMatrix.cc, dMatrix.h,
dNDArray.cc, dNDArray.h, dRowVector.cc, dRowVector.h, dSparse.cc, dSparse.h,
dim-vector.cc, dim-vector.h, fCColVector.cc, fCColVector.h, fCDiagMatrix.cc,
fCDiagMatrix.h, fCMatrix.cc, fCMatrix.h, fCNDArray.cc, fCNDArray.h,
fCRowVector.cc, fCRowVector.h, fColVector.cc, fColVector.h, fDiagMatrix.cc,
fDiagMatrix.h, fMatrix.cc, fMatrix.h, fNDArray.cc, fNDArray.h, fRowVector.cc,
fRowVector.h, idx-vector.cc, idx-vector.h, int16NDArray.cc, int16NDArray.h,
int32NDArray.cc, int32NDArray.h, int64NDArray.cc, int64NDArray.h,
int8NDArray.cc, int8NDArray.h, intNDArray.cc, intNDArray.h, uint16NDArray.cc,
uint16NDArray.h, uint32NDArray.cc, uint32NDArray.h, uint64NDArray.cc,
uint64NDArray.h, uint8NDArray.cc, uint8NDArray.h, cconv2.f, cdotc3.f, cmatm3.f,
csconv2.f, dconv2.f, ddot3.f, dmatm3.f, sconv2.f, sdot3.f, smatm3.f, zconv2.f,
zdconv2.f, zdotc3.f, zmatm3.f, crsf2csf.f, zrsf2csf.f, mk-f77-def.in.sh,
liboctave-build-info.h, liboctave-build-info.in.cc, CollocWt.cc, CollocWt.h,
DAE.h, DAEFunc.h, DAERT.h, DAERTFunc.h, DASPK-opts.in, DASPK.cc, DASPK.h,
DASRT-opts.in, DASRT.cc, DASRT.h, DASSL-opts.in, DASSL.cc, DASSL.h, DET.h,
EIG.cc, EIG.h, LSODE-opts.in, LSODE.cc, LSODE.h, ODE.h, ODEFunc.h, ODES.cc,
ODES.h, ODESFunc.h, Quad-opts.in, Quad.cc, Quad.h, aepbalance.cc, aepbalance.h,
base-dae.h, base-de.h, base-min.h, bsxfun-decl.h, bsxfun-defs.cc, bsxfun.h,
chol.cc, chol.h, eigs-base.cc, eigs-base.h, fEIG.cc, fEIG.h, gepbalance.cc,
gepbalance.h, gsvd.cc, gsvd.h, hess.cc, hess.h, lo-amos-proto.h,
lo-arpack-proto.h, lo-blas-proto.h, lo-fftpack-proto.h, lo-lapack-proto.h,
lo-mappers.cc, lo-mappers.h, lo-qrupdate-proto.h, lo-ranlib-proto.h,
lo-slatec-proto.h, lo-specfun.cc, lo-specfun.h, lu.cc, lu.h, oct-convn.cc,
oct-convn.h, oct-fftw.cc, oct-fftw.h, oct-norm.cc, oct-norm.h, oct-rand.cc,
oct-rand.h, oct-spparms.cc, oct-spparms.h, qr.cc, qr.h, qrp.cc, qrp.h,
randgamma.cc, randgamma.h, randmtzig.cc, randmtzig.h, randpoisson.cc,
randpoisson.h, schur.cc, schur.h, sparse-chol.cc, sparse-chol.h,
sparse-dmsolve.cc, sparse-dmsolve.h, sparse-lu.cc, sparse-lu.h, sparse-qr.cc,
sparse-qr.h, svd.cc, svd.h, Sparse-diag-op-defs.h, Sparse-op-decls.h,
Sparse-op-defs.h, Sparse-perm-op-defs.h, config-ops.sh, mk-ops.awk, mx-base.h,
mx-defs.h, mx-ext.h, mx-inlines.cc, mx-op-decl.h, mx-op-defs.h, mx-ops,
smx-ops, vx-ops, child-list.cc, child-list.h, cmach-info.c, cmach-info.h,
dir-ops.cc, dir-ops.h, file-ops.cc, file-ops.h, file-stat.cc, file-stat.h,
lo-sysdep.cc, lo-sysdep.h, mach-info.cc, mach-info.h, oct-env.cc, oct-env.h,
oct-group.cc, oct-group.h, oct-passwd.cc, oct-passwd.h, oct-syscalls.cc,
oct-syscalls.h, oct-time.cc, oct-time.h, oct-uname.cc, oct-uname.h,
action-container.h, base-list.h, blaswrap.c, byte-swap.h, caseless-str.h,
cmd-edit.cc, cmd-edit.h, cmd-hist.cc, cmd-hist.h, cquit.c, data-conv.cc,
data-conv.h, f2c-main.c, f77-fcn.c, f77-fcn.h, file-info.cc, file-info.h,
functor.h, glob-match.cc, glob-match.h, kpse.cc, kpse.h, lo-array-errwarn.cc,
lo-array-errwarn.h, lo-array-gripes.cc, lo-array-gripes.h, lo-cutils.c,
lo-cutils.h, lo-error.c, lo-error.h, lo-hash.cc, lo-hash.h, lo-ieee.cc,
lo-ieee.h, lo-regexp.cc, lo-regexp.h, lo-traits.h, lo-utils.cc, lo-utils.h,
oct-base64.cc, oct-base64.h, oct-binmap.h, oct-cmplx.h, oct-glob.cc,
oct-glob.h, oct-inttypes-fwd.h, oct-inttypes.cc, oct-inttypes.h, oct-locbuf.h,
oct-mutex.cc, oct-mutex.h, oct-refcount.h, oct-rl-edit.c, oct-rl-edit.h,
oct-rl-hist.c, oct-rl-hist.h, oct-shlib.cc, oct-shlib.h, oct-sort.cc,
oct-sort.h, oct-sparse.cc, oct-sparse.h, oct-string.cc, oct-string.h,
octave-preserve-stream-state.h, pathsearch.cc, pathsearch.h, quit.cc, quit.h,
singleton-cleanup.cc, singleton-cleanup.h, sparse-sort.cc, sparse-sort.h,
sparse-util.cc, sparse-util.h, str-vec.cc, str-vec.h, sun-utils.h,
unwind-prot.cc, unwind-prot.h, url-transfer.cc, url-transfer.h,
areadlink-wrapper.c, areadlink-wrapper.h, async-system-wrapper.c,
async-system-wrapper.h, base64-wrappers.c, base64-wrappers.h,
canonicalize-file-name-wrapper.c, canonicalize-file-name-wrapper.h,
dirent-wrappers.c, dirent-wrappers.h, fcntl-wrappers.c, fcntl-wrappers.h,
filepos-wrappers.c, filepos-wrappers.h, fpucw-wrappers.c, fpucw-wrappers.h,
gen-tempname-wrapper.c, gen-tempname-wrapper.h, getopt-wrapper.c,
getopt-wrapper.h, glob-wrappers.c, glob-wrappers.h, hash-wrappers.c,
hash-wrappers.h, localcharset-wrapper.c, localcharset-wrapper.h,
math-wrappers.c, math-wrappers.h, mkostemp-wrapper.c, mkostemp-wrapper.h,
nanosleep-wrapper.c, nanosleep-wrapper.h, nproc-wrapper.c, nproc-wrapper.h,
octave-popen2.c, octave-popen2.h, putenv-wrapper.c, putenv-wrapper.h,
set-program-name-wrapper.c, set-program-name-wrapper.h, signal-wrappers.c,
signal-wrappers.h, stat-wrappers.c, stat-wrappers.h, strdup-wrapper.c,
strdup-wrapper.h, strftime-wrapper.c, strftime-wrapper.h, strmode-wrapper.c,
strmode-wrapper.h, strptime-wrapper.c, strptime-wrapper.h, time-wrappers.c,
time-wrappers.h, tmpfile-wrapper.c, tmpfile-wrapper.h, uname-wrapper.c,
uname-wrapper.h, uniconv-wrappers.c, uniconv-wrappers.h, unistd-wrappers.c,
unistd-wrappers.h, unsetenv-wrapper.c, unsetenv-wrapper.h, vasprintf-wrapper.c,
vasprintf-wrapper.h, wait-for-input.c, wait-for-input.h, wait-wrappers.c,
wait-wrappers.h, acinclude.m4, ax_blas.m4, ax_lapack.m4, ax_openmp.m4,
ax_pthread.m4, octave_blas_f77_func.m4, pkg.m4, oct-conf-post.in.h,
run-octave.in, Map.m, ascii.m, binary.m, cd.m, close.m, delete.m,
dir.m, disp.m, ftp.m, loadobj.m, mget.m, mkdir.m, mput.m, rename.m, rmdir.m,
saveobj.m, __get_properties__.m, audioplayer.m, disp.m, get.m, isplaying.m,
pause.m, play.m, playblocking.m, resume.m, set.m, stop.m, subsasgn.m,
subsref.m, __get_properties__.m, audiorecorder.m, disp.m, get.m,
getaudiodata.m, getplayer.m, isrecording.m, pause.m, play.m, record.m,
recordblocking.m, resume.m, set.m, stop.m, subsasgn.m, subsref.m, lin2mu.m,
mu2lin.m, record.m, sound.m, soundsc.m, bitmax.m, chop.m, comma.m, isstr.m,
mahalanobis.m, md5sum.m, octave_config_info.m, onenormest.m, paren.m,
semicolon.m, sleep.m, usleep.m, wavread.m, wavwrite.m, acosd.m, acot.m,
acotd.m, acoth.m, acsc.m, acscd.m, acsch.m, asec.m, asecd.m, asech.m, asind.m,
atan2d.m, atand.m, cosd.m, cot.m, cotd.m, coth.m, csc.m, cscd.m, csch.m, sec.m,
secd.m, sech.m, sind.m, tand.m, accumarray.m, accumdim.m, bincoeff.m, bitcmp.m,
bitget.m, bitset.m, blkdiag.m, cart2pol.m, cart2sph.m, cell2mat.m, celldisp.m,
circshift.m, common_size.m, cplxpair.m, cumtrapz.m, curl.m, dblquad.m, deal.m,
deg2rad.m, del2.m, divergence.m, flip.m, flipdim.m, fliplr.m, flipud.m,
gradient.m, idivide.m, int2str.m, integral.m, integral2.m, integral3.m,
interp1.m, interp2.m, interp3.m, interpft.m, interpn.m, isequal.m, isequaln.m,
logspace.m, nextpow2.m, num2str.m, pol2cart.m, polyarea.m, postpad.m, prepad.m,
__splinen__.m, quad2d.m, quadgk.m, quadl.m, quadv.m, rad2deg.m, randi.m, rat.m,
repelem.m, repmat.m, rot90.m, rotdim.m, shift.m, shiftdim.m, sortrows.m,
sph2cart.m, structfun.m, subsindex.m, trapz.m, triplequad.m, xor.m, convhull.m,
delaunay.m, delaunayn.m, dsearch.m, dsearchn.m, griddata.m, griddata3.m,
griddatan.m, inpolygon.m, rectint.m, tsearchn.m, voronoi.m, voronoin.m,
dialog.m, errordlg.m, getappdata.m, guidata.m, guihandles.m, helpdlg.m,
inputdlg.m, isappdata.m, listdlg.m, msgbox.m, __file_filter__.m,
__fltk_file_filter__.m, __get_funcname__.m, __is_function__.m,
__uigetdir_fltk__.m, __uigetfile_fltk__.m, __uiobject_split_args__.m,
__uiputfile_fltk__.m, questdlg.m, rmappdata.m, setappdata.m, uibuttongroup.m,
uicontextmenu.m, uicontrol.m, uigetdir.m, uigetfile.m, uimenu.m, uipanel.m,
uipushtool.m, uiputfile.m, uiresume.m, uitoggletool.m, uitoolbar.m, uiwait.m,
waitbar.m, waitforbuttonpress.m, warndlg.m, __gripe_missing_component__.m,
__makeinfo__.m, __unimplemented__.m, ans.m, debug.m, doc.m, doc_cache_create.m,
error_ids.m, get_first_help_sentence.m, help.m, lookfor.m, print_usage.m,
__additional_help_message__.m, __strip_html_tags__.m, slash.m, type.m,
warning_ids.m, which.m, autumn.m, bone.m, brighten.m, cmpermute.m, cmunique.m,
colorcube.m, colormap.m, contrast.m, cool.m, copper.m, cubehelix.m, flag.m,
frame2im.m, getframe.m, gray.m, gray2ind.m, hot.m, hsv.m, hsv2rgb.m,
im2double.m, im2frame.m, image.m, imagesc.m, imfinfo.m, imformats.m, imread.m,
imshow.m, imwrite.m, ind2gray.m, ind2rgb.m, iscolormap.m, jet.m, lines.m,
ntsc2rgb.m, ocean.m, pink.m, prism.m, __imfinfo__.m, __imread__.m,
__imwrite__.m, colorspace_conversion_input_check.m,
colorspace_conversion_revert.m, imageIO.m, imwrite_filename.m, ind2x.m,
rainbow.m, rgb2hsv.m, rgb2ind.m, rgb2ntsc.m, rgbplot.m, spinmap.m, spring.m,
summer.m, viridis.m, white.m, winter.m, beep.m, csvread.m, csvwrite.m,
dlmwrite.m, fileread.m, importdata.m, is_valid_file_id.m, strread.m,
textread.m, javaArray.m, java_get.m, java_set.m, javaaddpath.m, javachk.m,
javaclasspath.m, javamem.m, javarmpath.m, ClassHelper.java, Matrix.java,
OctClassLoader.java, Octave.java, OctaveReference.java, usejava.m, bandwidth.m,
commutation_matrix.m, cond.m, condeig.m, condest.m, cross.m,
duplication_matrix.m, expm.m, gls.m, housh.m, isbanded.m, isdefinite.m,
isdiag.m, ishermitian.m, issymmetric.m, istril.m, istriu.m, krylov.m,
linsolve.m, logm.m, lscov.m, normest.m, normest1.m, null.m, ols.m, orth.m,
planerot.m, qzhess.m, rank.m, rref.m, subspace.m, trace.m, vech.m, vecnorm.m,
bug_report.m, bunzip2.m, cast.m, citation.m, compare_versions.m, computer.m,
copyfile.m, delete.m, desktop.m, dir.m, dos.m, edit.m, fact.m, fieldnames.m,
fileattrib.m, fileparts.m, fullfile.m, genvarname.m, getfield.m, grabcode.m,
gunzip.m, info.m, inputParser.m, inputname.m, isdeployed.m, isdir.m, ismac.m,
ispc.m, isunix.m, license.m, list_primes.m, loadobj.m, ls.m, ls_command.m,
menu.m, methods.m, mex.m, mexext.m, mkdir.m, mkoctfile.m, movefile.m,
namelengthmax.m, nargchk.m, narginchk.m, nargoutchk.m, news.m, nthargout.m,
open.m, orderfields.m, pack.m, parseparams.m, perl.m,
__publish_html_output__.m, __publish_latex_output__.m, __w2mpth__.m,
display_info_file.m, publish.m, python.m, recycle.m, run.m, saveobj.m,
setfield.m, substruct.m, swapbytes.m, symvar.m, tar.m, tempdir.m, tmpnam.m,
unix.m, unpack.m, untar.m, unzip.m, validateattributes.m, ver.m, version.m,
what.m, zip.m, mk-doc.pl, mk-pkg-add.sh, decic.m, ode15i.m, ode15s.m, ode23.m,
ode45.m, odeget.m, odeplot.m, odeset.m, AbsRel_norm.m, check_default_input.m,
integrate_adaptive.m, kahan.m, ode_event_handler.m, odedefaults.m,
odemergeopts.m, runge_kutta_23.m, runge_kutta_45_dorpri.m,
runge_kutta_interpolate.m, starting_stepsize.m, __all_opts__.m, fminbnd.m,
fminsearch.m, fminunc.m, fsolve.m, fzero.m, glpk.m, humps.m, lsqnonneg.m,
optimget.m, optimset.m, pqpnonneg.m, __fdjac__.m, qp.m, sqp.m, import.m,
matlabroot.m, pathdef.m, getsavepath.m, savepath.m, pkg.m, build.m,
configure_make.m, default_prefix.m, describe.m, dirempty.m, get_description.m,
get_forge_download.m, get_forge_pkg.m, get_unsatisfied_deps.m, getarch.m,
getarchdir.m, install.m, installed_packages.m, list_forge_packages.m,
load_packages.m, load_packages_and_dependencies.m, rebuild.m, save_order.m,
uninstall.m, unload_packages.m, __clabel__.m, __getlegenddata__.m,
__rotate_around_axis__.m, annotation.m, axis.m, box.m, camlookat.m, camorbit.m,
campos.m, camroll.m, camtarget.m, camup.m, camva.m, camzoom.m, caxis.m,
clabel.m, daspect.m, datetick.m, diffuse.m, grid.m, gtext.m, hidden.m,
legend.m, lighting.m, material.m, orient.m, pbaspect.m, __axis_label__.m,
__axis_limits__.m, rticks.m, shading.m, specular.m, text.m, thetaticks.m,
title.m, view.m, whitebg.m, xlabel.m, xlim.m, xticklabels.m, xticks.m,
ylabel.m, ylim.m, yticklabels.m, yticks.m, zlabel.m, zlim.m, zticklabels.m,
zticks.m, area.m, bar.m, barh.m, camlight.m, colorbar.m, comet.m, comet3.m,
compass.m, contour.m, contour3.m, contourc.m, contourf.m, cylinder.m,
ellipsoid.m, errorbar.m, ezcontour.m, ezcontourf.m, ezmesh.m, ezmeshc.m,
ezplot.m, ezplot3.m, ezpolar.m, ezsurf.m, ezsurfc.m, feather.m, fill.m,
fplot.m, hist.m, isocaps.m, isocolors.m, isonormals.m, isosurface.m, light.m,
line.m, loglog.m, loglogerr.m, mesh.m, meshc.m, meshz.m, pareto.m, patch.m,
pcolor.m, peaks.m, pie.m, pie3.m, plot.m, plot3.m, plotmatrix.m, plotyy.m,
polar.m, __add_datasource__.m, __bar__.m, __calc_isovalue_from_data__.m,
__contour__.m, __errplot__.m, __ezplot__.m, __interp_cube__.m, __line__.m,
__marching_cube__.m, __patch__.m, __pie__.m, __plt__.m, __quiver__.m,
__scatter__.m, __stem__.m, __unite_shared_vertices__.m, quiver.m, quiver3.m,
rectangle.m, reducepatch.m, reducevolume.m, ribbon.m, rose.m, scatter.m,
scatter3.m, semilogx.m, semilogxerr.m, semilogy.m, semilogyerr.m,
shrinkfaces.m, slice.m, smooth3.m, sombrero.m, sphere.m, stairs.m, stem.m,
stem3.m, stemleaf.m, surf.m, surface.m, surfc.m, surfl.m, surfnorm.m,
tetramesh.m, trimesh.m, triplot.m, trisurf.m, waterfall.m,
__actual_axis_position__.m, __default_plot_options__.m, __gnuplot_drawnow__.m,
__next_line_color__.m, __next_line_style__.m, __opengl_info__.m,
__plt_get_axis_arg__.m, __pltopt__.m, allchild.m, ancestor.m, axes.m, cla.m,
clf.m, close.m, closereq.m, colstyle.m, copyobj.m, figure.m, findall.m,
findfigs.m, findobj.m, gca.m, gcbf.m, gcbo.m, gcf.m, gco.m, ginput.m,
gnuplot_binary.in.m, graphics_toolkit.m, groot.m, hdl2struct.m, hggroup.m,
hgload.m, hgsave.m, hgtransform.m, hold.m, isaxes.m, isfigure.m, isgraphics.m,
ishandle.m, ishold.m, isprop.m, linkaxes.m, linkprop.m, meshgrid.m, ndgrid.m,
newplot.m, pan.m, print.m, printd.m, __add_default_menu__.m, __ghostscript__.m,
__gnuplot_draw_axes__.m, __gnuplot_draw_figure__.m, __gnuplot_get_var__.m,
__gnuplot_ginput__.m, __gnuplot_has_feature__.m, __gnuplot_has_terminal__.m,
__gnuplot_open_stream__.m, __gnuplot_print__.m, __gnuplot_version__.m,
__opengl_print__.m, __print_parse_opts__.m, __set_default_mouse_modes__.m,
refresh.m, refreshdata.m, rotate.m, rotate3d.m, saveas.m, shg.m, struct2hdl.m,
subplot.m, zoom.m, compan.m, conv.m, deconv.m, mkpp.m, mpoles.m, padecoef.m,
pchip.m, poly.m, polyaffine.m, polyder.m, polyeig.m, polyfit.m, polygcd.m,
polyint.m, polyout.m, polyreduce.m, polyval.m, polyvalm.m, ppder.m, ppint.m,
ppjumps.m, ppval.m, residue.m, roots.m, spline.m, splinefit.m, unmkpp.m,
addpref.m, getpref.m, ispref.m, prefdir.m, preferences.m, loadprefs.m,
prefsfile.m, saveprefs.m, rmpref.m, setpref.m, style.css, profexplore.m,
profexport.m, profile.m, profshow.m, intersect.m, ismember.m, powerset.m,
validsetargs.m, setdiff.m, setxor.m, union.m, unique.m, arch_fit.m, arch_rnd.m,
arch_test.m, arma_rnd.m, autoreg_matrix.m, bartlett.m, blackman.m, detrend.m,
diffpara.m, durbinlevinson.m, fftconv.m, fftfilt.m, fftshift.m, filter2.m,
fractdiff.m, freqz.m, freqz_plot.m, hamming.m, hanning.m, hurst.m, ifftshift.m,
periodogram.m, rectangle_lw.m, rectangle_sw.m, triangle_lw.m, triangle_sw.m,
sinc.m, sinetone.m, sinewave.m, spectral_adf.m, spectral_xdf.m, spencer.m,
stft.m, synthesis.m, unwrap.m, yulewalker.m, bicg.m, bicgstab.m, cgs.m,
colperm.m, eigs.m, etreeplot.m, gmres.m, gplot.m, ichol.m, ilu.m, nonzeros.m,
pcg.m, pcr.m, __sprand__.m, qmr.m, spaugment.m, spconvert.m, spdiags.m,
speye.m, spfun.m, spones.m, sprand.m, sprandn.m, sprandsym.m, spstats.m, spy.m,
svds.m, treelayout.m, treeplot.m, bessel.m, beta.m, betaln.m, ellipke.m,
expint.m, factor.m, factorial.m, isprime.m, lcm.m, legendre.m, nchoosek.m,
nthroot.m, perms.m, pow2.m, primes.m, reallog.m, realpow.m, realsqrt.m,
gallery.m, hadamard.m, hankel.m, hilb.m, invhilb.m, magic.m, pascal.m,
rosser.m, toeplitz.m, vander.m, wilkinson.m, __finish__.m, center.m, cloglog.m,
corr.m, corrcoef.m, cov.m, crosstab.m, histc.m, iqr.m, kendall.m, kurtosis.m,
logit.m, mean.m, meansq.m, median.m, mode.m, moment.m, ppplot.m, prctile.m,
probit.m, qqplot.m, quantile.m, range.m, ranks.m, run_count.m, runlength.m,
skewness.m, spearman.m, statistics.m, std.m, var.m, zscore.m, betacdf.m,
betainv.m, betapdf.m, betarnd.m, binocdf.m, binoinv.m, binopdf.m, binornd.m,
cauchy_cdf.m, cauchy_inv.m, cauchy_pdf.m, cauchy_rnd.m, chi2cdf.m, chi2inv.m,
chi2pdf.m, chi2rnd.m, discrete_cdf.m, discrete_inv.m, discrete_pdf.m,
discrete_rnd.m, empirical_cdf.m, empirical_inv.m, empirical_pdf.m,
empirical_rnd.m, expcdf.m, expinv.m, exppdf.m, exprnd.m, fcdf.m, finv.m,
fpdf.m, frnd.m, gamcdf.m, gaminv.m, gampdf.m, gamrnd.m, geocdf.m, geoinv.m,
geopdf.m, geornd.m, hygecdf.m, hygeinv.m, hygepdf.m, hygernd.m,
kolmogorov_smirnov_cdf.m, laplace_cdf.m, laplace_inv.m, laplace_pdf.m,
laplace_rnd.m, logistic_cdf.m, logistic_inv.m, logistic_pdf.m, logistic_rnd.m,
logncdf.m, logninv.m, lognpdf.m, lognrnd.m, nbincdf.m, nbininv.m, nbinpdf.m,
nbinrnd.m, normcdf.m, norminv.m, normpdf.m, normrnd.m, poisscdf.m, poissinv.m,
poisspdf.m, poissrnd.m, stdnormal_cdf.m, stdnormal_inv.m, stdnormal_pdf.m,
stdnormal_rnd.m, tcdf.m, tinv.m, tpdf.m, trnd.m, unidcdf.m, unidinv.m,
unidpdf.m, unidrnd.m, unifcdf.m, unifinv.m, unifpdf.m, unifrnd.m, wblcdf.m,
wblinv.m, wblpdf.m, wblrnd.m, wienrnd.m, logistic_regression.m,
logistic_regression_derivatives.m, logistic_regression_likelihood.m, anova.m,
bartlett_test.m, chisquare_test_homogeneity.m, chisquare_test_independence.m,
cor_test.m, f_test_regression.m, hotelling_test.m, hotelling_test_2.m,
kolmogorov_smirnov_test.m, kolmogorov_smirnov_test_2.m, kruskal_wallis_test.m,
manova.m, mcnemar_test.m, prop_test_2.m, run_test.m, sign_test.m, t_test.m,
t_test_2.m, t_test_regression.m, u_test.m, var_test.m, welch_test.m,
wilcoxon_test.m, z_test.m, z_test_2.m, base2dec.m, bin2dec.m, blanks.m,
cstrcat.m, deblank.m, dec2base.m, dec2bin.m, dec2hex.m, erase.m, findstr.m,
hex2dec.m, index.m, isletter.m, isstring.m, isstrprop.m, mat2str.m,
native2unicode.m, ostrsplit.m, regexptranslate.m, rindex.m, str2num.m,
strcat.m, strchr.m, strjoin.m, strjust.m, strmatch.m, strsplit.m, strtok.m,
strtrim.m, strtrunc.m, substr.m, unicode2native.m, untabify.m,
validatestring.m, __have_feature__.m, __printf_assert__.m,
__prog_output_assert__.m, __run_test_suite__.m, assert.m, demo.m, example.m,
fail.m, compare_plot_demos.m, dump_demos.m, html_compare_plot_demos.m,
rundemos.m, runtests.m, speed.m, test.m, addtodate.m, asctime.m, calendar.m,
clock.m, ctime.m, date.m, datenum.m, datestr.m, datevec.m, eomday.m, etime.m,
is_leap_year.m, now.m, weekday.m, display-available.c, display-available.h,
main-cli.cc, main-gui.cc, main.in.cc, mkoctfile.in.cc, octave-build-info.h,
octave-build-info.in.cc, octave-config.in.cc, shared-fcns.h, args.tst,
bug-31371.tst, bug-35448.tst, bug-35881.tst, bug-36025.tst, bug-38236.tst,
bug-38565.tst, bug-38576.tst, bug-38691.tst, bug-41723.tst, bug-44940.tst,
bug-46330.tst, bug-46660.tst, bug-50014.tst, bug-50035.tst, bug-50716.tst,
bug-51192.tst, bug-51532.tst, bug-51534.tst, bug-51599.tst, bug-52075.tst,
class-concat.tst, classdef-multiple-inheritance.tst, classdef.tst, classes.tst,
colormaps.tst, command.tst, complex.tst, ctor-vs-method.tst,
deprecate-props.tst, diag-perm.tst, error.tst, eval-catch.tst,
fcn-handle-derived-resolution.tst, fntests.m, for.tst, func.tst, global.tst,
if.tst, index.tst, io.tst, jit.tst, leftdiv.tst, line-continue.tst,
logical-index.tst, mk-bc-overloads-tst.sh, mk-conv-tst.sh, mk-sparse-tst.sh,
nest.tst, null-assign.tst, parser.tst, prefer.tst, publish.tst, range.tst,
recursion.tst, return.tst, show-failures.awk, single-index.tst, slice.tst,
struct.tst, switch.tst, system.tst, transpose.tst, try.tst, unwind.tst,
while.tst:
Changed punctuation of GPL license text to match that suggested by FSF.
author | Rik <rik@octave.org> |
---|---|
date | Sat, 06 Jan 2018 07:57:19 -0800 |
parents | 092078913d54 |
children | 6652d3823428 |
rev | line source |
---|---|
23219
3ac9f9ecfae5
maint: Update copyright dates.
John W. Eaton <jwe@octave.org>
parents:
23217
diff
changeset
|
1 @c Copyright (C) 1996-2017 John W. Eaton |
7018 | 2 @c |
3 @c This file is part of Octave. | |
4 @c | |
24534
194eb4bd202b
maint: Update punctuation for GPL v3 license text.
Rik <rik@octave.org>
parents:
23220
diff
changeset
|
5 @c Octave is free software: you can redistribute it and/or modify it |
22755
3a2b891d0b33
maint: Standardize Copyright formatting.
Rik <rik@octave.org>
parents:
22323
diff
changeset
|
6 @c under the terms of the GNU General Public License as published by |
24534
194eb4bd202b
maint: Update punctuation for GPL v3 license text.
Rik <rik@octave.org>
parents:
23220
diff
changeset
|
7 @c the Free Software Foundation, either version 3 of the License, or |
22755
3a2b891d0b33
maint: Standardize Copyright formatting.
Rik <rik@octave.org>
parents:
22323
diff
changeset
|
8 @c (at your option) any later version. |
19593
446c46af4b42
strip trailing whitespace from most source files
John W. Eaton <jwe@octave.org>
parents:
17744
diff
changeset
|
9 @c |
22755
3a2b891d0b33
maint: Standardize Copyright formatting.
Rik <rik@octave.org>
parents:
22323
diff
changeset
|
10 @c Octave is distributed in the hope that it will be useful, but |
3a2b891d0b33
maint: Standardize Copyright formatting.
Rik <rik@octave.org>
parents:
22323
diff
changeset
|
11 @c WITHOUT ANY WARRANTY; without even the implied warranty of |
3a2b891d0b33
maint: Standardize Copyright formatting.
Rik <rik@octave.org>
parents:
22323
diff
changeset
|
12 @c MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
3a2b891d0b33
maint: Standardize Copyright formatting.
Rik <rik@octave.org>
parents:
22323
diff
changeset
|
13 @c GNU General Public License for more details. |
19593
446c46af4b42
strip trailing whitespace from most source files
John W. Eaton <jwe@octave.org>
parents:
17744
diff
changeset
|
14 @c |
7018 | 15 @c You should have received a copy of the GNU General Public License |
16 @c along with Octave; see the file COPYING. If not, see | |
24534
194eb4bd202b
maint: Update punctuation for GPL v3 license text.
Rik <rik@octave.org>
parents:
23220
diff
changeset
|
17 @c <https://www.gnu.org/licenses/>. |
3294 | 18 |
4167 | 19 @node Numeric Data Types |
3294 | 20 @chapter Numeric Data Types |
21 @cindex numeric constant | |
22 @cindex numeric value | |
23 | |
23212
0881e1671490
doc: Add documentation for hex and binary prefix and _ separator(bugs #50305, #50334)
Ernst Reissner <rei3ner@arcor.de>
parents:
22323
diff
changeset
|
24 A @dfn{numeric constant} may be a scalar, a vector, or a matrix, and it may |
0881e1671490
doc: Add documentation for hex and binary prefix and _ separator(bugs #50305, #50334)
Ernst Reissner <rei3ner@arcor.de>
parents:
22323
diff
changeset
|
25 contain complex values. |
3294 | 26 |
23212
0881e1671490
doc: Add documentation for hex and binary prefix and _ separator(bugs #50305, #50334)
Ernst Reissner <rei3ner@arcor.de>
parents:
22323
diff
changeset
|
27 The simplest form of a numeric constant, a scalar, is a single number. Note |
23217
893d99338cc8
doc: Reword manual section on numeric constants for clarity.
Rik <rik@octave.org>
parents:
23212
diff
changeset
|
28 that by default numeric constants are represented within Octave by IEEE 754 |
23212
0881e1671490
doc: Add documentation for hex and binary prefix and _ separator(bugs #50305, #50334)
Ernst Reissner <rei3ner@arcor.de>
parents:
22323
diff
changeset
|
29 double precision (binary64) floating-point format (complex constants are |
0881e1671490
doc: Add documentation for hex and binary prefix and _ separator(bugs #50305, #50334)
Ernst Reissner <rei3ner@arcor.de>
parents:
22323
diff
changeset
|
30 stored as pairs of binary64 values). It is, however, possible to represent |
23217
893d99338cc8
doc: Reword manual section on numeric constants for clarity.
Rik <rik@octave.org>
parents:
23212
diff
changeset
|
31 real integers as described in @ref{Integer Data Types}. |
893d99338cc8
doc: Reword manual section on numeric constants for clarity.
Rik <rik@octave.org>
parents:
23212
diff
changeset
|
32 |
893d99338cc8
doc: Reword manual section on numeric constants for clarity.
Rik <rik@octave.org>
parents:
23212
diff
changeset
|
33 If the numeric constant is a real integer, it can be defined in decimal, |
893d99338cc8
doc: Reword manual section on numeric constants for clarity.
Rik <rik@octave.org>
parents:
23212
diff
changeset
|
34 hexadecimal, or binary notation. Hexadecimal notation starts with @samp{0x} or |
893d99338cc8
doc: Reword manual section on numeric constants for clarity.
Rik <rik@octave.org>
parents:
23212
diff
changeset
|
35 @samp{0X}, binary notation starts with @samp{0b} or @samp{0B}, otherwise |
893d99338cc8
doc: Reword manual section on numeric constants for clarity.
Rik <rik@octave.org>
parents:
23212
diff
changeset
|
36 decimal notation is assumed. As a consequence, @samp{0b} is not a hexadecimal |
893d99338cc8
doc: Reword manual section on numeric constants for clarity.
Rik <rik@octave.org>
parents:
23212
diff
changeset
|
37 number, in fact, it is not a valid number at all. |
893d99338cc8
doc: Reword manual section on numeric constants for clarity.
Rik <rik@octave.org>
parents:
23212
diff
changeset
|
38 |
893d99338cc8
doc: Reword manual section on numeric constants for clarity.
Rik <rik@octave.org>
parents:
23212
diff
changeset
|
39 For better readability, digits may be partitioned by the underscore separator |
893d99338cc8
doc: Reword manual section on numeric constants for clarity.
Rik <rik@octave.org>
parents:
23212
diff
changeset
|
40 @samp{_}, which is ignored by the Octave interpreter. Here are some examples |
893d99338cc8
doc: Reword manual section on numeric constants for clarity.
Rik <rik@octave.org>
parents:
23212
diff
changeset
|
41 of real-valued integer constants, which all represent the same value and are |
893d99338cc8
doc: Reword manual section on numeric constants for clarity.
Rik <rik@octave.org>
parents:
23212
diff
changeset
|
42 internally stored as binary64: |
3294 | 43 |
44 @example | |
45 @group | |
23212
0881e1671490
doc: Add documentation for hex and binary prefix and _ separator(bugs #50305, #50334)
Ernst Reissner <rei3ner@arcor.de>
parents:
22323
diff
changeset
|
46 42 # decimal notation |
0881e1671490
doc: Add documentation for hex and binary prefix and _ separator(bugs #50305, #50334)
Ernst Reissner <rei3ner@arcor.de>
parents:
22323
diff
changeset
|
47 0x2A # hexadecimal notation |
0881e1671490
doc: Add documentation for hex and binary prefix and _ separator(bugs #50305, #50334)
Ernst Reissner <rei3ner@arcor.de>
parents:
22323
diff
changeset
|
48 0b101010 # binary notation |
0881e1671490
doc: Add documentation for hex and binary prefix and _ separator(bugs #50305, #50334)
Ernst Reissner <rei3ner@arcor.de>
parents:
22323
diff
changeset
|
49 0b10_1010 # underscore notation |
0881e1671490
doc: Add documentation for hex and binary prefix and _ separator(bugs #50305, #50334)
Ernst Reissner <rei3ner@arcor.de>
parents:
22323
diff
changeset
|
50 round (42.1) # also binary64 |
3294 | 51 @end group |
52 @end example | |
53 | |
23212
0881e1671490
doc: Add documentation for hex and binary prefix and _ separator(bugs #50305, #50334)
Ernst Reissner <rei3ner@arcor.de>
parents:
22323
diff
changeset
|
54 In decimal notation, the numeric constant may be denoted as decimal fraction |
0881e1671490
doc: Add documentation for hex and binary prefix and _ separator(bugs #50305, #50334)
Ernst Reissner <rei3ner@arcor.de>
parents:
22323
diff
changeset
|
55 or even in scientific (exponential) notation. Note that this is not possible |
23217
893d99338cc8
doc: Reword manual section on numeric constants for clarity.
Rik <rik@octave.org>
parents:
23212
diff
changeset
|
56 for hexadecimal or binary notation. Again, in the following example all |
23212
0881e1671490
doc: Add documentation for hex and binary prefix and _ separator(bugs #50305, #50334)
Ernst Reissner <rei3ner@arcor.de>
parents:
22323
diff
changeset
|
57 numeric constants represent the same value: |
3294 | 58 |
59 @example | |
60 @group | |
23212
0881e1671490
doc: Add documentation for hex and binary prefix and _ separator(bugs #50305, #50334)
Ernst Reissner <rei3ner@arcor.de>
parents:
22323
diff
changeset
|
61 .105 |
0881e1671490
doc: Add documentation for hex and binary prefix and _ separator(bugs #50305, #50334)
Ernst Reissner <rei3ner@arcor.de>
parents:
22323
diff
changeset
|
62 1.05e-1 |
0881e1671490
doc: Add documentation for hex and binary prefix and _ separator(bugs #50305, #50334)
Ernst Reissner <rei3ner@arcor.de>
parents:
22323
diff
changeset
|
63 .00105e+2 |
3294 | 64 @end group |
65 @end example | |
66 | |
23217
893d99338cc8
doc: Reword manual section on numeric constants for clarity.
Rik <rik@octave.org>
parents:
23212
diff
changeset
|
67 Unlike most programming languages, complex numeric constants are denoted as |
893d99338cc8
doc: Reword manual section on numeric constants for clarity.
Rik <rik@octave.org>
parents:
23212
diff
changeset
|
68 the sum of real and imaginary parts. The imaginary part is denoted by a |
893d99338cc8
doc: Reword manual section on numeric constants for clarity.
Rik <rik@octave.org>
parents:
23212
diff
changeset
|
69 real-valued numeric constant followed immediately by a complex value indicator |
893d99338cc8
doc: Reword manual section on numeric constants for clarity.
Rik <rik@octave.org>
parents:
23212
diff
changeset
|
70 (@samp{i}, @samp{j}, @samp{I}, or @samp{J} which represents |
3294 | 71 @tex |
23217
893d99338cc8
doc: Reword manual section on numeric constants for clarity.
Rik <rik@octave.org>
parents:
23212
diff
changeset
|
72 $\sqrt{-1}$). |
3294 | 73 @end tex |
6620 | 74 @ifnottex |
23217
893d99338cc8
doc: Reword manual section on numeric constants for clarity.
Rik <rik@octave.org>
parents:
23212
diff
changeset
|
75 @code{sqrt (-1)}). |
6620 | 76 @end ifnottex |
23217
893d99338cc8
doc: Reword manual section on numeric constants for clarity.
Rik <rik@octave.org>
parents:
23212
diff
changeset
|
77 No spaces are allowed between the numeric constant and the complex value |
893d99338cc8
doc: Reword manual section on numeric constants for clarity.
Rik <rik@octave.org>
parents:
23212
diff
changeset
|
78 indicator. Some examples of complex numeric constants that all represent the |
893d99338cc8
doc: Reword manual section on numeric constants for clarity.
Rik <rik@octave.org>
parents:
23212
diff
changeset
|
79 same value: |
3294 | 80 |
81 @example | |
82 @group | |
23212
0881e1671490
doc: Add documentation for hex and binary prefix and _ separator(bugs #50305, #50334)
Ernst Reissner <rei3ner@arcor.de>
parents:
22323
diff
changeset
|
83 3 + 42i |
0881e1671490
doc: Add documentation for hex and binary prefix and _ separator(bugs #50305, #50334)
Ernst Reissner <rei3ner@arcor.de>
parents:
22323
diff
changeset
|
84 3 + 42j |
0881e1671490
doc: Add documentation for hex and binary prefix and _ separator(bugs #50305, #50334)
Ernst Reissner <rei3ner@arcor.de>
parents:
22323
diff
changeset
|
85 3 + 42I |
0881e1671490
doc: Add documentation for hex and binary prefix and _ separator(bugs #50305, #50334)
Ernst Reissner <rei3ner@arcor.de>
parents:
22323
diff
changeset
|
86 3 + 42J |
0881e1671490
doc: Add documentation for hex and binary prefix and _ separator(bugs #50305, #50334)
Ernst Reissner <rei3ner@arcor.de>
parents:
22323
diff
changeset
|
87 3.0 + 42.0i |
0881e1671490
doc: Add documentation for hex and binary prefix and _ separator(bugs #50305, #50334)
Ernst Reissner <rei3ner@arcor.de>
parents:
22323
diff
changeset
|
88 3.0 + 0x2Ai |
0881e1671490
doc: Add documentation for hex and binary prefix and _ separator(bugs #50305, #50334)
Ernst Reissner <rei3ner@arcor.de>
parents:
22323
diff
changeset
|
89 3.0 + 0b10_1010i |
0881e1671490
doc: Add documentation for hex and binary prefix and _ separator(bugs #50305, #50334)
Ernst Reissner <rei3ner@arcor.de>
parents:
22323
diff
changeset
|
90 0.3e1 + 420e-1i |
3294 | 91 @end group |
92 @end example | |
93 | |
6549 | 94 @DOCSTRING(double) |
95 | |
96 @DOCSTRING(complex) | |
97 | |
3294 | 98 @menu |
7984
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
99 * Matrices:: |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
100 * Ranges:: |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
101 * Single Precision Data Types:: |
6549 | 102 * Integer Data Types:: |
6781 | 103 * Bit Manipulations:: |
17152
f2a8592b8fbd
doc: Shorten some long subsection names in Manual.
Rik <rik@octave.org>
parents:
17097
diff
changeset
|
104 * Logical Values:: |
7984
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
105 * Promotion and Demotion of Data Types:: |
17152
f2a8592b8fbd
doc: Shorten some long subsection names in Manual.
Rik <rik@octave.org>
parents:
17097
diff
changeset
|
106 * Predicates for Numeric Objects:: |
3294 | 107 @end menu |
108 | |
4167 | 109 @node Matrices |
3294 | 110 @section Matrices |
111 @cindex matrices | |
112 | |
113 @opindex [ | |
114 @opindex ] | |
115 @opindex ; | |
116 @opindex , | |
117 | |
118 It is easy to define a matrix of values in Octave. The size of the | |
119 matrix is determined automatically, so it is not necessary to explicitly | |
120 state the dimensions. The expression | |
121 | |
122 @example | |
123 a = [1, 2; 3, 4] | |
124 @end example | |
125 | |
126 @noindent | |
127 results in the matrix | |
128 @tex | |
129 $$ a = \left[ \matrix{ 1 & 2 \cr 3 & 4 } \right] $$ | |
130 @end tex | |
6620 | 131 @ifnottex |
3294 | 132 |
133 @example | |
134 @group | |
135 | |
136 / \ | |
137 | 1 2 | | |
138 a = | | | |
139 | 3 4 | | |
140 \ / | |
141 | |
142 @end group | |
143 @end example | |
10828
322f43e0e170
Grammarcheck .txi documentation files.
Rik <octave@nomad.inbox5.com>
parents:
10791
diff
changeset
|
144 |
6620 | 145 @end ifnottex |
3294 | 146 |
147 Elements of a matrix may be arbitrary expressions, provided that the | |
148 dimensions all make sense when combining the various pieces. For | |
149 example, given the above matrix, the expression | |
150 | |
151 @example | |
152 [ a, a ] | |
153 @end example | |
154 | |
155 @noindent | |
156 produces the matrix | |
157 | |
158 @example | |
159 @group | |
160 ans = | |
161 | |
162 1 2 1 2 | |
163 3 4 3 4 | |
164 @end group | |
165 @end example | |
166 | |
167 @noindent | |
168 but the expression | |
169 | |
170 @example | |
171 [ a, 1 ] | |
172 @end example | |
173 | |
174 @noindent | |
175 produces the error | |
176 | |
177 @example | |
8015
30629059b72d
Update the manual to reflect the changes in error output
sh@sh-laptop
parents:
7989
diff
changeset
|
178 error: number of rows must match (1 != 2) near line 13, column 6 |
3294 | 179 @end example |
180 | |
181 @noindent | |
182 (assuming that this expression was entered as the first thing on line | |
183 13, of course). | |
184 | |
185 Inside the square brackets that delimit a matrix expression, Octave | |
186 looks at the surrounding context to determine whether spaces and newline | |
187 characters should be converted into element and row separators, or | |
4476 | 188 simply ignored, so an expression like |
3294 | 189 |
190 @example | |
191 @group | |
192 a = [ 1 2 | |
193 3 4 ] | |
194 @end group | |
195 @end example | |
196 | |
197 @noindent | |
198 will work. However, some possible sources of confusion remain. For | |
199 example, in the expression | |
200 | |
201 @example | |
202 [ 1 - 1 ] | |
203 @end example | |
204 | |
205 @noindent | |
206 the @samp{-} is treated as a binary operator and the result is the | |
207 scalar 0, but in the expression | |
208 | |
209 @example | |
210 [ 1 -1 ] | |
211 @end example | |
212 | |
213 @noindent | |
214 the @samp{-} is treated as a unary operator and the result is the | |
4476 | 215 vector @code{[ 1, -1 ]}. Similarly, the expression |
216 | |
217 @example | |
218 [ sin (pi) ] | |
219 @end example | |
220 | |
221 @noindent | |
222 will be parsed as | |
223 | |
224 @example | |
225 [ sin, (pi) ] | |
226 @end example | |
3294 | 227 |
4476 | 228 @noindent |
229 and will result in an error since the @code{sin} function will be | |
230 called with no arguments. To get around this, you must omit the space | |
231 between @code{sin} and the opening parenthesis, or enclose the | |
232 expression in a set of parentheses: | |
233 | |
234 @example | |
235 [ (sin (pi)) ] | |
236 @end example | |
237 | |
238 Whitespace surrounding the single quote character (@samp{'}, used as a | |
239 transpose operator and for delimiting character strings) can also cause | |
240 confusion. Given @code{a = 1}, the expression | |
3294 | 241 |
242 @example | |
243 [ 1 a' ] | |
244 @end example | |
245 | |
246 @noindent | |
4476 | 247 results in the single quote character being treated as a |
3294 | 248 transpose operator and the result is the vector @code{[ 1, 1 ]}, but the |
249 expression | |
250 | |
251 @example | |
252 [ 1 a ' ] | |
253 @end example | |
254 | |
255 @noindent | |
256 produces the error message | |
257 | |
258 @example | |
9209
923c7cb7f13f
Simplify TeXinfo files by eliminating redundant @iftex followed by @tex construction.
Rik <rdrider0-list@yahoo.com>
parents:
9158
diff
changeset
|
259 @group |
8015
30629059b72d
Update the manual to reflect the changes in error output
sh@sh-laptop
parents:
7989
diff
changeset
|
260 parse error: |
30629059b72d
Update the manual to reflect the changes in error output
sh@sh-laptop
parents:
7989
diff
changeset
|
261 |
30629059b72d
Update the manual to reflect the changes in error output
sh@sh-laptop
parents:
7989
diff
changeset
|
262 syntax error |
30629059b72d
Update the manual to reflect the changes in error output
sh@sh-laptop
parents:
7989
diff
changeset
|
263 |
30629059b72d
Update the manual to reflect the changes in error output
sh@sh-laptop
parents:
7989
diff
changeset
|
264 >>> [ 1 a ' ] |
30629059b72d
Update the manual to reflect the changes in error output
sh@sh-laptop
parents:
7989
diff
changeset
|
265 ^ |
9209
923c7cb7f13f
Simplify TeXinfo files by eliminating redundant @iftex followed by @tex construction.
Rik <rdrider0-list@yahoo.com>
parents:
9158
diff
changeset
|
266 @end group |
3294 | 267 @end example |
268 | |
269 @noindent | |
6620 | 270 because not doing so would cause trouble when parsing the valid expression |
3294 | 271 |
272 @example | |
273 [ a 'foo' ] | |
274 @end example | |
275 | |
276 For clarity, it is probably best to always use commas and semicolons to | |
4476 | 277 separate matrix elements and rows. |
3294 | 278 |
12190
66b2c377b38e
Add sizemax function to documentation.
Rik <octave@nomad.inbox5.com>
parents:
11573
diff
changeset
|
279 The maximum number of elements in a matrix is fixed when Octave is compiled. |
66b2c377b38e
Add sizemax function to documentation.
Rik <octave@nomad.inbox5.com>
parents:
11573
diff
changeset
|
280 The allowable number can be queried with the function @code{sizemax}. Note |
66b2c377b38e
Add sizemax function to documentation.
Rik <octave@nomad.inbox5.com>
parents:
11573
diff
changeset
|
281 that other factors, such as the amount of memory available on your machine, |
66b2c377b38e
Add sizemax function to documentation.
Rik <octave@nomad.inbox5.com>
parents:
11573
diff
changeset
|
282 may limit the maximum size of matrices to something smaller. |
66b2c377b38e
Add sizemax function to documentation.
Rik <octave@nomad.inbox5.com>
parents:
11573
diff
changeset
|
283 |
66b2c377b38e
Add sizemax function to documentation.
Rik <octave@nomad.inbox5.com>
parents:
11573
diff
changeset
|
284 @DOCSTRING(sizemax) |
66b2c377b38e
Add sizemax function to documentation.
Rik <octave@nomad.inbox5.com>
parents:
11573
diff
changeset
|
285 |
3294 | 286 When you type a matrix or the name of a variable whose value is a |
287 matrix, Octave responds by printing the matrix in with neatly aligned | |
288 rows and columns. If the rows of the matrix are too large to fit on the | |
289 screen, Octave splits the matrix and displays a header before each | |
290 section to indicate which columns are being displayed. You can use the | |
291 following variables to control the format of the output. | |
292 | |
3321 | 293 @DOCSTRING(output_max_field_width) |
3294 | 294 |
3321 | 295 @DOCSTRING(output_precision) |
3294 | 296 |
297 It is possible to achieve a wide range of output styles by using | |
298 different values of @code{output_precision} and | |
299 @code{output_max_field_width}. Reasonable combinations can be set using | |
300 the @code{format} function. @xref{Basic Input and Output}. | |
301 | |
3321 | 302 @DOCSTRING(split_long_rows) |
3294 | 303 |
304 Octave automatically switches to scientific notation when values become | |
305 very large or very small. This guarantees that you will see several | |
306 significant figures for every value in a matrix. If you would prefer to | |
307 see all values in a matrix printed in a fixed point format, you can set | |
308 the built-in variable @code{fixed_point_format} to a nonzero value. But | |
309 doing so is not recommended, because it can produce output that can | |
310 easily be misinterpreted. | |
311 | |
3321 | 312 @DOCSTRING(fixed_point_format) |
3294 | 313 |
314 @menu | |
17152
f2a8592b8fbd
doc: Shorten some long subsection names in Manual.
Rik <rik@octave.org>
parents:
17097
diff
changeset
|
315 * Empty Matrices:: |
3294 | 316 @end menu |
317 | |
4167 | 318 @node Empty Matrices |
3294 | 319 @subsection Empty Matrices |
320 | |
321 A matrix may have one or both dimensions zero, and operations on empty | |
19040
0850b5212619
doc: Add @nospell macro around proper names in documentation.
Rik <rik@octave.org>
parents:
18900
diff
changeset
|
322 matrices are handled as described by @nospell{Carl de Boor} in |
0850b5212619
doc: Add @nospell macro around proper names in documentation.
Rik <rik@octave.org>
parents:
18900
diff
changeset
|
323 @cite{An Empty Exercise}, SIGNUM, Volume 25, pages 2-6, 1990 and |
0850b5212619
doc: Add @nospell macro around proper names in documentation.
Rik <rik@octave.org>
parents:
18900
diff
changeset
|
324 @nospell{C. N. Nett and W. M. Haddad}, in |
0850b5212619
doc: Add @nospell macro around proper names in documentation.
Rik <rik@octave.org>
parents:
18900
diff
changeset
|
325 @cite{A System-Theoretic Appropriate Realization of the Empty Matrix Concept}, |
0850b5212619
doc: Add @nospell macro around proper names in documentation.
Rik <rik@octave.org>
parents:
18900
diff
changeset
|
326 IEEE Transactions on Automatic Control, Volume 38, Number 5, May 1993. |
3294 | 327 @tex |
328 Briefly, given a scalar $s$, an $m\times n$ matrix $M_{m\times n}$, | |
329 and an $m\times n$ empty matrix $[\,]_{m\times n}$ (with either one or | |
330 both dimensions equal to zero), the following are true: | |
331 $$ | |
332 \eqalign{% | |
333 s \cdot [\,]_{m\times n} = [\,]_{m\times n} \cdot s &= [\,]_{m\times n}\cr | |
334 [\,]_{m\times n} + [\,]_{m\times n} &= [\,]_{m\times n}\cr | |
9209
923c7cb7f13f
Simplify TeXinfo files by eliminating redundant @iftex followed by @tex construction.
Rik <rdrider0-list@yahoo.com>
parents:
9158
diff
changeset
|
335 [\,]_{0\times m} \cdot M_{m\times n} &= [\,]_{0\times n}\cr |
3294 | 336 M_{m\times n} \cdot [\,]_{n\times 0} &= [\,]_{m\times 0}\cr |
337 [\,]_{m\times 0} \cdot [\,]_{0\times n} &= 0_{m\times n}} | |
338 $$ | |
339 @end tex | |
6620 | 340 @ifnottex |
3294 | 341 Briefly, given a scalar @var{s}, an @var{m} by |
342 @var{n} matrix @code{M(mxn)}, and an @var{m} by @var{n} empty matrix | |
343 @code{[](mxn)} (with either one or both dimensions equal to zero), the | |
344 following are true: | |
345 | |
346 @example | |
347 @group | |
348 s * [](mxn) = [](mxn) * s = [](mxn) | |
349 | |
350 [](mxn) + [](mxn) = [](mxn) | |
351 | |
352 [](0xm) * M(mxn) = [](0xn) | |
353 | |
354 M(mxn) * [](nx0) = [](mx0) | |
355 | |
356 [](mx0) * [](0xn) = 0(mxn) | |
357 @end group | |
358 @end example | |
10828
322f43e0e170
Grammarcheck .txi documentation files.
Rik <octave@nomad.inbox5.com>
parents:
10791
diff
changeset
|
359 |
6620 | 360 @end ifnottex |
3294 | 361 |
362 By default, dimensions of the empty matrix are printed along with the | |
363 empty matrix symbol, @samp{[]}. The built-in variable | |
364 @code{print_empty_dimensions} controls this behavior. | |
365 | |
3321 | 366 @DOCSTRING(print_empty_dimensions) |
3294 | 367 |
368 Empty matrices may also be used in assignment statements as a convenient | |
369 way to delete rows or columns of matrices. | |
17097
e7a059a9a644
doc: Use XREF as anchor prefix in documentation for clearer results in Info viewer.
Rik <rik@octave.org>
parents:
16939
diff
changeset
|
370 @xref{Assignment Ops,,Assignment Expressions}. |
3294 | 371 |
372 When Octave parses a matrix expression, it examines the elements of the | |
373 list to determine whether they are all constants. If they are, it | |
374 replaces the list with a single matrix constant. | |
375 | |
4167 | 376 @node Ranges |
3294 | 377 @section Ranges |
378 @cindex range expressions | |
379 @cindex expression, range | |
380 | |
11403
b8b08b1ac21f
Add missing operator functions to doc/interpreter.
Judd Storrs <jstorrs@gmail.com>
parents:
11392
diff
changeset
|
381 @opindex : |
3294 | 382 |
383 A @dfn{range} is a convenient way to write a row vector with evenly | |
384 spaced elements. A range expression is defined by the value of the first | |
385 element in the range, an optional value for the increment between | |
386 elements, and a maximum value which the elements of the range will not | |
387 exceed. The base, increment, and limit are separated by colons (the | |
388 @samp{:} character) and may contain any arithmetic expressions and | |
389 function calls. If the increment is omitted, it is assumed to be 1. | |
390 For example, the range | |
391 | |
392 @example | |
393 1 : 5 | |
394 @end example | |
395 | |
396 @noindent | |
22299
9fc91bb2aec3
doc: grammarcheck documentation for 4.2 release.
Rik <rik@octave.org>
parents:
20716
diff
changeset
|
397 defines the set of values @code{[ 1, 2, 3, 4, 5 ]}, and the range |
3294 | 398 |
399 @example | |
400 1 : 3 : 5 | |
401 @end example | |
402 | |
403 @noindent | |
22299
9fc91bb2aec3
doc: grammarcheck documentation for 4.2 release.
Rik <rik@octave.org>
parents:
20716
diff
changeset
|
404 defines the set of values @code{[ 1, 4 ]}. |
3294 | 405 |
406 Although a range constant specifies a row vector, Octave does @emph{not} | |
19394
b39cbe9f3bb0
allow ranges to be disabled
John W. Eaton <jwe@octave.org>
parents:
19040
diff
changeset
|
407 normally convert range constants to vectors unless it is necessary to do so. |
22299
9fc91bb2aec3
doc: grammarcheck documentation for 4.2 release.
Rik <rik@octave.org>
parents:
20716
diff
changeset
|
408 This allows you to write a constant like @code{1 : 10000} without using |
3294 | 409 80,000 bytes of storage on a typical 32-bit workstation. |
410 | |
11179
6ead75935ebf
Explain that ranges in vectors do get expanded
Jordi Gutiérrez Hermoso <jordigh@gmail.com>
parents:
10846
diff
changeset
|
411 A common example of when it does become necessary to convert ranges into |
11573
6f8ffe2c6f76
Grammarcheck txi files for 3.4 release.
Rik <octave@nomad.inbox5.com>
parents:
11523
diff
changeset
|
412 vectors occurs when they appear within a vector (i.e., inside square |
6f8ffe2c6f76
Grammarcheck txi files for 3.4 release.
Rik <octave@nomad.inbox5.com>
parents:
11523
diff
changeset
|
413 brackets). For instance, whereas |
11179
6ead75935ebf
Explain that ranges in vectors do get expanded
Jordi Gutiérrez Hermoso <jordigh@gmail.com>
parents:
10846
diff
changeset
|
414 |
6ead75935ebf
Explain that ranges in vectors do get expanded
Jordi Gutiérrez Hermoso <jordigh@gmail.com>
parents:
10846
diff
changeset
|
415 @example |
6ead75935ebf
Explain that ranges in vectors do get expanded
Jordi Gutiérrez Hermoso <jordigh@gmail.com>
parents:
10846
diff
changeset
|
416 x = 0 : 0.1 : 1; |
6ead75935ebf
Explain that ranges in vectors do get expanded
Jordi Gutiérrez Hermoso <jordigh@gmail.com>
parents:
10846
diff
changeset
|
417 @end example |
6ead75935ebf
Explain that ranges in vectors do get expanded
Jordi Gutiérrez Hermoso <jordigh@gmail.com>
parents:
10846
diff
changeset
|
418 |
11573
6f8ffe2c6f76
Grammarcheck txi files for 3.4 release.
Rik <octave@nomad.inbox5.com>
parents:
11523
diff
changeset
|
419 @noindent |
11179
6ead75935ebf
Explain that ranges in vectors do get expanded
Jordi Gutiérrez Hermoso <jordigh@gmail.com>
parents:
10846
diff
changeset
|
420 defines @var{x} to be a variable of type @code{range} and occupies 24 |
6ead75935ebf
Explain that ranges in vectors do get expanded
Jordi Gutiérrez Hermoso <jordigh@gmail.com>
parents:
10846
diff
changeset
|
421 bytes of memory, the expression |
6ead75935ebf
Explain that ranges in vectors do get expanded
Jordi Gutiérrez Hermoso <jordigh@gmail.com>
parents:
10846
diff
changeset
|
422 |
6ead75935ebf
Explain that ranges in vectors do get expanded
Jordi Gutiérrez Hermoso <jordigh@gmail.com>
parents:
10846
diff
changeset
|
423 @example |
6ead75935ebf
Explain that ranges in vectors do get expanded
Jordi Gutiérrez Hermoso <jordigh@gmail.com>
parents:
10846
diff
changeset
|
424 y = [ 0 : 0.1 : 1]; |
6ead75935ebf
Explain that ranges in vectors do get expanded
Jordi Gutiérrez Hermoso <jordigh@gmail.com>
parents:
10846
diff
changeset
|
425 @end example |
6ead75935ebf
Explain that ranges in vectors do get expanded
Jordi Gutiérrez Hermoso <jordigh@gmail.com>
parents:
10846
diff
changeset
|
426 |
11573
6f8ffe2c6f76
Grammarcheck txi files for 3.4 release.
Rik <octave@nomad.inbox5.com>
parents:
11523
diff
changeset
|
427 @noindent |
11179
6ead75935ebf
Explain that ranges in vectors do get expanded
Jordi Gutiérrez Hermoso <jordigh@gmail.com>
parents:
10846
diff
changeset
|
428 defines @var{y} to be of type @code{matrix} and occupies 88 bytes of |
6ead75935ebf
Explain that ranges in vectors do get expanded
Jordi Gutiérrez Hermoso <jordigh@gmail.com>
parents:
10846
diff
changeset
|
429 memory. |
6ead75935ebf
Explain that ranges in vectors do get expanded
Jordi Gutiérrez Hermoso <jordigh@gmail.com>
parents:
10846
diff
changeset
|
430 |
19394
b39cbe9f3bb0
allow ranges to be disabled
John W. Eaton <jwe@octave.org>
parents:
19040
diff
changeset
|
431 This space saving optimization may be disabled using the function |
b39cbe9f3bb0
allow ranges to be disabled
John W. Eaton <jwe@octave.org>
parents:
19040
diff
changeset
|
432 @dfn{disable_range}. |
b39cbe9f3bb0
allow ranges to be disabled
John W. Eaton <jwe@octave.org>
parents:
19040
diff
changeset
|
433 |
b39cbe9f3bb0
allow ranges to be disabled
John W. Eaton <jwe@octave.org>
parents:
19040
diff
changeset
|
434 @DOCSTRING(disable_range) |
b39cbe9f3bb0
allow ranges to be disabled
John W. Eaton <jwe@octave.org>
parents:
19040
diff
changeset
|
435 |
3294 | 436 Note that the upper (or lower, if the increment is negative) bound on |
437 the range is not always included in the set of values, and that ranges | |
438 defined by floating point values can produce surprising results because | |
439 Octave uses floating point arithmetic to compute the values in the | |
440 range. If it is important to include the endpoints of a range and the | |
441 number of elements is known, you should use the @code{linspace} function | |
442 instead (@pxref{Special Utility Matrices}). | |
443 | |
9158 | 444 When adding a scalar to a range, subtracting a scalar from it (or subtracting a |
445 range from a scalar) and multiplying by scalar, Octave will attempt to avoid | |
446 unpacking the range and keep the result as a range, too, if it can determine | |
9209
923c7cb7f13f
Simplify TeXinfo files by eliminating redundant @iftex followed by @tex construction.
Rik <rdrider0-list@yahoo.com>
parents:
9158
diff
changeset
|
447 that it is safe to do so. For instance, doing |
9158 | 448 |
449 @example | |
450 a = 2*(1:1e7) - 1; | |
451 @end example | |
452 | |
10846
a4f482e66b65
Grammarcheck more of the documentation.
Rik <octave@nomad.inbox5.com>
parents:
10828
diff
changeset
|
453 @noindent |
22299
9fc91bb2aec3
doc: grammarcheck documentation for 4.2 release.
Rik <rik@octave.org>
parents:
20716
diff
changeset
|
454 will produce the same result as @code{1:2:2e7-1}, but without ever forming a |
9158 | 455 vector with ten million elements. |
456 | |
22299
9fc91bb2aec3
doc: grammarcheck documentation for 4.2 release.
Rik <rik@octave.org>
parents:
20716
diff
changeset
|
457 Using zero as an increment in the colon notation, as @code{1:0:1} is not |
9158 | 458 allowed, because a division by zero would occur in determining the number of |
9209
923c7cb7f13f
Simplify TeXinfo files by eliminating redundant @iftex followed by @tex construction.
Rik <rdrider0-list@yahoo.com>
parents:
9158
diff
changeset
|
459 range elements. However, ranges with zero increment (i.e., all elements equal) |
9158 | 460 are useful, especially in indexing, and Octave allows them to be constructed |
22299
9fc91bb2aec3
doc: grammarcheck documentation for 4.2 release.
Rik <rik@octave.org>
parents:
20716
diff
changeset
|
461 using the built-in function @code{ones}. Note that because a range must be a |
9fc91bb2aec3
doc: grammarcheck documentation for 4.2 release.
Rik <rik@octave.org>
parents:
20716
diff
changeset
|
462 row vector, @code{ones (1, 10)} produces a range, while @code{ones (10, 1)} |
9fc91bb2aec3
doc: grammarcheck documentation for 4.2 release.
Rik <rik@octave.org>
parents:
20716
diff
changeset
|
463 does not. |
9158 | 464 |
3294 | 465 When Octave parses a range expression, it examines the elements of the |
466 expression to determine whether they are all constants. If they are, it | |
467 replaces the range expression with a single range constant. | |
468 | |
7984
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
469 @node Single Precision Data Types |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
470 @section Single Precision Data Types |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
471 |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
472 Octave includes support for single precision data types, and most of the |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
473 functions in Octave accept single precision values and return single |
9036
58604c45ca74
Cleanup of data types related documentation
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
474 precision answers. A single precision variable is created with the |
8534
0eb83938c8bc
Trivial fixes in numbers.txi
Thorsten Meyer <thorsten.meyier@gmx.de>
parents:
8347
diff
changeset
|
475 @code{single} function. |
7984
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
476 |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
477 @DOCSTRING(single) |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
478 |
10828
322f43e0e170
Grammarcheck .txi documentation files.
Rik <octave@nomad.inbox5.com>
parents:
10791
diff
changeset
|
479 for example: |
7984
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
480 |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
481 @example |
9209
923c7cb7f13f
Simplify TeXinfo files by eliminating redundant @iftex followed by @tex construction.
Rik <rdrider0-list@yahoo.com>
parents:
9158
diff
changeset
|
482 @group |
7984
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
483 sngl = single (rand (2, 2)) |
19593
446c46af4b42
strip trailing whitespace from most source files
John W. Eaton <jwe@octave.org>
parents:
17744
diff
changeset
|
484 @result{} sngl = |
8534
0eb83938c8bc
Trivial fixes in numbers.txi
Thorsten Meyer <thorsten.meyier@gmx.de>
parents:
8347
diff
changeset
|
485 0.37569 0.92982 |
0eb83938c8bc
Trivial fixes in numbers.txi
Thorsten Meyer <thorsten.meyier@gmx.de>
parents:
8347
diff
changeset
|
486 0.11962 0.50876 |
7984
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
487 class (sngl) |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
488 @result{} single |
9209
923c7cb7f13f
Simplify TeXinfo files by eliminating redundant @iftex followed by @tex construction.
Rik <rdrider0-list@yahoo.com>
parents:
9158
diff
changeset
|
489 @end group |
7984
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
490 @end example |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
491 |
9036
58604c45ca74
Cleanup of data types related documentation
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
492 Many functions can also return single precision values directly. For |
7984
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
493 example |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
494 |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
495 @example |
9209
923c7cb7f13f
Simplify TeXinfo files by eliminating redundant @iftex followed by @tex construction.
Rik <rdrider0-list@yahoo.com>
parents:
9158
diff
changeset
|
496 @group |
7984
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
497 ones (2, 2, "single") |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
498 zeros (2, 2, "single") |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
499 eye (2, 2, "single") |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
500 rand (2, 2, "single") |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
501 NaN (2, 2, "single") |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
502 NA (2, 2, "single") |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
503 Inf (2, 2, "single") |
9209
923c7cb7f13f
Simplify TeXinfo files by eliminating redundant @iftex followed by @tex construction.
Rik <rdrider0-list@yahoo.com>
parents:
9158
diff
changeset
|
504 @end group |
7984
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
505 @end example |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
506 |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
507 @noindent |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
508 will all return single precision matrices. |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
509 |
6549 | 510 @node Integer Data Types |
511 @section Integer Data Types | |
512 | |
6620 | 513 Octave supports integer matrices as an alternative to using double |
9036
58604c45ca74
Cleanup of data types related documentation
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
514 precision. It is possible to use both signed and unsigned integers |
58604c45ca74
Cleanup of data types related documentation
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
515 represented by 8, 16, 32, or 64 bits. It should be noted that most |
6620 | 516 computations require floating point data, meaning that integers will |
9036
58604c45ca74
Cleanup of data types related documentation
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
517 often change type when involved in numeric computations. For this |
6620 | 518 reason integers are most often used to store data, and not for |
519 calculations. | |
520 | |
521 In general most integer matrices are created by casting | |
9036
58604c45ca74
Cleanup of data types related documentation
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
522 existing matrices to integers. The following example shows how to cast |
6620 | 523 a matrix into 32 bit integers. |
524 | |
525 @example | |
9209
923c7cb7f13f
Simplify TeXinfo files by eliminating redundant @iftex followed by @tex construction.
Rik <rdrider0-list@yahoo.com>
parents:
9158
diff
changeset
|
526 @group |
6620 | 527 float = rand (2, 2) |
528 @result{} float = 0.37569 0.92982 | |
529 0.11962 0.50876 | |
530 integer = int32 (float) | |
531 @result{} integer = 0 1 | |
532 0 1 | |
9209
923c7cb7f13f
Simplify TeXinfo files by eliminating redundant @iftex followed by @tex construction.
Rik <rdrider0-list@yahoo.com>
parents:
9158
diff
changeset
|
533 @end group |
6620 | 534 @end example |
535 | |
536 @noindent | |
537 As can be seen, floating point values are rounded to the nearest integer | |
538 when converted. | |
539 | |
6549 | 540 @DOCSTRING(isinteger) |
541 | |
542 @DOCSTRING(int8) | |
543 | |
544 @DOCSTRING(uint8) | |
545 | |
546 @DOCSTRING(int16) | |
547 | |
548 @DOCSTRING(uint16) | |
549 | |
550 @DOCSTRING(int32) | |
551 | |
552 @DOCSTRING(uint32) | |
553 | |
554 @DOCSTRING(int64) | |
555 | |
556 @DOCSTRING(uint64) | |
557 | |
558 @DOCSTRING(intmax) | |
559 | |
560 @DOCSTRING(intmin) | |
561 | |
17390
4bcd301754ce
Add Matlab-compatible flintmax function
Mike Miller <mtmiller@ieee.org>
parents:
17281
diff
changeset
|
562 @DOCSTRING(flintmax) |
4bcd301754ce
Add Matlab-compatible flintmax function
Mike Miller <mtmiller@ieee.org>
parents:
17281
diff
changeset
|
563 |
6624 | 564 @menu |
565 * Integer Arithmetic:: | |
566 @end menu | |
567 | |
6620 | 568 @node Integer Arithmetic |
569 @subsection Integer Arithmetic | |
570 | |
571 While many numerical computations can't be carried out in integers, | |
572 Octave does support basic operations like addition and multiplication | |
9036
58604c45ca74
Cleanup of data types related documentation
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
573 on integers. The operators @code{+}, @code{-}, @code{.*}, and @code{./} |
58604c45ca74
Cleanup of data types related documentation
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
574 work on integers of the same type. So, it is possible to add two 32 bit |
6620 | 575 integers, but not to add a 32 bit integer and a 16 bit integer. |
576 | |
577 When doing integer arithmetic one should consider the possibility of | |
9036
58604c45ca74
Cleanup of data types related documentation
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
578 underflow and overflow. This happens when the result of the computation |
58604c45ca74
Cleanup of data types related documentation
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
579 can't be represented using the chosen integer type. As an example it is |
6620 | 580 not possible to represent the result of @math{10 - 20} when using |
9036
58604c45ca74
Cleanup of data types related documentation
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
581 unsigned integers. Octave makes sure that the result of integer |
58604c45ca74
Cleanup of data types related documentation
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
582 computations is the integer that is closest to the true result. So, the |
6620 | 583 result of @math{10 - 20} when using unsigned integers is zero. |
584 | |
585 When doing integer division Octave will round the result to the nearest | |
9036
58604c45ca74
Cleanup of data types related documentation
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
586 integer. This is different from most programming languages, where the |
58604c45ca74
Cleanup of data types related documentation
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
587 result is often floored to the nearest integer. So, the result of |
14856
c3fd61c59e9c
maint: Use Octave coding conventions for cuddling parentheses in doc directory
Rik <octave@nomad.inbox5.com>
parents:
14402
diff
changeset
|
588 @code{int32 (5) ./ int32 (8)} is @code{1}. |
6620 | 589 |
7984
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
590 @DOCSTRING(idivide) |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
591 |
6781 | 592 @node Bit Manipulations |
593 @section Bit Manipulations | |
594 | |
595 Octave provides a number of functions for the manipulation of numeric | |
9036
58604c45ca74
Cleanup of data types related documentation
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
596 values on a bit by bit basis. The basic functions to set and obtain the |
6781 | 597 values of individual bits are @code{bitset} and @code{bitget}. |
598 | |
599 @DOCSTRING(bitset) | |
600 | |
601 @DOCSTRING(bitget) | |
602 | |
603 The arguments to all of Octave's bitwise operations can be scalar or | |
604 arrays, except for @code{bitcmp}, whose @var{k} argument must a | |
9036
58604c45ca74
Cleanup of data types related documentation
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
605 scalar. In the case where more than one argument is an array, then all |
6781 | 606 arguments must have the same shape, and the bitwise operator is applied |
9036
58604c45ca74
Cleanup of data types related documentation
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
607 to each of the elements of the argument individually. If at least one |
6781 | 608 argument is a scalar and one an array, then the scalar argument is |
9036
58604c45ca74
Cleanup of data types related documentation
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
609 duplicated. Therefore |
6781 | 610 |
611 @example | |
612 bitget (100, 8:-1:1) | |
613 @end example | |
614 | |
10846
a4f482e66b65
Grammarcheck more of the documentation.
Rik <octave@nomad.inbox5.com>
parents:
10828
diff
changeset
|
615 @noindent |
6781 | 616 is the same as |
617 | |
618 @example | |
619 bitget (100 * ones (1, 8), 8:-1:1) | |
620 @end example | |
621 | |
622 It should be noted that all values passed to the bit manipulation | |
9036
58604c45ca74
Cleanup of data types related documentation
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
623 functions of Octave are treated as integers. Therefore, even though the |
6781 | 624 example for @code{bitset} above passes the floating point value |
625 @code{10}, it is treated as the bits @code{[1, 0, 1, 0]} rather than the | |
626 bits of the native floating point format representation of @code{10}. | |
627 | |
8828 | 628 As the maximum value that can be represented by a number is important |
6781 | 629 for bit manipulation, particularly when forming masks, Octave supplies |
20716
1ecee53513d7
doc: Peridodic grammar check of documentation.
Rik <rik@octave.org>
parents:
20486
diff
changeset
|
630 two utility functions: @code{flintmax} for floating point integers, and |
1ecee53513d7
doc: Peridodic grammar check of documentation.
Rik <rik@octave.org>
parents:
20486
diff
changeset
|
631 @code{intmax} for integer objects (@code{uint8}, @code{int64}, etc.). |
6781 | 632 |
17281
bc924baa2c4e
doc: Add new @qcode macro for code samples which are quoted.
Rik <rik@octave.org>
parents:
17152
diff
changeset
|
633 Octave also includes the basic bitwise 'and', 'or', and 'exclusive or' |
6781 | 634 operators. |
635 | |
636 @DOCSTRING(bitand) | |
637 | |
638 @DOCSTRING(bitor) | |
639 | |
640 @DOCSTRING(bitxor) | |
641 | |
8347
fa78cb8d8a5c
corrections for typos
Brian Gough<bjg@network-theory.co.uk>
parents:
8325
diff
changeset
|
642 The bitwise 'not' operator is a unary operator that performs a logical |
9036
58604c45ca74
Cleanup of data types related documentation
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
643 negation of each of the bits of the value. For this to make sense, the |
58604c45ca74
Cleanup of data types related documentation
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
644 mask against which the value is negated must be defined. Octave's |
6781 | 645 bitwise 'not' operator is @code{bitcmp}. |
646 | |
647 @DOCSTRING(bitcmp) | |
648 | |
8347
fa78cb8d8a5c
corrections for typos
Brian Gough<bjg@network-theory.co.uk>
parents:
8325
diff
changeset
|
649 Octave also includes the ability to left-shift and right-shift values bitwise. |
6781 | 650 |
651 @DOCSTRING(bitshift) | |
652 | |
9036
58604c45ca74
Cleanup of data types related documentation
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
653 Bits that are shifted out of either end of the value are lost. Octave |
8347
fa78cb8d8a5c
corrections for typos
Brian Gough<bjg@network-theory.co.uk>
parents:
8325
diff
changeset
|
654 also uses arithmetic shifts, where the sign bit of the value is kept |
10828
322f43e0e170
Grammarcheck .txi documentation files.
Rik <octave@nomad.inbox5.com>
parents:
10791
diff
changeset
|
655 during a right shift. For example: |
6781 | 656 |
657 @example | |
658 @group | |
659 bitshift (-10, -1) | |
660 @result{} -5 | |
661 bitshift (int8 (-1), -1) | |
662 @result{} -1 | |
663 @end group | |
664 @end example | |
665 | |
666 Note that @code{bitshift (int8 (-1), -1)} is @code{-1} since the bit | |
667 representation of @code{-1} in the @code{int8} data type is @code{[1, 1, | |
668 1, 1, 1, 1, 1, 1]}. | |
669 | |
4167 | 670 @node Logical Values |
3428 | 671 @section Logical Values |
672 | |
9036
58604c45ca74
Cleanup of data types related documentation
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
673 Octave has built-in support for logical values, i.e., variables that |
58604c45ca74
Cleanup of data types related documentation
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
674 are either @code{true} or @code{false}. When comparing two variables, |
6620 | 675 the result will be a logical value whose value depends on whether or |
676 not the comparison is true. | |
677 | |
678 The basic logical operations are @code{&}, @code{|}, and @code{!}, | |
8347
fa78cb8d8a5c
corrections for typos
Brian Gough<bjg@network-theory.co.uk>
parents:
8325
diff
changeset
|
679 which correspond to ``Logical And'', ``Logical Or'', and ``Logical |
9036
58604c45ca74
Cleanup of data types related documentation
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
680 Negation''. These operations all follow the usual rules of logic. |
6620 | 681 |
682 It is also possible to use logical values as part of standard numerical | |
9036
58604c45ca74
Cleanup of data types related documentation
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
683 calculations. In this case @code{true} is converted to @code{1}, and |
6620 | 684 @code{false} to 0, both represented using double precision floating |
9036
58604c45ca74
Cleanup of data types related documentation
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
685 point numbers. So, the result of @code{true*22 - false/6} is @code{22}. |
6620 | 686 |
687 Logical values can also be used to index matrices and cell arrays. | |
688 When indexing with a logical array the result will be a vector containing | |
689 the values corresponding to @code{true} parts of the logical array. | |
690 The following example illustrates this. | |
691 | |
692 @example | |
9209
923c7cb7f13f
Simplify TeXinfo files by eliminating redundant @iftex followed by @tex construction.
Rik <rdrider0-list@yahoo.com>
parents:
9158
diff
changeset
|
693 @group |
6620 | 694 data = [ 1, 2; 3, 4 ]; |
695 idx = (data <= 2); | |
696 data(idx) | |
9136
537a73861cb7
Fix small mistake in example.
Ansgar Burchard <ansgar@43-1.org>
parents:
9036
diff
changeset
|
697 @result{} ans = [ 1; 2 ] |
9209
923c7cb7f13f
Simplify TeXinfo files by eliminating redundant @iftex followed by @tex construction.
Rik <rdrider0-list@yahoo.com>
parents:
9158
diff
changeset
|
698 @end group |
6620 | 699 @end example |
700 | |
701 @noindent | |
702 Instead of creating the @code{idx} array it is possible to replace | |
11376
567ca09a97aa
Remove obsolete documentation about 64-bit integer arithmetic.
Rik <octave@nomad.inbox5.com>
parents:
11179
diff
changeset
|
703 @code{data(idx)} with @w{@code{data( data <= 2 )}} in the above code. |
6620 | 704 |
8828 | 705 Logical values can also be constructed by |
6620 | 706 casting numeric objects to logical values, or by using the @code{true} |
707 or @code{false} functions. | |
708 | |
6549 | 709 @DOCSTRING(logical) |
710 | |
3428 | 711 @DOCSTRING(true) |
712 | |
713 @DOCSTRING(false) | |
714 | |
7984
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
715 @node Promotion and Demotion of Data Types |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
716 @section Promotion and Demotion of Data Types |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
717 |
10828
322f43e0e170
Grammarcheck .txi documentation files.
Rik <octave@nomad.inbox5.com>
parents:
10791
diff
changeset
|
718 Many operators and functions can work with mixed data types. For example, |
7984
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
719 |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
720 @example |
9209
923c7cb7f13f
Simplify TeXinfo files by eliminating redundant @iftex followed by @tex construction.
Rik <rdrider0-list@yahoo.com>
parents:
9158
diff
changeset
|
721 @group |
7984
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
722 uint8 (1) + 1 |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
723 @result{} 2 |
9209
923c7cb7f13f
Simplify TeXinfo files by eliminating redundant @iftex followed by @tex construction.
Rik <rdrider0-list@yahoo.com>
parents:
9158
diff
changeset
|
724 @end group |
7984
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
725 @end example |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
726 |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
727 @noindent |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
728 where the above operator works with an 8-bit integer and a double precision |
9036
58604c45ca74
Cleanup of data types related documentation
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
729 value and returns an 8-bit integer value. Note that the type is demoted |
7984
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
730 to an 8-bit integer, rather than promoted to a double precision value as |
9036
58604c45ca74
Cleanup of data types related documentation
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
731 might be expected. The reason is that if Octave promoted values in |
7984
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
732 expressions like the above with all numerical constants would need to be |
9036
58604c45ca74
Cleanup of data types related documentation
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
733 explicitly cast to the appropriate data type like |
7984
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
734 |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
735 @example |
9209
923c7cb7f13f
Simplify TeXinfo files by eliminating redundant @iftex followed by @tex construction.
Rik <rdrider0-list@yahoo.com>
parents:
9158
diff
changeset
|
736 @group |
7984
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
737 uint8 (1) + uint8 (1) |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
738 @result{} 2 |
9209
923c7cb7f13f
Simplify TeXinfo files by eliminating redundant @iftex followed by @tex construction.
Rik <rdrider0-list@yahoo.com>
parents:
9158
diff
changeset
|
739 @end group |
7984
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
740 @end example |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
741 |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
742 @noindent |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
743 which becomes difficult for the user to apply uniformly and might allow |
9036
58604c45ca74
Cleanup of data types related documentation
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
744 hard to find bugs to be introduced. The same applies to single precision |
7984
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
745 values where a mixed operation such as |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
746 |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
747 @example |
9209
923c7cb7f13f
Simplify TeXinfo files by eliminating redundant @iftex followed by @tex construction.
Rik <rdrider0-list@yahoo.com>
parents:
9158
diff
changeset
|
748 @group |
7984
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
749 single (1) + 1 |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
750 @result{} 2 |
9209
923c7cb7f13f
Simplify TeXinfo files by eliminating redundant @iftex followed by @tex construction.
Rik <rdrider0-list@yahoo.com>
parents:
9158
diff
changeset
|
751 @end group |
7984
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
752 @end example |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
753 |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
754 @noindent |
9036
58604c45ca74
Cleanup of data types related documentation
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
755 returns a single precision value. The mixed operations that are valid |
7984
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
756 and their returned data types are |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
757 |
7989
23c248d415b5
Various doc fixes. Readd cellidx
David Bateman <dbateman@free.fr>
parents:
7984
diff
changeset
|
758 @multitable @columnfractions .2 .3 .3 .2 |
19593
446c46af4b42
strip trailing whitespace from most source files
John W. Eaton <jwe@octave.org>
parents:
17744
diff
changeset
|
759 @headitem @tab Mixed Operation @tab Result @tab |
7984
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
760 @item @tab double OP single @tab single @tab |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
761 @item @tab double OP integer @tab integer @tab |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
762 @item @tab double OP char @tab double @tab |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
763 @item @tab double OP logical @tab double @tab |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
764 @item @tab single OP integer @tab integer @tab |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
765 @item @tab single OP char @tab single @tab |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
766 @item @tab single OP logical @tab single @tab |
7989
23c248d415b5
Various doc fixes. Readd cellidx
David Bateman <dbateman@free.fr>
parents:
7984
diff
changeset
|
767 @end multitable |
7984
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
768 |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
769 The same logic applies to functions with mixed arguments such as |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
770 |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
771 @example |
9209
923c7cb7f13f
Simplify TeXinfo files by eliminating redundant @iftex followed by @tex construction.
Rik <rdrider0-list@yahoo.com>
parents:
9158
diff
changeset
|
772 @group |
7984
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
773 min (single (1), 0) |
7989
23c248d415b5
Various doc fixes. Readd cellidx
David Bateman <dbateman@free.fr>
parents:
7984
diff
changeset
|
774 @result{} 0 |
9209
923c7cb7f13f
Simplify TeXinfo files by eliminating redundant @iftex followed by @tex construction.
Rik <rdrider0-list@yahoo.com>
parents:
9158
diff
changeset
|
775 @end group |
7984
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
776 @end example |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
777 |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
778 @noindent |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
779 where the returned value is single precision. |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
780 |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
781 In the case of mixed type indexed assignments, the type is not |
10828
322f43e0e170
Grammarcheck .txi documentation files.
Rik <octave@nomad.inbox5.com>
parents:
10791
diff
changeset
|
782 changed. For example, |
7984
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
783 |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
784 @example |
9209
923c7cb7f13f
Simplify TeXinfo files by eliminating redundant @iftex followed by @tex construction.
Rik <rdrider0-list@yahoo.com>
parents:
9158
diff
changeset
|
785 @group |
7984
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
786 x = ones (2, 2); |
14402
cbcaf5602469
doc: Make spacing nicer for Strings chapter of manual.
Rik <octave@nomad.inbox5.com>
parents:
14138
diff
changeset
|
787 x(1, 1) = single (2) |
cbcaf5602469
doc: Make spacing nicer for Strings chapter of manual.
Rik <octave@nomad.inbox5.com>
parents:
14138
diff
changeset
|
788 @result{} x = 2 1 |
cbcaf5602469
doc: Make spacing nicer for Strings chapter of manual.
Rik <octave@nomad.inbox5.com>
parents:
14138
diff
changeset
|
789 1 1 |
9209
923c7cb7f13f
Simplify TeXinfo files by eliminating redundant @iftex followed by @tex construction.
Rik <rdrider0-list@yahoo.com>
parents:
9158
diff
changeset
|
790 @end group |
7984
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
791 @end example |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
792 |
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
793 @noindent |
19593
446c46af4b42
strip trailing whitespace from most source files
John W. Eaton <jwe@octave.org>
parents:
17744
diff
changeset
|
794 where @code{x} remains of the double precision type. |
7984
bbaa5d7d0143
Some documentation updates
David Bateman <dbateman@free.fr>
parents:
7638
diff
changeset
|
795 |
4167 | 796 @node Predicates for Numeric Objects |
3294 | 797 @section Predicates for Numeric Objects |
798 | |
6620 | 799 Since the type of a variable may change during the execution of a |
9036
58604c45ca74
Cleanup of data types related documentation
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
800 program, it can be necessary to do type checking at run-time. Doing this |
58604c45ca74
Cleanup of data types related documentation
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
801 also allows you to change the behavior of a function depending on the |
58604c45ca74
Cleanup of data types related documentation
Rik <rdrider0-list@yahoo.com>
parents:
8920
diff
changeset
|
802 type of the input. As an example, this naive implementation of @code{abs} |
7001 | 803 returns the absolute value of the input if it is a real number, and the |
6620 | 804 length of the input if it is a complex number. |
805 | |
806 @example | |
9209
923c7cb7f13f
Simplify TeXinfo files by eliminating redundant @iftex followed by @tex construction.
Rik <rdrider0-list@yahoo.com>
parents:
9158
diff
changeset
|
807 @group |
6620 | 808 function a = abs (x) |
809 if (isreal (x)) | |
810 a = sign (x) .* x; | |
811 elseif (iscomplex (x)) | |
812 a = sqrt (real(x).^2 + imag(x).^2); | |
813 endif | |
814 endfunction | |
9209
923c7cb7f13f
Simplify TeXinfo files by eliminating redundant @iftex followed by @tex construction.
Rik <rdrider0-list@yahoo.com>
parents:
9158
diff
changeset
|
815 @end group |
6620 | 816 @end example |
817 | |
818 The following functions are available for determining the type of a | |
819 variable. | |
820 | |
3428 | 821 @DOCSTRING(isnumeric) |
822 | |
18900
49961d67e4b9
Add new matrix functions (isdiag, isbanded, istril, istriu) (bug #42688).
Massimiliano Fasi <massimiliano.fasi@gmail.com>
parents:
17744
diff
changeset
|
823 @DOCSTRING(islogical) |
49961d67e4b9
Add new matrix functions (isdiag, isbanded, istril, istriu) (bug #42688).
Massimiliano Fasi <massimiliano.fasi@gmail.com>
parents:
17744
diff
changeset
|
824 |
12581
c8be316f9543
Group commonly used isXXX functions together in documentation.
Rik <octave@nomad.inbox5.com>
parents:
12488
diff
changeset
|
825 @DOCSTRING(isfloat) |
3428 | 826 |
12581
c8be316f9543
Group commonly used isXXX functions together in documentation.
Rik <octave@nomad.inbox5.com>
parents:
12488
diff
changeset
|
827 @DOCSTRING(isreal) |
7638
2df457529cfa
implement expm1 and log1p functions
Jaroslav Hajek <highegg@gmail.com>
parents:
7018
diff
changeset
|
828 |
4029 | 829 @DOCSTRING(iscomplex) |
3428 | 830 |
4029 | 831 @DOCSTRING(ismatrix) |
3294 | 832 |
4029 | 833 @DOCSTRING(isvector) |
3294 | 834 |
12488
bea828c03969
Add new isrow, iscolumn functions.
Rik <octave@nomad.inbox5.com>
parents:
12190
diff
changeset
|
835 @DOCSTRING(isrow) |
bea828c03969
Add new isrow, iscolumn functions.
Rik <octave@nomad.inbox5.com>
parents:
12190
diff
changeset
|
836 |
bea828c03969
Add new isrow, iscolumn functions.
Rik <octave@nomad.inbox5.com>
parents:
12190
diff
changeset
|
837 @DOCSTRING(iscolumn) |
bea828c03969
Add new isrow, iscolumn functions.
Rik <octave@nomad.inbox5.com>
parents:
12190
diff
changeset
|
838 |
4029 | 839 @DOCSTRING(isscalar) |
3294 | 840 |
4029 | 841 @DOCSTRING(issquare) |
3294 | 842 |
4029 | 843 @DOCSTRING(issymmetric) |
3428 | 844 |
11431
0d9640d755b1
Improve docstrings for all isXXX functions.
Rik <octave@nomad.inbox5.com>
parents:
11403
diff
changeset
|
845 @DOCSTRING(ishermitian) |
0d9640d755b1
Improve docstrings for all isXXX functions.
Rik <octave@nomad.inbox5.com>
parents:
11403
diff
changeset
|
846 |
6550 | 847 @DOCSTRING(isdefinite) |
848 | |
18900
49961d67e4b9
Add new matrix functions (isdiag, isbanded, istril, istriu) (bug #42688).
Massimiliano Fasi <massimiliano.fasi@gmail.com>
parents:
17744
diff
changeset
|
849 @DOCSTRING(isbanded) |
49961d67e4b9
Add new matrix functions (isdiag, isbanded, istril, istriu) (bug #42688).
Massimiliano Fasi <massimiliano.fasi@gmail.com>
parents:
17744
diff
changeset
|
850 |
49961d67e4b9
Add new matrix functions (isdiag, isbanded, istril, istriu) (bug #42688).
Massimiliano Fasi <massimiliano.fasi@gmail.com>
parents:
17744
diff
changeset
|
851 @DOCSTRING(isdiag) |
49961d67e4b9
Add new matrix functions (isdiag, isbanded, istril, istriu) (bug #42688).
Massimiliano Fasi <massimiliano.fasi@gmail.com>
parents:
17744
diff
changeset
|
852 |
49961d67e4b9
Add new matrix functions (isdiag, isbanded, istril, istriu) (bug #42688).
Massimiliano Fasi <massimiliano.fasi@gmail.com>
parents:
17744
diff
changeset
|
853 @DOCSTRING(istril) |
49961d67e4b9
Add new matrix functions (isdiag, isbanded, istril, istriu) (bug #42688).
Massimiliano Fasi <massimiliano.fasi@gmail.com>
parents:
17744
diff
changeset
|
854 |
49961d67e4b9
Add new matrix functions (isdiag, isbanded, istril, istriu) (bug #42688).
Massimiliano Fasi <massimiliano.fasi@gmail.com>
parents:
17744
diff
changeset
|
855 @DOCSTRING(istriu) |
6550 | 856 |
857 @DOCSTRING(isprime) | |
13017
aaf6fbb2512f
doc: Add cross references to "status of variables" in sections for predicates
Jordi Gutiérrez Hermoso <jordigh@gmail.com>
parents:
12581
diff
changeset
|
858 |
aaf6fbb2512f
doc: Add cross references to "status of variables" in sections for predicates
Jordi Gutiérrez Hermoso <jordigh@gmail.com>
parents:
12581
diff
changeset
|
859 If instead of knowing properties of variables, you wish to know which |
aaf6fbb2512f
doc: Add cross references to "status of variables" in sections for predicates
Jordi Gutiérrez Hermoso <jordigh@gmail.com>
parents:
12581
diff
changeset
|
860 variables are defined and to gather other information about the |
17097
e7a059a9a644
doc: Use XREF as anchor prefix in documentation for clearer results in Info viewer.
Rik <rik@octave.org>
parents:
16939
diff
changeset
|
861 workspace itself, @pxref{Status of Variables}. |