Project Members

B7 Y2321 Ravishankar Sundararaman shankars@iitk.ac.in
B8 Y2360 Shanthanu Bhardwaj shanth@iitk.ac.in
B8 Y2414 Veeramani V veera@iitk.ac.in

 

Project Title

Java Ultimate Mathematical PackageŽ (JUMP)

 

Objective

The aim of this project is to create a GUI-based application for plotting graphs of mathematical functions, solving mathematical equations, calcultion of derivative & integrals (numerically), solving differential equations (numerically) upto order 2, other mathematical operations and functions such as determinants etc.

 

Program Design

How JUMP is being programmed: This program is being programmed using the following Java IDE's :BlueJ, J Creator & Forte for Java.

How JUMP will work: The program parses the given mathematical expression and converts it into postfix notation. Eg: 7*8+6/(5-2) is stored by the program as:
7 8 * 6 5 2 - / + and the expression is evaluated as follows , the numbers are read and stored (pushed) in a stack. Whenever an operation is encountered the program pops an element from the stack and performs the operation and pushes the result onto the stack. In this way the expression is evaluated.

Notations & conventions used in the source code: In this program the expression is parsed and stored as an array of short type (int could also be used but short was used so as to consume less memory). Mathematical operators and functions are assigned a numerical code for storing them in the stack.

 

Sample I/O

INPUT: Mathematical expression such as : exp(sin(x))
OUTPUT:
 
INPUT:Math equation such as : f(x) = x^2-2x+1 {solve for f(x)=0}
OUTPUT: x=1.0
 
INPUT:Differential Equation : d2y/dx2 + 9y = 0 {y=0 at x=0 and y=1 at x=pi/6
OUTPUT: