home *** CD-ROM | disk | FTP | other *** search
/ Geek Gadgets 1 / ADE-1.bin / ade-dist / octave-1.1.1p1-base.tgz / octave-1.1.1p1-base.tar / fsf / octave / src / arith-ops.h < prev    next >
C/C++ Source or Header  |  1996-09-27  |  3KB  |  102 lines

  1. // arith-ops.h                                        -*- C++ -*-
  2. /*
  3.  
  4. Copyright (C) 1992, 1993, 1994, 1995 John W. Eaton
  5.  
  6. This file is part of Octave.
  7.  
  8. Octave is free software; you can redistribute it and/or modify it
  9. under the terms of the GNU General Public License as published by the
  10. Free Software Foundation; either version 2, or (at your option) any
  11. later version.
  12.  
  13. Octave is distributed in the hope that it will be useful, but WITHOUT
  14. ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  15. FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  16. for more details.
  17.  
  18. You should have received a copy of the GNU General Public License
  19. along with Octave; see the file COPYING.  If not, write to the Free
  20. Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
  21.  
  22. */
  23.  
  24. #if !defined (octave_arith_ops_h)
  25. #define octave_arith_ops_h 1
  26.  
  27. #include "tree-expr.h"
  28.  
  29. template <class T> class complex;
  30. typedef complex<double> Complex;
  31.  
  32. class Matrix;
  33. class ComplexMatrix;
  34. class tree_constant;
  35.  
  36. extern tree_constant do_unary_op (double d, tree_expression::type t);
  37.  
  38. extern tree_constant do_unary_op (const Matrix& a, tree_expression::type t);
  39.  
  40. extern tree_constant do_unary_op (const Complex& c, tree_expression::type t);
  41.  
  42. extern tree_constant do_unary_op (const ComplexMatrix& a,
  43.                   tree_expression::type t);
  44.  
  45. extern tree_constant do_binary_op (double a, double b,
  46.                    tree_expression::type t);
  47.  
  48. extern tree_constant do_binary_op (double a, const Matrix& b,
  49.                    tree_expression::type t);
  50.  
  51. extern tree_constant do_binary_op (double a, const Complex& b,
  52.                    tree_expression::type t);
  53.  
  54. extern tree_constant do_binary_op (double a, const ComplexMatrix& b,
  55.                    tree_expression::type t);
  56.  
  57. extern tree_constant do_binary_op (const Matrix& a, double b,
  58.                    tree_expression::type t);
  59.  
  60. extern tree_constant do_binary_op (const Matrix& a, const Matrix& b,
  61.                    tree_expression::type t);
  62.  
  63. extern tree_constant do_binary_op (const Matrix& a, const Complex& b,
  64.                    tree_expression::type t);
  65.  
  66. extern tree_constant do_binary_op (const Matrix& a, const ComplexMatrix& b,
  67.                    tree_expression::type t);
  68.  
  69. extern tree_constant do_binary_op (const Complex& a, double b,
  70.                    tree_expression::type t);
  71.  
  72. extern tree_constant do_binary_op (const Complex& a, const Matrix& b,
  73.                    tree_expression::type t);
  74.  
  75. extern tree_constant do_binary_op (const Complex& a, const Complex& b,
  76.                    tree_expression::type t);
  77.  
  78. extern tree_constant do_binary_op (const Complex& a, const ComplexMatrix& b,
  79.                    tree_expression::type t);
  80.  
  81. extern tree_constant do_binary_op (const ComplexMatrix& a, double b,
  82.                    tree_expression::type t);
  83.  
  84. extern tree_constant do_binary_op (const ComplexMatrix& a, const Matrix& b,
  85.                    tree_expression::type t); 
  86.  
  87. extern tree_constant do_binary_op (const ComplexMatrix& a, const Complex& b,
  88.                    tree_expression::type t); 
  89.  
  90. extern tree_constant do_binary_op (const ComplexMatrix& a,
  91.                    const ComplexMatrix& b,
  92.                    tree_expression::type t); 
  93.  
  94. #endif
  95.  
  96. /*
  97. ;;; Local Variables: ***
  98. ;;; mode: C++ ***
  99. ;;; page-delimiter: "^/\\*" ***
  100. ;;; End: ***
  101. */
  102.