Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.lsmp.djep.vectorJep.function
Class MAdd

    java.lang.Object
      org.nfunk.jep.function.PostfixMathCommand
          org.nfunk.jep.function.Add
              org.lsmp.djep.vectorJep.function.MAdd

All Implemented Interfaces:
  BinaryOperatorI, PostfixMathCommandI

    public class MAdd

extends Add
implements BinaryOperatorI

An extension of the Add command to allow it to add MVector's and Matrix's.

Author:
  Rich Morris Created on 27-Jul-2003

Field Summary

Fields inherited from class org.nfunk.jep.function.PostfixMathCommand
`curNumberOfParameters, numberOfParameters`

Constructor Summary
`MAdd()`

Method Summary
`Matrix` | `add(Matrix lhs, Matrix rhs)` Adds two matrices.
`MVector` | `add(MVector lhs, MVector rhs)` Adds two vectors.
`java.lang.Object` | `add(java.lang.Object param1, java.lang.Object param2)` Adds two objects.
`Tensor` | `add(Tensor lhs, Tensor rhs)` Adds two tensors.
`Dimensions` | `calcDim(Dimensions ldim, Dimensions rdim)` Find the dimensions of this operator when applied to arguments with given dimensions.
`MatrixValueI` | `calcValue(MatrixValueI res, MatrixValueI lhs, MatrixValueI rhs)` calculates the value.

Methods inherited from class org.nfunk.jep.function.Add
`add, add, add, run`

Methods inherited from class org.nfunk.jep.function.PostfixMathCommand
`checkNumberOfParameters, checkStack, getNumberOfParameters, setCurNumberOfParameters`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Methods inherited from interface org.nfunk.jep.function.PostfixMathCommandI
`checkNumberOfParameters, getNumberOfParameters, run, setCurNumberOfParameters`

Constructor Detail

### MAdd

    public MAdd()

Method Detail

### calcDim

    public Dimensions calcDim(Dimensions ldim,
                              Dimensions rdim)

  Description copied from interface: `BinaryOperatorI`
  Find the dimensions of this operator when applied to arguments with given dimensions.

  Specified by:
    `calcDim` in interface `BinaryOperatorI`

### calcValue

    public MatrixValueI calcValue(MatrixValueI res,
                                  MatrixValueI lhs,
                                  MatrixValueI rhs)
                           throws ParseException

  calculates the value.

  Specified by:
    `calcValue` in interface `BinaryOperatorI`
  Parameters:
    `res` - - results will be stored in this object
    `lhs` - - lhs value
    `rhs` - - rhs value
  Returns:
    res
  Throws:
    `ParseException`

### add

    public java.lang.Object add(java.lang.Object param1,
                                java.lang.Object param2)
                         throws ParseException

  Adds two objects.

  Overrides:
    `add` in class `Add`
  Parameters:
    `param1` - The first parameter to be added.
    `param2` - The second parameter to be added.
  Returns:
    The sum of param1 and param2, or concatenation of the two if they are Strings.
  Throws:
    `ParseException`

### add

    public MVector add(MVector lhs,
                       MVector rhs)
                throws ParseException

  Adds two vectors.

  Throws:
    `ParseException`

### add

    public Matrix add(Matrix lhs,
                      Matrix rhs)
               throws ParseException

  Adds two matrices.

  Throws:
    `ParseException`

### add

    public Tensor add(Tensor lhs,
                      Tensor rhs)
               throws ParseException

  Adds two tensors.

  Throws:
    `ParseException`

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

http://www.singularsys.com/jep Copyright © 2007 Singular Systems