Algebraic.eval
evaluate an Algebraic expression
Calling Sequence
Description
Examples
Algebraic eval() throws MapleException
The eval function evaluates the Maple expression represented by the current Algebraic object and returns the result as a new Algebraic.
The current Algebraic object is unchanged by this call.
import com.maplesoft.openmaple.*;
import com.maplesoft.externalcall.MapleException;
class Example
{
public static void main( String notused[] ) throws MapleException
String[] mapleArgs = { "java" };
Engine engine = new Engine( mapleArgs, new EngineCallBacksDefault(), null, null );
Algebraic a1 = engine.evaluate( "''int''(x,x):" );
Algebraic a2 = a1.eval( );
System.out.println( "a1 = "+a1 );
System.out.println( "a2 = "+a2 );
}
Executing this code should produce the following output.
a1 = int(x,x)
a2 = 1/2*x^2
See Also
eval
ExternalCalling/Java/MapleException
OpenMaple
OpenMaple/Java/Algebraic
OpenMaple/Java/API
OpenMaple/Java/Engine/evaluate
Download Help Document