An object that represents a symbolic expression in Mathematica. More...
Public Member Functions | |
SymExpression (x, varargin) | |
The class constructor function. More... | |
function | delete () |
object destruction function More... | |
function | display (namestr) |
Display the symbolic expression. More... | |
function y = | argnames () |
Symbolic function input variables ARGNAMES(F) returns a sym array [X1, X2, ... ] of symbolic variables for F(X1, X2, ...). More... | |
function x = | formula () |
Symbolic expression formula body FORMULA(F) returns the definition of symbolic function F as a sym object expression. More... | |
function x = | symbol () |
Symbolic expression symbol string SYMBOL(F) returns the symbolc string of symbolic expression F as a sym object expression. More... | |
function y = | privToCell () |
function y = | length () |
The length of the symbolic vector LENGTH(X) returns the length of vector X. It is equivalent to MAX(SIZE(X)) for non-empty arrays and 0 for empty ones. More... | |
function varargout = | size () |
The size of the symbolic expression tensor. More... | |
function status = | islist () |
Check if the symbolic expression is a scalar (non-list) More... | |
function X = | first () |
function B = | uminus () |
------------— Arithmetic --------------— Symbolic negation. More... | |
function B = | uplus () |
Unary plus. More... | |
function X = | plus (B) |
Symbolic plus operation. More... | |
function X = | minus (B) |
Symbolic minus operation. More... | |
function X = | times (B) |
Symbolic array multiplication. TIMES(A,B) overloads symbolic A .* B. More... | |
function X = | mtimes (B) |
Symbolic matrix multiplication. MTIMES(A,B) overloads symbolic A * B. More... | |
function B = | mpower (p) |
Symbolic matrix power. MPOWER(A,p) overloads symbolic A^p. More... | |
function B = | power (p) |
Symbolic array power. POWER(A,p) overloads symbolic A.^p. More... | |
function X = | rdivide (B) |
Symbolic array right division. RDIVIDE(A,B) overloads symbolic A ./ B. More... | |
function X = | ldivide (B) |
Symbolic array left division. LDIVIDE(A,B) overloads symbolic A . B. More... | |
function X = | mrdivide (B) |
/ Slash or symbolic right matrix divide. A/B is the matrix division of B into A, which is roughly the same as A*INV(B) , except it is computed in a different way. More precisely, A / B = (B \ A )'. See SYM/MLDIVIDE for details. Warning messages are produced if X does not exist or is not unique. Rectangular matrices A are allowed, but the equations must be consistent; a least squares solution is not computed. More... | |
function X = | mldivide (B) |
Symbolic matrix left division. MLDIVIDE(A,B) overloads symbolic A \ B. X = A \ B solves the symbolic linear equations A*X = B. Warning messages are produced if X does not exist or is not unique. Rectangular matrices A are allowed, but the equations must be consistent; a least squares solution is not computed. More... | |
function B = | transpose () |
Symbolic matrix transpose. TRANSPOSE(A) overloads symbolic A.' . More... | |
function B = | ctranspose () |
Symbolic matrix complex conjugate transpose. CTRANSPOSE(A) overloads symbolic A' . More... | |
function B = | inv () |
Symbolic matrix inverse. INV(A) computes the symbolic inverse of A INV(VPA(A)) uses variable precision arithmetic. More... | |
function y = | eq (B) |
Symbolic equality test. EQ(A,B) overloads symbolic A == B. If A and B are integers, rational numbers, floating point values or complex numbers then A == B compares the values and returns true or false. Otherwise A == B returns a sym object of the unevaluated equation which can be passed to other functions like solve. To force the equation to perform a comparison call LOGICAL or isAlways. LOGICAL will compare the two sides structurally. isAlways will compare the two sides mathematically. More... | |
function y = | ne (B) |
NE Symbolic inequality test. NE(A,B) overloads symbolic A ~= B. The result is the opposite of A == B. More... | |
function C = | subsasgn (Idx, R) |
Subscripted assignment for a sym array. C = SUBSASGN(L,Idx,R) is called for the syntax L(Idx)=R. Idx is a structure array with the fields: type – string containing () specifying the subscript type. Only parenthesis subscripting is allowed. subs – Cell array or string containing the actual subscripts. More... | |
function B = | subsref (Idx) |
Subscripted reference for a sym array. B = SUBSREF(A,S) is called for the syntax A(I). S is a structure array with the fields: type – string containing () specifying the subscript type. Only parenthesis subscripting is allowed. subs – Cell array or string containing the actual subscripts. More... | |
function y = | end (varargin) |
Last index in an indexing expression for a sym array. END(A,K,N) is called for indexing expressions involving the sym array A when END is part of the K-th index out of N indices. For example, the expression A(end-1,:) calls A's END method with END(A,1,2). More... | |
function X = | double () |
Converts symbolic matrix to MATLAB double. DOUBLE(S) converts the symbolic matrix S to a matrix of double precision floating point numbers. S must not contain any symbolic variables, except eps . More... | |
function M = | char () |
Convert scalar or array sym to string. CHAR(A) returns a string representation of the symbolic object A in MuPAD syntax. More... | |
function [ SymExpression obj , file , SymExpression obj ] = | load (char file_path, file,SymExpression obj, varargin,SymExpression obj,char file_path, file) |
load the saved symbolic expression from a wolframe MX file More... | |
Protected Attributes | |
char | f |
The body (or formula) of the symbolic expression. More... | |
char | s |
The symbol that represents the symbolic expression. More... | |
Additional Inherited Members | |
Public Attributes inherited from handle | |
addlistener | |
Creates a listener for the specified event and assigns a callback function to execute when the event occurs. More... | |
notify | |
Broadcast a notice that a specific event is occurring on a specified handle object or array of handle objects. More... | |
delete | |
Handle object destructor method that is called when the object's lifecycle ends. More... | |
disp | |
Handle object disp method which is called by the display method. See the MATLAB disp function. More... | |
display | |
Handle object display method called when MATLAB software interprets an expression returning a handle object that is not terminated by a semicolon. See the MATLAB display function. More... | |
findobj | |
Finds objects matching the specified conditions from the input array of handle objects. More... | |
findprop | |
Returns a meta.property objects associated with the specified property name. More... | |
fields | |
Returns a cell array of string containing the names of public properties. More... | |
fieldnames | |
Returns a cell array of string containing the names of public properties. See the MATLAB fieldnames function. More... | |
isvalid | |
Returns a logical array in which elements are true if the corresponding elements in the input array are valid handles. This method is Sealed so you cannot override it in a handle subclass. More... | |
eq | |
Relational functions example. See details for more information. More... | |
transpose | |
Transposes the elements of the handle object array. More... | |
permute | |
Rearranges the dimensions of the handle object array. See the MATLAB permute function. More... | |
reshape | |
hanges the dimensions of the handle object array to the specified dimensions. See the MATLAB reshape function. More... | |
sort | |
ort the handle objects in any array in ascending or descending order. More... | |
Detailed Description
An object that represents a symbolic expression in Mathematica.
Copyright (c) 2016-2017, AMBER Lab All right reserved.
Redistribution and use in source and binary forms, with or without modification, are permitted only in compliance with the BSD 3-Clause license, see http://www.opensource.org/licenses/bsd-license.php
Constructor & Destructor Documentation
◆ SymExpression()
|
inline |
The class constructor function.
- Parameters
-
x it could be one of the followings: - SymExpression: it will copy one SymExpression object to antother
- numeric: create a numeric symbolic expression
- char: create symbolic expression specified by
x
- Required fields of x:
Referenced by SymVariable.subsref(), and SymVariable.SymVariable().
Member Function Documentation
◆ argnames()
|
inline |
Symbolic function input variables ARGNAMES(F) returns a sym array [X1, X2, ... ] of symbolic variables for F(X1, X2, ...).
◆ char()
|
inline |
Convert scalar or array sym to string. CHAR(A) returns a string representation of the symbolic object A in MuPAD syntax.
- Note
- This method has the MATLAB method attribute
Hidden
set to true. - matlab documentation of method attributes.
◆ ctranspose()
|
inline |
Symbolic matrix complex conjugate transpose. CTRANSPOSE(A) overloads symbolic A' .
- Example
- [a b; 1-i c]' returns [ conj(a), 1+i] [ conj(b), conj(c)].
- See also
- SYM/TRANSPOSE.
◆ delete()
|
inline |
object destruction function
◆ display()
|
inline |
Display the symbolic expression.
◆ double()
|
inline |
Converts symbolic matrix to MATLAB double. DOUBLE(S) converts the symbolic matrix S to a matrix of double precision floating point numbers. S must not contain any symbolic variables, except eps
.
- See also
- SYM, VPA.
- Note
- This method has the MATLAB method attribute
Hidden
set to true. - matlab documentation of method attributes.
◆ end()
|
inline |
Last index in an indexing expression for a sym array. END(A,K,N) is called for indexing expressions involving the sym array A when END is part of the K-th index out of N indices. For example, the expression A(end-1,:) calls A's END method with END(A,1,2).
- See also
- SYM.
- Note
- This method has the MATLAB method attribute
Hidden
set to true. - matlab documentation of method attributes.
◆ eq()
|
inline |
Symbolic equality test. EQ(A,B) overloads symbolic A == B. If A and B are integers, rational numbers, floating point values or complex numbers then A == B compares the values and returns true or false. Otherwise A == B returns a sym object of the unevaluated equation which can be passed to other functions like solve. To force the equation to perform a comparison call LOGICAL or isAlways. LOGICAL will compare the two sides structurally. isAlways will compare the two sides mathematically.
- See also
- SYM/LOGICAL, SYM/isAlways
- Required fields of B:
◆ first()
|
inline |
◆ formula()
|
inline |
Symbolic expression formula body FORMULA(F) returns the definition of symbolic function F as a sym object expression.
◆ inv()
|
inline |
Symbolic matrix inverse. INV(A) computes the symbolic inverse of A INV(VPA(A)) uses variable precision arithmetic.
- Examples
- Suppose B is [ 1/(2-t), 1/(3-t) ] [ 1/(3-t), 1/(4-t) ]
Then inv(B) is [ -(-3+t)^2*(-2+t), (-3+t)*(-2+t)*(-4+t) ] [ (-3+t)*(-2+t)*(-4+t), -(-3+t)^2*(-4+t) ]
◆ islist()
|
inline |
Check if the symbolic expression is a scalar (non-list)
◆ ldivide()
|
inline |
Symbolic array left division. LDIVIDE(A,B) overloads symbolic A . B.
- See also
- SYM/RDIVIDE, SYM/MRDIVIDE, SYM/MLDIVIDE, SYM/QUOREM.
- Required fields of B:
◆ length()
|
inline |
The length of the symbolic vector LENGTH(X) returns the length of vector X. It is equivalent to MAX(SIZE(X)) for non-empty arrays and 0 for empty ones.
- See also
- NUMEL, SIZE
◆ load()
function SymExpression obj = SymExpression.load | ( | char | file_path, |
file, | |||
SymExpression | obj, | ||
varargin, | |||
SymExpression | obj, | ||
char | file_path, | ||
file | |||
) |
load the saved symbolic expression from a wolframe MX file
- Parameters
-
file_path the path to export the file filename the (full) file name of exported file obj the expressions other than the main object
- Note
- This method has the MATLAB method attribute
Hidden
set to true. - matlab documentation of method attributes.
◆ minus()
|
inline |
Symbolic minus operation.
- Required fields of B:
◆ mldivide()
|
inline |
Symbolic matrix left division. MLDIVIDE(A,B) overloads symbolic A \ B. X = A \ B solves the symbolic linear equations A*X = B. Warning messages are produced if X does not exist or is not unique. Rectangular matrices A are allowed, but the equations must be consistent; a least squares solution is not computed.
- See also
- SYM/MRDIVIDE, SYM/LDIVIDE, SYM/RDIVIDE, SYM/QUOREM.
- Required fields of B:
◆ mpower()
|
inline |
Symbolic matrix power. MPOWER(A,p) overloads symbolic A^p.
Example; A = [x y; alpha 2] A^2 returns [x^2+alpha*y x*y+2*y; alpha*x+2*alpha alpha*y+4].
- Required fields of p:
◆ mrdivide()
|
inline |
/ Slash or symbolic right matrix divide. A/B is the matrix division of B into A, which is roughly the same as A*INV(B) , except it is computed in a different way. More precisely, A / B = (B \ A
)'. See SYM/MLDIVIDE for details. Warning messages are produced if X does not exist or is not unique. Rectangular matrices A are allowed, but the equations must be consistent; a least squares solution is not computed.
- See also
- SYM/MLDIVIDE, SYM/RDIVIDE, SYM/LDIVIDE, SYM/QUOREM.
- Required fields of B:
◆ mtimes()
|
inline |
Symbolic matrix multiplication. MTIMES(A,B) overloads symbolic A * B.
- Required fields of B:
◆ ne()
|
inline |
NE Symbolic inequality test. NE(A,B) overloads symbolic A ~= B. The result is the opposite of A == B.
- Required fields of B:
◆ plus()
|
inline |
Symbolic plus operation.
- Required fields of B:
◆ power()
|
inline |
Symbolic array power. POWER(A,p) overloads symbolic A.^p.
- Examples
- A = [x 10 y; alpha 2 5]; A .^ 2 returns [x^2 100 y^2; alpha^2 4 25]. A .^ x returns [x^x 10^x y^x; alpha^x 2^x 5^x]. A .^ A returns [x^x 1.0000e+10 y^y; alpha^alpha 4 3125]. A .^ [1 2 3; 4 5 6] returns [x 100 y^3; alpha^4 32 15625]. A .^ magic(3) is an error.
- Required fields of p:
◆ privToCell()
|
inline |
◆ rdivide()
|
inline |
Symbolic array right division. RDIVIDE(A,B) overloads symbolic A ./ B.
- See also
- SYM/LDIVIDE, SYM/MRDIVIDE, SYM/MLDIVIDE, SYM/QUOREM.
- Required fields of B:
◆ size()
|
inline |
The size of the symbolic expression tensor.
- See also
- NUMEL, LENGTH
◆ subsasgn()
|
inline |
Subscripted assignment for a sym array. C = SUBSASGN(L,Idx,R) is called for the syntax L(Idx)=R. Idx is a structure array with the fields: type – string containing ()
specifying the subscript type. Only parenthesis subscripting is allowed. subs – Cell array or string containing the actual subscripts.
- See also
- SYM.
- Required fields of Idx:
- Note
- This method has the MATLAB method attribute
Hidden
set to true. - matlab documentation of method attributes.
◆ subsref()
|
inline |
Subscripted reference for a sym array. B = SUBSREF(A,S) is called for the syntax A(I). S is a structure array with the fields: type – string containing ()
specifying the subscript type. Only parenthesis subscripting is allowed. subs – Cell array or string containing the actual subscripts.
- Required fields of Idx:
- Note
- This method has the MATLAB method attribute
Hidden
set to true. - matlab documentation of method attributes.
◆ symbol()
|
inline |
Symbolic expression symbol string SYMBOL(F) returns the symbolc string of symbolic expression F as a sym object expression.
◆ times()
|
inline |
Symbolic array multiplication. TIMES(A,B) overloads symbolic A .* B.
- Required fields of B:
◆ transpose()
|
inline |
Symbolic matrix transpose. TRANSPOSE(A) overloads symbolic A.' .
- Example
- [a b; 1-i c].' returns [a 1-i; b c].
- See also
- SYM/CTRANSPOSE.
◆ uminus()
|
inline |
------------— Arithmetic --------------— Symbolic negation.
◆ uplus()
|
inline |
Unary plus.
Member Data Documentation
◆ f
|
protected |
The body (or formula) of the symbolic expression.
◆ s
|
protected |
The symbol that represents the symbolic expression.
The documentation for this class was generated from the following files:
- /home/ayonga/.dropboxes/business/Dropbox/research/dzopt/frost/matlab/symbolic/@SymExpression/SymExpression.m
- /home/ayonga/.dropboxes/business/Dropbox/research/dzopt/frost/matlab/symbolic/@SymExpression/load.m