The Function Simulator (from http://www.marcolombardo.it/)
with Java API: J2SDK 1.4.2 , Jfreechart 0.9.11 , Jcommon 0.8.6
This is java standalone application that shows a mathematic function in one or more charts. You can use the standard notation for the mathematic function like this:
2x sin x
and Input field is 2*x*sin(x)
You can normally use the rounds for some precedence expression.
You can use simply operators like :
/, * , %, + , -, ^
Costants like:
pi, exp or e.
The all Function operators are:
sqrt(), cos(), sen(), tan(), log() or ln(), asin or arcsin,
acos or arccos, atan or arctan, abs (absolute value)
The Domain input is a collection of drawing points of chart in ascending and exclusive mode, like :
[ x(1) I , x(1) F [; [ x(2) I , x(2) F [; ... ;
where x(i) F > x(i) I and x(i) F < x(i+1) I , i = 1,2, ..
The software architecture uses four parts:
Click HERE to see the image.
Math Function Parser |
This component parses the mathematic function and splits it in token for the next converter. |
Math Function Infix-PostFix Converter |
This component traslate the function infix notation to postfix notation. This is for the elaboration of all points of the mathematic function. |
Charts Manager |
Component to manage the function in relation with relative domains. |
Domain Parser |
Parser for the user domains and start-up component for chart manager. |
The Simulator has three text fields, two check-boxes, two push-buttons and a text-area that is the consolle.
In the text field named ' Enter the Function' the mathematical function in variable x is introduced.
In the 'Domain field' the mathematical domain is introduced (in which representing the mathematical function). Every domain is subdivided in one or more sub-domains.
Every sub-domains is constituted from two decimal values (in increasing order) separated from a comma. Every sub-domains is separated from others by a ';'. Every sub-domains must have greater values of the previous one and more small of the successive one, and, moreover, its values must be mutually exclusive regarding the others (do not have to be inner to other domains).
The 'RUN' button elaborates and shows the chart (or charts in relation of the user domains)
Click HERE to see the image.
The simulator shows the diagram, the response of the consolle and push-buttons are added to show other charts in relation of the user domains.
Click HERE to see the image.
For example, pressing the push-button ' Next Chart' the other portion of the mathematical function is shown in the next domain.
You notice yourself that aiming the mouse at the diagram, it is possible to visualize the mathematic values of the point.
Click HERE to see the image.
Or with the right button is possible to zoom the function.
Click HERE to see the image.
Pressing the 'New Function' button is possible to reset all fields and restarts with a new function.
The check-boxes are 'Auto' and 'Custom' and they identify the type of step-elaboration that is wanted to be made.
With 'auto' option the elaboration of the mathematic values is automatic. With 'custom' option the elaboration of the mathematic values will happen at times with the set up value.
This field is named 'Enter step' s value' (the elaboration will happen with a linear interpolation in points that are equidistant from the others from distance that is equal at the set up value.
Click HERE to see the image.
In the sub menu is possible to see the Info and the Help for the Simulator.
HERE TO RUN AND INSTALL THE FUNCTION SIMULATOR STANDALONE (The application run with the Java Network Launching Protocol, than you need Java Web Start).
HERE TO SEE JavaDoc of the FUNCTION SIMULATOR STANDALONE Application. If you have questions or other, you can email to me.
HERE TO See THE FUNCTION SIMULATOR Server Side Version (Servlet and JSP).
Go to Main Project JaSPEnT on http