Return to Application List


Download from Android market(Free).

This is calculator application. You input a calculating formula in polish notation, and the result is displayed when you push the "eval" button.

The polish notation is notation same as "lisp". However, this application does not have compatibility with "lisp".

You can input expression with system standard IME, phisycal keyboard, and numeric keypad on screen.

Numeric keypad can swipe to left. Buttons on right side are use to move calet.

Built-in functions listed side of keypad.

When long-tap item on list, show context menu.

If long tap built-in function, show reference of function on web.

If your defined function, show menu Edit or Delete function.

Polish notation

The polish notation writes an operator first and is a format to write a value for the operation next. By this application, I fill in the both ends of the expression with a parenthesis and show the range of the expression.

1 + 2 + 3 (+ 1 2 3)

You can expression into other expression to value.

1 + (2 * 3) + 4 - 2 (- (+ 1 (* 2 3)) 2)

Functions reference

Click here to implements default functions list.


Define user define expression.
Find function name including input word currentry.
Sorry, no preferences user can setting yet.

User define expression

Function name.
Argument name. IF input plural arguments, separate in space.
(example: a b c)
Optional arguments
When receive an indefinite numerical argument, turn on this check box. Then the argument which I appointed a lot from the number that input in "Arguments" is stored away by the name of "&REST" by a list and can refer.
Input expression.

Save this expression and can use it for a function. When this expression has error, it is saved as "Draft", and it is returns string "<DRAFT>" when evaluate it for a function.
Discard this modify and revert expression to before called Activity.

The polish notation writes an operator first and is a format to write a value for the operation next. By this application, I fill in the both ends of the expression with a parenthesis and show the range of the expression.

When select "Defun..." of the menu when cursor is on word, show source of function if this word is user-defined function. You can edit it.

Auto complete function name

When select "Find..." of the menu when you duaring the input of word, Search and display functions include the input word in name. If find only one function, input this function automatically.


Choise "Prefs..." menu on main screen. configuration preferences.

Use ICS style
If checked, use GUI style of "Ice Cream Sandwich". Can setting if your device is "Android4.0" or newer.

This setting item is reflected since I started application next.
Hide ten-key buttons
If checked, hide a numeric keypad and a list of functions and "evaluation" button. Push "Shift + Enter" on physical keyboard on end of expression to evaluate. And push "Alt + Enter", show built-in function reference on web site.

Decimal place
Number of the figures when I display the decimal value. For example, if set 3. "3.14159265" displays "3.142".
Zero Padding
Bury the beam which remained with the decimal value with 0. For example, "0.5" displays "0.500".
Evaluate time limit
Time of the maximum that I can use for an evaluation by a second unit. For example, an evaluation is stopped when I set "10" when an evaluation is not over within 10 seconds. When I set "0", wait until evaluations are always finished (NOT RECOMMEND).
Stack depth limit
Maximum depth of the stack to use for the evaluation of the expression. When I define the function to call recursively, I can stop it forcibly even if it is the contents which I continue calling forever. When I set 0, I call it without any restriction and enable it
Show evaluate time
Display the time that processing took when an evaluation was completed by millimeters second unit. This value is an aim and is not a value right closely.

Call from other application.

This application regist intent filter, scheme type "lisp://". Your application can call clCalclator to evaluate expression by Intent.

Simple case.

If you will evaluate one expression, you launch startActivityForResult method with Intent:

Simple case can reference user-defined function regist on clCalc application, but cannot define new function and symbol by Intent.

extra data
Set string extra your expression with named "expression".

clCalc launch Activity and just close. Activity returns:

resultCode (2nd argument of Activity#onAvtivityResult method)
If evaluation succeeded, returns Activity.RESULT_OK. If failed, returns Activity.RESULT_CANCELED
extra data RESULT (String)
set only evaluate succeeded. result of expression.
extra data ERROR (String)
set only occured exception when evaluate. description message of exception.

If you will use macro and values.

Please see How to use Intent from your application.

Example of simple case.

private void callClCalc() {
	Intent i = new Intent(Intent.ACTION_RUN, Uri.parse("lisp://"));
	i.putExtra("expression", "(+ 1 2 3)");
	startActivityForResult(i, 0);

public void onActivityResult(int requestCode, int resultCode, Intent data) {
	String result;
	if(resultCode == Activity.RESULT_OK) {
		// returns 6.
		result = "SUCCESS: " + data.getStringExtra("result");
	} else {
		result = "FAILED: " + data.getStringExtra("error");
	Toast.makeText(this, result, Toast.LENGTH_SHORT).show();



Return to Application List