MyExcel Spreadsheet
email: gbosmis@yahoo.com
webpage: www.geocities.com/gbosmis
Source Code: www.geocities.com/gbosmis/MyExcel.zip
March 9 2004
Introduction
MyExcel is a simple spreadsheet developed with rapidq free basic compiler. For example, open the spreadsheet and type in a cell:
=(cos(pi())+3^(3*2))/(7/5-1)
and press enter.
You can reference to another cell by the function cell(i;j) were
i: is the col number
j: is the row number
There are many other functions (see 'function help' inside the program about the syntax).
Options Window
Auto Recalc Option: Recalculates Sheet when a cell is changed. Keep this option disabled if you want to recalculate the sheet manually for speed reasons.
Auto Check Syntax Option: When Disabled the program doesn't check cells for syntax errors and the speed is increased.
Quick Fill Window
Open a New Sheet
Open Quick Fill Window (by pressing the appropriate button)
Type A1 and A10 for the beginning and ending of the cell range respectively.
Type in the formula
=rnd(1)
Press Fill
Type A1 and J10 for the beginning and ending of the cell range respectively.
Type in the formula
=(Row-1)*100+(Col-1)*10
Press Fill
Monte Carlo Simulation Window
You have to estimate the cost of a new product. The formula describing the cost is
10 + 50/(sales in thousands) + (labor cost per unit)
we expect sales in thousands to be uniformly distributed between 10000 and 20000
we expect labor cost per unit to be uniformly distributed between 2 and 3
we open a new sheet and we type in cell A1:
=10*(1+rnd(1)) (this is the sales)
we type in cell A2
=2+rnd(1) (this is the labor cost)
we type in cell A3
=10+50/cell(1;1)+cell(1;2) (this is the cost formula)
Now we open the Monte Carlo simulation window
We type 100 for the number of iterations, A3 for the cell we want to record (this is the cell who contains the cost formula), and C1 for the destination cell that the outputs will go. After that just press Monte.
This is just a simple model. You can construct far more complex models using other distributions that your inputs follow (for example normal).
Import a File
This option is used for importing text (Tab delimited or Comma delimited) or CSV files into MyExcel.
Solver Window
It is an algorithm for finding the inputs that maximize a cell's function.
Open a New Sheet
Type 1 in cell A1
Type 1 in cell A2
Type 1 in cell A3
In cell B1 type:
=sin(cell(1;1))+2*cos(cell(1;2))-sin(cell(1;3))
(this is the function that we want maximize)
Open Solver
Choose Input Cell Range from A1 to A3
Choose maximizing Cell B1
Press Solve
Functions List
The build-in functions currently available in MyExcel are:
sin, cos, tan, sinh, cosh, tanh, cot, sec, csc, sqrt, log, ln, inv, exp, abs int, frac, cbrt, square, fact, degrees, radians, pi, asin, acos, atan cub, rnd, combin, permut, power, binomdist, poisson, normdist, cell, sum, average, var normsdist, normsinv, chidist, chiinv, fdist, finv, tdist, tinv, correl, covar, product gr, eq, greq, noteq, and, or, if, pv, fv, pmt, nper, skew, kurt