Abstract:
The present invention relates generally to the field of information processing by digital computers and, more particularly, to the entry and processing of information by application programs, particularly spreadsheets. The present invention is an electronic mathematical model builder that comprises a memory for storage of data, a processor for defining addressable sets of cells stored in the memory with a unique identifier, for entering data into the cells and for processing data stored in the cells, a user interface with a display for displaying sets of cells in a work area and means for creating and positioning sets of cells in the work area and inputting data to be entered into the cells, and a function builder for building mathematical relations between cells, comprising fields for user specification of a desired function by mathematical operators and input variables of the function, and set of destination cells containing values of the function.

Description:
FIELD OF THE INVENTION  
       [0001]     The present invention relates generally to the field of information processing by digital computers and, more particularly, to the entry and processing of information by application programs, particularly spreadsheets.  
       BACKGROUND OF THE INVENTION  
       [0002]     The present description relies on technical terms used in connection with operation of a spreadsheet program, including spreadsheet formulas, for an overview see e.g. Microsoft Excel 2002 Bible, John Walkenbach, John Wiley &amp; Sons Inc; ISBN: 0764535838.  
         [0003]     Before computers, numerical analyses, particularly financial analyses, were usually prepared on an accountant&#39;s columnar pad or spreadsheet, with pencil and calculator in hand. By organizing data into columns and rows, spreadsheets afford the rapid assimilation of information by a reader. The task of preparing a spreadsheet on paper, however, is not quite so fast. Instead, the process tends to be very slow, as each entry must be tediously calculated and entered into the spreadsheet. Since all calculations are the responsibility of the person preparing the spreadsheet, manually prepared spreadsheets are also prone to errors. Hence, preparation of spreadsheets by hand is slow, tedious, and unreliable.  
         [0004]     With the advent of microcomputers, a solution was forthcoming in the form of “electronic spreadsheets.” Better known simply as “spreadsheets,” these software programs provide a computerized replacement for the traditional financial modelling tools: The accountant&#39;s columnar pad, pencil, and calculator. The improvement represented by a spreadsheet program over these tools may be compared with the improvement provided by a word processor over a typewriter. Spreadsheets offer a dramatic improvement in ease of creating, editing, and using financial models.  
         [0005]     A spreadsheet provides millions of cells grouped together in a single sheet or document. A single cell may contain a value, a label or a formula. In a conventional spreadsheet, millions of cells are provided even though only e.g. 25 cells are needed for a specific task. A conventional spreadsheet typically offers 256 columns and 65536 rows amounting to 16,777,216 cells. Most of the cells are not visible. A standard monitor typically displays about 500 cells at the time (33 rows by 15 columns). If a spreadsheet model covers more than 33 rows or 15 columns on a standard monitor, the user will either have to scroll up and down to manage or work with the spreadsheet model or open different windows e.g. showing different parts of the model at the time.  
         [0006]     Data is entered into an electronic spreadsheet in much the same way as an accountant enters information on his pad. After the user has positioned a screen cursor at a desired location (a cell), the user can enter alphanumeric information. Besides holding text and numerical information, however, spreadsheet cells can store special instructions or formulas specifying calculations to be performed on the data stored in spreadsheet cells. This is in fact one of the major disadvantages of conventional spreadsheets: Data and the user interface form a complex structure. For example, a single cell may contain a text-based formula hidden underneath the displayed numerical output value of the formula. Hence it is not easy for a spreadsheet user to document a spreadsheet model (i.e. describe to other users how to use a specific model and ensure that the model gives the correct result).  
         [0007]     During creation of a particular spreadsheet model, a user enters formulas into cells the same way he or she enters values and labels.  
         [0008]     Spreadsheet formulas are fundamental to the creation and operation of a spreadsheet.  
         [0009]     A spreadsheet formula has a specific syntax defined by the spreadsheet designer. Typically, a formula begins with a special token (e.g. =, + or @) to distinguish the formula from raw data, followed by tokens as operators (e.g. +−/), values, cell references (e.g. =(B 1 −B 2 )/100), and/or built-in functions (e.g. =SUM (A 1 :A 12 )). Cell references or addresses can serve as variables in an equation, thereby allowing precise mathematical relationships to be defined between cells.  
         [0010]     Before meaningful results of a given spreadsheet can be presented to a user, the formulas of a given spreadsheet model must be evaluated or recalculated. “Recalculation” is the process by which spreadsheet cells, particularly those holding formulas, are updated. In a conventional spreadsheet system, the standard recalculation order is termed “natural”.  
         [0011]     Suppose, for example, that it is desired to calculate the price of a good including VAT and shipping costs: The user enters the price of a good in cell A 1 , the VAT rate in cell B 1  and the shipping rate in cell C 1 . The formula for VAT is entered in cell A 4 , shipping costs are calculated in cell B 4 , and total cost is calculated in cell A 7 , cf.  FIG. 1 .  
         [0012]     By entering different values in cell A 1 , the user can calculate the total costs. Each time the user enters a new value in cell A 1  the spreadsheet system recalculates the model to show the result in cell A 7 . Interdependencies between the cells dictate how a spreadsheet system actually performs recalculation. Before the spreadsheet system can recalculate the formula in cell A 7 , the spreadsheet system must recalculate the formulas in the cells, A 4  and B 4 . In the same way, the spreadsheet system must recalculate the formula in cell A 4  before it can recalculate the formula in cell B 4 . This gives the order of recalculation: A 4 →B 4 →A 7 .  
         [0013]     Users can use more than one built-in function in a single formula, with one built-in function constituting an argument or parameter to another built-in function. This is termed “nesting” built-in functions. Generally, a user can nest as many built-in functions as desired. For example, the nested function below calculates the average values in cell block C 1 :C 14 , and then rounds the average to two decimal places: 
 
=ROUND (AVG ( C 1 :C 14);2) 
 
         [0014]     Nested built-in functions evaluate from inside out. In the above example, for instance, the AVG is calculated before the ROUND.  
         [0015]     When formula syntax and arguments are correct, most built-in functions and formulas recalculate to a numeric value (including dates) or a string value (label or text). If the user does not enter the formulas in a cell correctly, the result of a recalculation is a special value ERR (an error). It is therefore a precondition that the user of a spreadsheet system is familiar with the syntax of a spreadsheet formula. Different spreadsheet systems have different syntaxes to obey.  
         [0016]     For example, if a spreadsheet user has to write the formula described in cell B 4  in  FIG. 1 , the user has to know the syntax of an IF built-in function. (Three arguments divided by a special the token ‘;’ or other argument separator (as specified by the implementation) and the meaning of the token ‘&lt;=’ not greater etc.).  
         [0017]     With the present trend of employing electronic spreadsheets to model increasingly complex data models, conventional spreadsheets have disadvantages.  
         [0018]     One disadvantage is related to the ability of most users to correctly enter and understand complex cell formulas using a conventional electronic spreadsheet system. Some formula-builder systems have been developed to address this problem, e.g. as disclosed in U.S. Pat. No. 5,603,021. Formula-builders constitute a major improvement of spreadsheets and have certainly assisted the user in building a formula with the correct syntax. However, it has not solved the problem that most spreadsheet users find it difficult to manage the syntax of a spreadsheet formula. Consequently the average spreadsheet user has difficulty in understanding the logic of a formula and hence the logic of the spreadsheet.  
         [0019]     Another disadvantage is related to the ability to reuse formulas.  
         [0020]     For example, the cell formula: 
 
=ROUND (AVG ( C 1 :C 14);2) 
 
 is constructed of two built-in functions and operates on the cellblock C 1 :C 14 . If it is desired to reuse this formula in a conventional spreadsheet, it must be copied and pasted to a different cell location either in the same spreadsheet or another spreadsheet that are currently residing in the memory of the computer. The copy and paste process will in turn adjust the relative cell references in the spreadsheet formula. If the formula is pasted into a cell located two columns to the right of the cell it was copied from, the cell references is adjusted to E 1 :E 14 . It is not possible to save the function as a built-in function under a name, e.g. ROUND_AVG — 2 to for reuse on other cell references or as a nested function. 
 
         [0021]     Typically, a financial spreadsheet includes a feature termed Goal Seek.  
         [0022]     Consider a sales budget spreadsheet with Sales of 50000 in Cell B 2 , Costs of 45000 in Cell B 3  and the formula =B 2 −B 3  in Cell B 4  to calculate gross profit. Further, cell B 5  holds the formula =B 4 /B 2  to calculate the gross profit percentage, cf.  FIG. 2 .  
         [0023]     After a recalculation the result, 20% is displayed in cell B 5 . However, it is desired to reduce the costs to obtain a gross profit percentage of 25%. To obtain the wanted result, the spreadsheet user may enter random values manually into cell B 3  until B 5  attains the value 25%. Each time the user enters a new value in the cell the spreadsheet model recalculates. Another solution is to use the built-in Goal Seek tool, which is part of most modern spreadsheet systems. A typical Goal Seek tool has a dialog box where the user can enter specifications, cf.  FIG. 3 .  
         [0024]     By entering the specified information in the dialog box and clicking the OK button, the Goal Seek tool starts an iterative process to find the specified value. The process resembles the process of finding the root in an equation. Various root-finding techniques are available, cf. e.g. William Press, Saul A Teukolsky, William T. Vetterling, and Brian P Flannery, Numerical Recipes in C. Cambridge University Press, second edition, 1992.  
         [0025]     Regardless of the specific technique used in the spreadsheet system, the goal seek function will insert values in the specified “changing cell” until the desired condition is fulfilled. The condition is fulfilled if the desired value is within a range of ± a delta value from the value specified in the “equal to cell”. If the condition is not fulfilled, the goal seek function will stop after a maximum number of iterations (typical 500 iterations). Each time a new value is inserted in the “changing cell” by the goal seek tool the spreadsheet model is recalculated and the value in the “make cell” is compared with the value in the “equal to cell”. Thus, the goal seek tool is external to the spreadsheet model meaning that the goal seek function is not recalculated each time the sales budget spreadsheet model is recalculated. If the goal seek tool was part of the spreadsheet model, the goal seek process (root finding) would restart each time the spreadsheet model was recalculated after a new value is inserted into the “changing cell”, a process that would lead to an infinite loop. Instead the user must initiate the goal seek loop from a dialog box.  
         [0026]     It is a disadvantage of conventional spreadsheets that the goal seek function must be external to the spreadsheet to avoid infinitive recalculation. Further, the inexperienced spreadsheet user finds it difficult to manage a spreadsheet model and specify the demanded input in the goal seek dialog box.  
       SUMMARY OF THE INVENTION  
       [0027]     It is an object of the present invention to provide a new calculation tool that overcomes the above-mentioned disadvantages.  
         [0028]     According to the present invention, an electronic mathematical model builder that fulfils the above-mentioned and other objects, comprises  
         [0029]     a memory for storage of data,  
         [0030]     a processor for defining addressable sets of cells stored in the memory with a unique identifier, for entering data into the cells and for processing data stored in the cells,  
         [0031]     a user interface with a display for displaying sets of cells in a work area and means for creating and positioning sets of cells in the work area and inputting data to be entered into the cells.  
         [0032]     The electronic mathematical model builder may further comprise a function builder for building mathematical relations between cells, comprising fields for user specification of a desired function by mathematical operators and input variables of the function, and a set of destination cells containing values of the function.  
         [0033]     It is an important advantage of the present invention that a function created with the function builder is not inherently connected to one or more specific cells as in conventional spreadsheets. On the contrary, the operator of the mathematical model builder is free to define input cells containing input values for the function and destination cells containing output values of the function. In a preferred embodiment of the invention, a new set of cells is created containing the output values of the function. Further, the function may be stored in the memory as an independent entity for later retrieval and possible editing, the editing including one or more of the following: Renaming, redefinition of cell addresses of input variables, redefinition of cell addresses of output variables, modification of the function, etc.  
         [0034]     An electronic mathematical model builder according to the present invention may comprise features and functions of conventional spreadsheets, such as cell display format features, mathematical functions, charts, cell protection features, user interface features, such as icons, tools, tool bars, etc., etc.  
         [0035]     For example, a cell may contain various types of data, such as a numerical value, an alphanumeric string, a logical value, a formula, etc.  
         [0036]     Further, various features of a cell may be specified by a user, features such as character fonts used to display the contents of a cell, attributes of displayed characters, such as underline, overline, bold, italic, etc., justification in a cell of a string displayed, such as left, right, centre, etc., attributes of displayed borders, patterns, and colours of cells, etc.  
         [0037]     Cells may be copied, pasted, moved, etc., either into the current model or into another model, and cells may be inserted into, deleted from, or cleared in the current model.  
         [0038]     Graphical objects, such as lines, arrows, rectangles, ellipses, arcs, polygons, text boxes, etc., may be created in the model.  
         [0039]     Charts, such as line charts, pie charts, bar charts, area charts, column charts, XY (scatter) charts, radar charts, 3D type charts, etc., based on cell data may be created.  
         [0040]     Cells of a model may be displayed in two dimensions by means for displaying cells, such as a CRT monitor, a LCD monitor, a plasma monitor, a printer, etc., e.g. in a way well-known in the art of spreadsheets, i.e. as a grid-like table or matrix of cells holding data. In one embodiment, the grid-like table or matrix is formed of a series of columns intersecting a series of rows. The columns extend from a peripheral horizontal axis of the matrix while the rows extend from a peripheral vertical axis of the matrix. Each row is labelled with a numeral ( 1 ,  2 ,  3  . . . ) along the peripheral vertical axis and each column is labelled with a letter (A, B, C, . . . ) along the peripheral horizontal axis. An intersection of a row and column forms a cell, which receives a label formed by the composition of the respective labels of the specific row and column (e.g. C 5 ).  
         [0041]     In a preferred embodiment of the invention, cells are created and displayed in sets or panels. Each set or panel may be individually and independently positioned or moved around in the display of the model, e.g. using a mouse and a cursor to drag the set or panel in question to a desired position within the display of the model. A panel may hold one cell, a column of cells, a row of cells or a two-dimensional matrix of cells. The displayed panel may have row labels, column labels and a unique identifier. The panel identifier, its row number, and its column number uniquely identify each cell in the panel. The panel may further have a number of attributes defining features of the panel (e.g. the visibility of the row and column labels, the colour of the labels and cells, edibility of the cells, number format etc.).  
         [0042]     In the illustrated embodiment of the present invention, the number of cells in a panel may be greater than the number of visible cells. The system provides means for the user to adjust the number of cells in a panel as well as the number of visible cells. Further, the system provides means for attaching a scrollbar to one or a group of panels with the purpose of scrolling cells outside the visible area into the displayed panel area.  
         [0043]     The display of the model may comprise one or more sheets.  
         [0044]     In the function builder, cells providing input values to the function may be selected in a way similar to or identical to the way cells are selected in conventional spreadsheets, i.e. selecting desired cells using a pointing device, such as a mouse and a display cursor. Cells for holding output values of the function may be selected in the same way. Selected cells may be dragged and dropped into the function field of the function builder for definition of the selected cells as cells holding input values or output values, respectively. In a preferred embodiment, the function builder creates a new set or panel of cells to hold output function values.  
         [0045]     The function builder may comprise components for selection by the user for specification of the function. The components may be function components, such as mathematical operators, mathematical functions, logical and Boolean functions, financial functions, string functions, data base functions, etc.  
         [0046]     A function component may be a Java class that encapsulates the algorithm of a specific function, e.g. a mathematical function, a logical and Boolean function, a financial function, a string function, a data base function, etc, and the data that is input for the function.  
         [0047]     Further, the components may be data components, such as data of a set of cells, data from an external data source, etc. For example, a data component may be a Java class that holds an object reference to a specific data source, e.g. a set of cells or an external database.  
         [0048]     Further, the function builder may comprise graphical symbols relating to respective components for selection by the user to be incorporated into the desired function. The graphical symbols relating to respective components may be organized in various ways, e.g. under various tabs according to their type, in a graphical, hierarchical diagram according to their type, etc.  
         [0049]     The user may select a specific component to be included in the function by dragging and dropping the corresponding graphical symbols into the function field of the function builder.  
         [0050]     The graphical symbols that correspond to components in the model or function may comprise one or more input and/or output ports, which symbolize the respective input and/or output of the function components.  
         [0051]     Further the components of a model or function may be connected by dragging and dropping of connection lines between the input/output ports of the graphical symbols in the function field.  
         [0052]     The input/output ports of the graphical symbols may have one or more different colours or form to facilitate building of functions. One or more colours may be applied to input ports and the same or other colours may be applied to output ports. The colour of an input/output port may depend on the type of input/output, e.g. string, integer, function, array, etc. or the order of arguments.  
         [0053]     Employment of coloured ports in graphical symbols in the function field facilitates a comprehensive view of the components of a model and eases construction of a model. The function builder may further comprise tools for specification of calculation type, such as by row, by column, all cells in a panel, selected cells in a panel, accumulated or non-accumulated, etc.  
         [0054]     In order to be able to store and retrieve functions built with the function builder, the user interface may comprise means for naming functions built with the function builder, and may comprise means for storage and retrieval of functions in a memory.  
         [0055]     The model builder may comprise means for storing a selected part of the model, such as the entire model, in the memory.  
         [0056]     A first function may constitute an input variable to a second function.  
         [0057]     The function builder may further comprise tools for user definition of a mathematical operator.  
         [0058]     Thus, according to an embodiment of the present invention, an electronic mathematical model builder is provided having a user interface providing input tools, such as a keyboard and a pointing device, e.g. a mouse, a trackball, a pen, etc, and a display displaying a cursor that is controlled by the pointing device, to be controlled by an operator of the builder to 1) create cell panels in a model document resembling a conventional spreadsheet, 2) creating and editing functions, such as mathematical formulas, 3) assigning functions to desired cells in the model document, and 4) storing functions in a library of user defined functions.  
         [0059]     The model builder may further include tools for saving a model document with or without data for example as a standalone application, e.g. as a Java .jar file, an .exe file or a Java Applet, or a serverside application e.g. a Java Servlet.  
         [0060]     The model builder may also include tools for documenting the structure of a specific model document.  
         [0061]     With the present invention, users may construct model documents in substantially less time and with fewer errors than what is possible with conventional spreadsheet systems.  
         [0062]     The model builder may be accessed through an Internet browser.  
         [0063]     Different rights may be assigned to different users, e.g. so that some users may be able to display and import data from a specific mathematical model while others may be allowed to edit various or all parts of the model.  
         [0064]     Further, the user may build standalone application to be executed on any Java-enabled PC, Mac, and UNIX machine or in a java-enabled browser, with no special downloads, plug-ins or spreadsheet engines required. 
     
    
     BRIEF DESCRIPTION OF THE DRAWINGS  
       [0065]      FIG. 1  illustrates the operation of a conventional spreadsheet,  
         [0066]      FIG. 2  illustrates the operation of a conventional spreadsheet,  
         [0067]      FIG. 3  shows a goal seek dialogue box of a conventional spreadsheet,  
         [0068]      FIG. 4  shows a model according to the present invention as displayed on a monitor,  
         [0069]      FIG. 5  shows various cell panels,  
         [0070]      FIG. 6  shows a conventional spreadsheet display,  
         [0071]      FIG. 7  shows a hidden formula of the spreadsheet of  FIG. 6 ,  
         [0072]      FIG. 8  shows other hidden formulas of the spreadsheet of  FIG. 6 ,  
         [0073]      FIG. 9  shows the example of  FIG. 6  as modelled according to the present invention,  
         [0074]      FIG. 10  shows function builder displays of one embodiment of the present invention,  
         [0075]      FIG. 11  schematically illustrates the architecture of an embodiment of the present invention,  
         [0076]      FIG. 12  schematically illustrates interfaces and components of an embodiment of the present invention,  
         [0077]      FIG. 13  shows an Excel spreadsheet,  
         [0078]      FIG. 14  shows hidden formulas of the spreadsheet in  FIG. 13 ,  
         [0079]      FIG. 15  shows a function builder display example according to the present invention,  
         [0080]      FIG. 16  schematically illustrates a relation between a cell panel and a function,  
         [0081]      FIG. 17  shows another function builder display example according to the present invention,  
         [0082]      FIG. 18  shows yet another function builder display example according to the present invention and the architecture of the function,  
         [0083]      FIG. 19  schematically illustrates JAVA building blocks of an embodiment of the present invention,  
         [0084]      FIG. 20  schematically illustrates different layers of an embodiment of the present invention,  
         [0085]      FIG. 21  schematically illustrates JAVA classes of an embodiment of the present invention,  
         [0086]      FIG. 22  schematically illustrates JAVA objects of an embodiment of the present invention,  
         [0087]      FIG. 23  shows a function builder display example according to the present invention,  
         [0088]      FIG. 24  shows a flow chart of calculation of an output value of a function according to the present invention,  
         [0089]      FIG. 25  shows a function created with one embodiment of the function builder according to the present invention,  
         [0090]      FIGS. 26-34  illustrate the process of creating a function with one embodiment of the function builder according to the present invention,  
         [0091]      FIG. 35  shows the function builder displaying a retrieved function,  
         [0092]      FIG. 36  is a blocked schematic of an embodiment of the present invention, and  
         [0093]      FIG. 37  is a perspective view of the electronic mathematical model builder embodiment of  FIG. 36 .  
         [0094]      FIGS. 38-43  illustrate the process of creating a function according to another embodiment of the mathematical model builder of the present invention, 
     
    
     DETAILED DESCRIPTION OF PREFERRED EMBODIMENTS  
       [0095]     The description in this paper relies on technical terms used in the subjects of object-oriented programming and specially Java programming. For an overview, see e.g., Ken Arnold, James Gosling &amp; David Holmes, The Java Programming Language Addison-Wesley 2000, 3&#39;rd edition ISBN 0-201-70433-1  
         [0096]     The embodiment illustrated in the appended figures is programmed in the programming language Java and the system is running on the Java platform. Other programming languages could have been used for the development (e.g. C++ or C#) for a specific platform (e.g. Windows XP or Mac OS).  
         [0097]     As shown in  FIG. 4 , the illustrated embodiment of the present invention includes a spreadsheet system having a user interface built of Java graphical user interface components (e.g. windows, drop down menus ( 4 . 1 ), toolbars ( 4 . 2 ), buttons, tabbed panes ( 4 . 3 ), labels, scroll bars etc. ( 4 . 4 )). In operation, the system provides a number of cell-groups (grid views) organised in panels ( FIG. 5   a ). The system provides means for user input into the cells (e.g., keyboard, mouse, disk, and the like) for storage and processing by the system. The system provides means for building and holding spreadsheet formulas and means for recalculating of formulas and showing the result in the system ( 4 . 7 ). Further, the system provides means for drawing and updating charts ( 4 . 6 ).  
         [0098]     In the illustrated embodiment of the present invention, data are stored in cells, which in turn are grouped in panels ( FIG. 4 . 5 ). A panel can hold one cell, a column of cells, a row of cells or a two-dimensional or a N-dimensional (N≧3) matrix of cells. A cell panel have row labels, column labels and a unique identifier (in the illustrated embodiment of the present invention, a name in the embodiment of a Java String). A cell panel has further a number of attributes to describe the state of the panel (e.g. the visibility of the row and column labels, the colour of the labels and cells, edibility of the cells, number format etc.).  
         [0099]     In the illustrated embodiment of the present invention, the number of cells in a cell panel can be greater than the number of visible cells. The system provides means for the user to adjust the number of cells in a cell panel as well as the number of visible cells. Further, the system provides means for attaching a scrollbar to one or a group of cell panels with the purpose of scrolling cells not visible into the visible area of the cell panel. In  FIG. 5   a  and  FIG. 5   b  it is shown, that the scrollbar in the cell panel Column ( 5   a.   1 ) scroll the cells in cell panel Column as well as in cell panel Column  2  ( 5   a.   2  and  5   b.   4 )  
         [0100]     In the illustrated embodiment of the present invention, a user creates a cell panel by dragging a cell tool ( 4 . 2 ) from a toolbar and dropping it in the work area ( 4 . 8 ) (the spreadsheet document). The user can edit the attributes of a cell panel in a dialog box and change the location of a panel by moving it with a hardware device (e.g. a mouse or a keyboard).  
         [0101]     According to the present state of the art, development of spreadsheet models involves working with text based pr. cell formulas either by typing the formula directly in the cells or by using a formula builder, for building text based spreadsheet formulas (for a description se e.g. U.S. Pat. No. 5,603,021). The formulas and raw data (e.g. numeric values) are mixed together in the user interface  
         [0102]     In  FIG. 6  it is shown how data and formulas are mixed together in the cells in a spreadsheet model to obtain a model calculation prices inclusive VAT. Many empty cells in the spreadsheet are provided, but not needed for the spreadsheet model.  
         [0103]     In  FIG. 7  it is shown, that cell C 1  has a text-based formula entered in the cell. In fact the cells C 1  to C 12  all have text-based formulas of almost the same appearance, as shown in  FIG. 8 .  
         [0104]      FIG. 9  shows the same model in the illustrated embodiment of the invention. MAT uses drag and drop techniques to create the number of cells needed for the calculation (25 cells). The cells are grouped in cell panels.  
         [0105]     In the illustrated embodiment of the present invention, formulas are not text based but built of software components. A formula can be aggregated by other formula components. To build a formula MAT uses a graphical builder based on drag and drop techniques. Further, a formula in MAT is not associated with a single cell but a complete cell panel. This means that many cells can share the same formula.  
         [0106]     In  FIG. 10  it is shown that the model has only one formula, which is associated to the cell panel with the column label “Input*VAT” ( 10 . 4 ). All cells in the Cell panel are properly calculated, the type of calculation is performed row by row ( 10 . 1 ) and the cell panel “Vat” provides data as absolute references ( 10 . 3 )  
         [0107]     One of the fundamental problems in the art of spreadsheets is that data and functionality are mixed together in the user interface ( 7 . 1 ).  
         [0108]     To overcome this problem according to the present invention, the illustrated embodiment uses an extended MVC (Model View Controller) architecture shown in  FIG. 11 .  
         [0109]      FIG. 11  shows the interaction between the components in the MVC architecture. The Grid Model ( 11 . 2 ) passes data to the Cell ( 11 . 1 ). The Grid View determines which events that are passed to the Grid Controller ( 11 . 3 ), e.g. key events, when the user has entered new data into the Grid View or mouse events. The Grid Controller connects the Grid Model with the Grid View and determines how the Grid Model shall react on a specific event.  
         [0110]     The Grid Model does not encapsulate the data as in a traditional MVC architecture. Instead the Grid Model has an association to an object of type Data Layer that encompasses the data ( 11 . 4 ). The Data Layer is an abstract class and has in the illustrated embodiment of the present invention four non-abstract subclasses ( 11 . 5 ).  
         [0111]     By provision of this extension to the MVC architecture, the data have been separated from the user interface, and during the builder process, it is possible to work interactively with the functionality e.g. changing the kind of data or the type of calculation without disturbing the user interface.  
         [0112]     In the illustrated embodiment of the present invention, Data Layer is an abstract class that encapsulates all fields and methods that are common for the specialized Data Layers: Integer Layer, Double Layer, Object Layer, Calc Layer ( 11 . 6 ) etc.  
         [0113]     The Double Layer, for instance holds primitive data of type double while the Object Layer can hold mixed data (e.g. data of type String and data of type Integer).  
         [0114]     The Calc Layer holds the results of recalculations and will be investigated further in the next couple of sections.  
         [0115]     As schematically illustrated in  FIG. 12 , MAT defines three interfaces that manage the interrelationships between the components, Data Provider ( 12 . 1 ), Cell Provider ( 12 . 3 ) and Data Observer ( 12 . 4 ).  
         [0116]     The two interfaces Data Provider ( 12 . 1 ) and Cell Provider ( 12 . 3 ) specify the behaviour for components that can have dependent components (e.g. a cell panel can provide input for a chart. Whenever the data in the cell panel changes, the chart needs to be repainted). A Data Provider is used when a complete cell panel provides data and a Cell Provider is used when only part (e.g. a single cell or a group of cells) of a cell panel provides the data.  
         [0117]     In the illustrated embodiment of the present invention, components that can have dependent components must implement one of these interfaces.  
         [0118]     Components that are dependent on other components (e.g. can be recalculated or repainted) must be of type Data Observer ( 12 . 4 ). The illustrated embodiment defines the interface Data Observer to specify behaviour for components that can react on changes in components of type Data Provider.  
         [0119]     Both the Calc ( 12 . 6 ) component and the Chart ( 12 . 5 ) component implements the Data Observer interface.  
         [0120]     Spreadsheet formulas are fundamental to the creation and operation of a spreadsheet data model. In the state of the art, during creation of a particular traditional spreadsheet or worksheet model, a user enters formulas as text in spreadsheet cells the same way he or she enters values and labels.  
         [0121]     A spreadsheet formula has a specific syntax defined by the spreadsheet producer. A formula begins with a special token (e.g. =in Excel) to distinguish the formula from raw data, followed by tokens as cell references (e.g. C 1 ), operators (e.g. +−/), values, and built in functions (e.g. SUM(C 1 :C 12 )). Required arguments to a built-in function must be enclosed in parentheses. Multiple arguments must be separated by a semicolon, or other argument separator (as specified by the implementation). Further, multiple arguments must be entered in a specific order. If an optional argument is specified for a built-in-function, the user must also specify all preceding optional arguments for the function. If a user fails to follow the specified format for entering a built-in function formula, a spreadsheet system will refuse to process the formula further and, instead, display a syntax error message.  
         [0122]     In general, users must adhere to the following prescribed format for functions:  
         [0123]     FUNCTION_NAME (Argument 1; Argument; . . . )  
         [0124]     The type of information to be provided as arguments depends on the specific built-in function. Arguments can be divided into three general types: numeric values, matrix values, and string values (text). Most arguments require one of these types of values. Some accept a combination or a choice of types. For instance, SUM and other statistical functions accept a “list,” which can be a matrix value (i.e., cell coordinates e.g.: C 1 :C 20 ) used alone or with numeric values.  
         [0125]     Users can use more than one built-in function in a single formula, with one built-in function serving as the argument or parameter to another built-in function. This is called “nesting” functions. Generally, a user can nest as many functions as desired, several layers deep. For example, the following calculates the average values in cell matrix C 14  . . . F 24 , then rounds the average to two decimal places: 
 
=ROUND (AVG ( C 14:  F 24), 2) 
 
         [0126]     Nested functions evaluate from inside out. In the above example, for instance, the AVG is calculated before the ROUND.  
         [0127]     When formula syntax and arguments are correct, most built-in functions and formulas evaluate to a numeric value (including dates) or string value (label or text). If a value cannot be calculated, a spreadsheet “ERR” value is returned thereby indicating an error condition.  
         [0128]     In  FIG. 13 a  typical Excel spreadsheet model is shown. The cells A 1  to A 12  and B 1  . . . B 12  hold some data, while the cells C 1  . . . C 12  hold formulas.  
         [0129]     In the state of the art the evaluation of formulas (shown in  FIG. 14 ) will not be based directly on the formulas entered by the user, but on a “Reverse-Polish Notation” (RPN) or “postfix” format. Before recalculation the spreadsheet system converts the formulas to (RPN) format: E.g. the formula A 1 +B 1 / 5  entered by the user as text is converted to 
 
A1 B1 5/+  (13) 
 
         [0130]     As the RPN indicates, the / operator has higher precedence than the + operator. According to this the term B 1 / 5  will be evaluated first and the result of this division will be added to value hold in cell A 1 .  
         [0131]     The RPN format will make it possible for a traditional spreadsheet system to carry out a stack based recalculation. The internal representation of the formula in RPN format may be in so called “p-code” or opcodes, easy to convert back into text strings (“de-parsed”) for easy on-screen editing of formulas by the user.  
         [0132]     In general in the state of the art, a spreadsheet system holds a so called spreadsheet engine able to 1) parse a spreadsheet formula entered by the user as text to the internal representation 2) de-parse the internal representation back into a text string readable for the user 3) sort the cell dependency into a specific recalculation order (e.g. natural recalculation order) and 4) evaluate the formula to a numeric value (including dates) or string value (label or text) to be shown in the spreadsheet at the specific cell location. If a value cannot be calculated, a spreadsheet “ERR” value is returned thereby indicating an error condition.  
         [0133]     According to the present invention a spreadsheet formula is constructed of software building blocks, which resemble the LEGO building blocks for children. In MAT a spreadsheet formula can consists of one or many software-building blocs. A spreadsheet formula can be constructed by software components in much the same manner children builds houses of LEGO blocks by placing building blocks side by side or on top of each other. A software building block represents 1) a function (e.g. a sum function)—then called a software function building block—able to perform calculation on data input or 2) fundamental data (e.g. holding a reference to a cell panel or a reference to a constant value)—then called a software data building block.  
         [0134]     According to the present invention it is further possible to embed one or many software building blocks into software function building blocks and thereby nest the building blocks. Nested building blocks can be software function building blocks and/or software data building blocks. The outer building block then acts as a container for the nested building block(s). The nested building block(s) makes up input data for the container building block.  
         [0135]     After the construction of a formula in MAT, the formula is 1) associated with a cell panel, which then shows the result of the calculation and/or 2) stored in a library of user-defined formulas.  
         [0136]     A formula in MAT can consist of a function, e.g. a Sum function, which sums all the cells in a cell panel ( FIG. 15   a.   1 ) C 1 . The formula is constructed by the software function building block ( 15   a.   2 ) representing a sum function. Embedded in the function is a software data building block with a reference to the cell panel C 1 . The formula is associated to the cell panel ( 15   a.   3 ), which shows the result of the calculation. Further the formula sums all cells in the embedded software data building block and shows the result in one cell. The type of calculation is specified to calc all ( 15   a.   4 ). Calculation types will be specified below.  
         [0137]      FIG. 16  shows the software function building block representing a sum function with an association to the software data building block representing the cell panel C 1 .  
         [0138]     A software function building block can further have embedded software function building blocks as shown in the next example ( FIG. 17 ). Two cell panels C 1  and C 2  hold input data and a cell panel Sum holds output data generated by the formula.  
         [0139]     The formula ( 17 . 4 ) is built of a software function building block representing a Sum function and two embedded software building blocks. The first is a software data building block having a reference to the cell panel C 1  ( 17 . 1 ) and the second is a software function building block representing a division function. The division software function building block has two embedded software building blocks. The first is a software data building block having a reference to the cell panel C 2  ( 17 . 2 ). The second is a software data building block having a reference to a const value 5.0.  
         [0140]     The formula ( 17 . 4 ) is performing the calculation in rows as specified by the dropdown menu ( 17 . 6 ). The meaning of this is that the calculation is performed row by row starting from the top (e.g. the value in the first cell in C 1  is added to the value in the first cell in C 2  divided by 5 (1+1/5=1.2 and the result is placed in the first cell in the Sum cell panel) then the second cell in C 1  is added to the value in the second cell in C 2  divided by 5 (2+2/5=2.4 and the result is placed in the second cell in the Sum cell panel etc.)  
         [0141]      FIG. 18   a  and  18   b  shows the architecture of the formula. The Sum software function building block ( 18   b.   1 ) has two embedded software buildings blocks ( 18   b.   2 ). The second of these buildings blocks is another software function building block with two embedded software building blocks ( 18   b.   3 ).  
         [0142]     In one embodiment of the present invention, a Java interface Function ( 19 . 1 ) is provided, as illustrated in  FIG. 19 , to define the behaviour for calculation in the system. Further an extendable abstract Java class Function ( 19 . 2 ) is provided. The class implements the interface Function and defines the behaviour for built-in functions in the system. All built-in functions ( 19 . 3 ) in the illustrated embodiment extend the abstract class Function.  
         [0143]     The system provides further a Java class Function Holder ( 19   4 ), able to contain/hold software building blocks. The class further has an object reference to an object of type Function. Objects of type Function Holder can thus act as a built-in function and carry out calculations.  
         [0144]     All spreadsheet formulas in the illustrated embodiment of the present invention are of type Function.  
         [0145]     After the construction of a formula in MAT, the formula is associated with a cell panel, which then shows the result of the calculation and/or stored in a library of user-defined formulas.  
         [0146]     In the illustrated embodiment of the present invention, an association of a formula to a cell panel is done by utilization of the extended MVC architecture. In  FIG. 11  the association (object reference) from the Grid Model ( 11 . 2 ) to the Data Layer ( 11 . 4 ) is set to type Calc.  
         [0147]     As schematically illustrated in  FIG. 20 , the Calc layer is a special Data Layer having an association (object reference) ( 20 . 2 ) to an object of type Function. By this object reference the calc layer holds a formula and through the mechanism of the extended MVC architecture the result of a calculation is shown in the cell panel.  
         [0148]     The type of calculation performed by a specific formula is specified by the calc layer and implemented as an association (object reference) ( 20 . 3 ) to an object of type Calc Type ( 21 . 1 ) as schematically illustrated in  FIG. 21 . In the illustrated embodiments of the present invention, the Calc Type is a Java interface. The system defines a number of Java classes that implements the Calc Type interface ( 21 . 2 ).  
         [0149]     In the illustrated embodiment of the present invention, each function can have an associated private calc type specified by an object reference from an object of type Function ( 22 . 1 ) to an object of type Calc Type ( 22 . 2 ). If no special Calc Type is provided for a function the object reference ( 22 . 1 ) is set to null, and the Calc Type of the function will be the same as specified by the Calc Layer. The default Calc Type for the Calc Layer is “in rows” and cannot be null. The Calc Type for a function has higher precedence than the Calc Type for the layer.  
         [0150]     In the illustrated embodiments of the present invention, a formula built of a number of functions can in the process of calculation carry out different calculations types.  FIG. 23  shows an example.  
         [0151]     The cell panel PRO 4  ( 23 . 3 ) displays the result of the calculation of the formula ( 23 . 4 ). The formula combines three functions: 1) Product 2) Sum and 3) Avg. The calc type associated with the calc layer is calc row (calc in rows). To the Sum function there is further assigned a private calc type Calc All ( 23 . 6 ). As the Product and the Avg functions have no assigned private Calc Type, the calculation of these functions will be in rows, specified for the Calc Layer ( 23 . 5 ).  
         [0152]     The value ( 15 ) in the first cell in the cell panel PRO 4 ( 23 . 3 ) is a result of the calculation Product ( 10 ;  1 . 5 ) that evaluates to  15 . The first argument,  10  is a result of the calculation Sum (Column  1 ) as the calc type of the Sum function is Calc All ( 23 . 6 ) and all the cells in Column  1  is added to one value. The second argument  1 . 5  is a result of the calculation Avg (the value in the first cell of Column  2 ; the value in the first cell of Column  2  ) equal to Avg ( 1 ; 2 ).  
         [0153]     The value ( 20 ) in the second cell in the cell panel PRO 4 ( 23 . 3 ) is a result of the calculation Product ( 10 ;  2 ) that evaluates to  20 . The first argument  10  is a result of the calculation Sum (Column  1 ) as described above. The second argument  2  is a result of the calculation Avg (the value in the second cell of Column  2 ; the value in the second cell of Column  3  ) equal to Avg ( 2 ; 2 ). Etc.  
         [0154]     The evaluation of a formula, in the illustrated embodiment of the present invention, is a simple traverse of the arguments left to right. The user will evaluate the formula directly on the formula built. The formula does not need to be converted to a RPN notation before evaluation.  
         [0155]     A Formula evaluation, in the illustrated embodiments of the present invention, is done by a procedure called “Handle Function.”  FIG. 24  shows a flow chart of formula evaluation of the illustrated embodiment of the present invention:  
         [0156]     Let us follow the flow chart ( FIG. 24 ) to evaluate the formula shown in  FIG. 25 . The formula is built of a software function building block representing a Sum function ( FIG. 25 . 1 ) with two embedded software building blocks ( 25 . 2 ) and ( 25 . 3 ).  
         [0157]     The evaluation of the formula starts by making a call to the procedure Handle Function in ( 24 . 1 ). Let us name this procedure call, the outer procedure. The task for this procedure is to evaluate the outer software function building block, representing the Sum function ( FIG. 25 . 1 ). The evaluation moves to ( 24 . 2 ). Since the software function building block has two embedded software building blocks the decision in ( 24 . 2 ) is set to true and the evaluation moves to ( 24 . 3 ). At this point the procedure gets the next software building block (C 1  in  FIG. 25 . 2 ) and moves to ( 24 . 4 ). As the software building block ( FIG. 25 . 2 ) is a software data building block the decision in ( 24 . 4 ) is set to false and the data building block is added to the list of operands ( 24 . 5 ). The evaluation proceeds to  24 . 2 . As one more embedded software-building block is present ( FIG. 25 . 3 ) the evaluation get hold of this building block ( 24 . 3 ) and moves to ( 24 . 4 ). The decision in ( 24 . 4 ) is set to true, as this building block is a software function building block. The evaluation then moves to ( 24 . 6 ). At this point a new call to the procedure Handle Function is made. Let us name this procedure call, the inner procedure. The task for this inner procedure is to evaluate the inner software function building block, representing the Division function ( FIG. 25 . 3 ). The inner procedure starts in ( 24 . 1 ) and moves to ( 24 . 2 ) in order to check the number of embedded software building blocks. As the software function building block has two embedded software building blocks ( FIG. 25 . 4  and  25 . 5 ) the decision in ( 24 . 2 ) is set to true and the evaluation moves to ( 24 . 3 ) where it gets the next software building block ( 25 . 4 ). The evaluation moves to ( 24 . 4 ) in order to determine the type of the actual software building block. The type of the software building block is a software data building block ( FIG. 25 . 4 ) and the decision in ( 24 . 4 ) is set to false and the data building block (C 2  in  FIG. 25 . 4 ) is added to the list of operands ( 24 . 5 ). The evaluation proceeds to  24 . 2 . Since one more embedded software block is present the evaluation gets the next building block ( 24 . 3 ) and moves to ( 24 . 4 ). The new software building block is also a software data building block and is added to the list of operands and the evaluation moves to ( 24 . 2 ). As no more embedded software building blocks are present the evaluation moves to ( 24 . 7 ). The software function building block executes the function it represents (Division) on the operands which is found in the list of operands and the result of the inner Handle Function procedure is returned to the outer Handle Function procedure. The result is returned in ( 24 . 5 ) of the outer procedure and added to the list of operands.  
         [0158]     The outer procedure continues the evaluation and moves to ( 24 . 2 ). No more embedded software building blocks are present and the evaluation moves to ( 24 . 7 ). The software function building block executes the function it represents (Sum) on its operands and the result is returned. As the software function building block representing the Sum function is the outer software building block the result of the evaluation is returned to the cell panel, it is associated with (e.g. Sum in  FIG. 18 ).  
         [0159]     The work process of creating a spreadsheet model (e.g. a financial model) typical involves setting up data and building formulas, re-building formulas, changing the position of the data and formulas, setting up charts etc.  
         [0160]     In the illustrated embodiment of the present invention, a formula is built of software building blocks included in the actual model by drag and drop techniques.  
         [0161]     To be able to build formulas, the illustrated embodiments of the present invention provides a visual tool for building formulas or functions ( FIG. 26  and  38 ) Formula Builder or function builder. In the illustrated embodiment in  FIG. 26 , the Formula Builder is a javax.swing dialog ( 26 . 2 ), which is opened by a click on the Function tool in the tools palette ( 26 . 1 ).  
         [0162]     The Formula Builder includes a Tabbed Pane with a number of tabs to organise the different types of built-in functions (e.g. Statistical and Logical) ( 26 . 3 ). On each tab pane the software function building blocks that represent the built-in functions are placed ( 26 . 4 ) able to be dragged into the work area of the Formula Builder ( 26 . 8 ). The Formula Builder further includes a tool ( 26 . 5 ) to specify the calculation type of the formula, ( 26 . 6 ) a tool to associate a formula with a cell panel and ( 26 . 7 ) a tool to store a formula in a library.  
         [0163]     To build a new formula the user drops a function into the work panel ( FIG. 27 . 1  and  27 . 2 )  
         [0164]     The user can embed software building blocks into a function. With a mouse click (or another input device e.g. a keyboard) a new dialog box is opened to represent the internal of the function ( 28 . 2 ). In this “inner” dialog box most of the same tools are available as in the “outer” dialog box. A work area is provided ( 28 . 2 ) into where the user can drag software building blocks. In the illustrated embodiment, two extra tab panes are provided ( 28 . 3  and  28 . 4 ). In the tab pane “Const” a software data building block is provided to add constant values to a formula ( 28 . 5 ).  
         [0165]     In the tab pane “Column” a software data building block is provided to add software data building blocks that represent cell panels in the spreadsheet model to a formula ( 29 . 2 ).  
         [0166]     In  FIG. 30  the complete formula is displayed. The “outer” software function building block representing an “If” built-in function ( 30 . 1 ) has three embedded software building blocks as schematically illustrated in  FIG. 31  window  2 . A software function building block representing an Equal To built-in function ( 30 . 2 ) and two software data building blocks ( 30 . 3  and  30 . 4 ). The “inner” software function building block representing an Equal To built-in function ( 30 . 2 ) has two embedded software data building blocks as illustrated in  FIG. 31  window  3 .  
         [0167]     The user can associate the formula with a cell panel in the spreadsheet model by clicking on the button  5  in  FIG. 30  or the user can store the formula in a library of user-defined formulas by clicking the button  6  in  FIG. 30 .  
         [0168]     In  FIG. 32   a  the cell panel associated with the formula is shown ( 32   a.   1 ). In the illustrated embodiment of the present invention, the user can open the Formula Builder by double clicking on the cell panel ( 32   b.   1 ). In this way the user can be built the formula.  
         [0169]     As an example the user can reorder the embedded software building blocks in the formula, cf.  FIG. 33   a,  item  1  by dragging and dropping the software building blocks. The result is shown in  FIG. 33   b,  item  1 .  
         [0170]     In the illustrated embodiment of the present invention, a user can store a user-defined formula in a library. The user may associate a formula with a cell panel by clicking a button,  FIG. 30 , button  5 . By clicking button  6  in  FIG. 30 , the same formula could be stored in a library to be used later in the same spreadsheet library or in other spreadsheet models. To be able to identify the new “built-in” formula, the user will be asked to give it a name, cf.  FIG. 34 , window  2  (e.g. IF_EqualTo). The formula will then appear in the Formula Builder as a user defined built-in formula, cf.  FIG. 35 , window  1 . The formula can be dropped into the work area of the Formula Builder, cf.  FIG. 35 , window  2 , and software building blocks can be embedded, cf.  FIG. 35 , window  3 . In  FIG. 35 , the formula takes four embedded building blocks equivalent to the four software data building blocks in  FIG. 30 .  
         [0171]      FIG. 36  is a blocked schematic of the embodiment shown in  FIG. 37 . The illustrated electronic mathematical model builder  10  according to the present invention, includes a central processing unit (CPU)  14  with a math coprocessor or floating-point processing unit (FPU), a main memory  20 , an input/output controller  24 , a keyboard  16 , a pointing device  18 , e.g., mouse, track ball, pen device, or the like, a display device  12 , and a mass storage  22  (e.g., hard disk). Additional input/output devices, such as a printing device  26 , may be included in the system  10  as desired. As illustrated, the various components of the system  10  communicate through a system bus  28  or similar architecture.  
         [0172]     A computer software system is provided for directing the operation of the computer system  10 . The software system is stored in system memory  20  and on disk memory  22 , includes a kernel or operating system and an interface. One or more application programs may be “loaded” (i.e., transferred from storage  22  into memory  20 ) for execution by the system  10 . The system  10  receives user commands and data through the user interface, i.e. the keyboard  16  and the pointing device  18 ; these inputs may then be acted upon by the system  10  in accordance with instructions from operating system module and/or the application module. The interface, which may support a character-based and/or preferably a graphical user interface (GUI), also serves to display results, whereupon the user may supply additional inputs or terminate the session.  
         [0173]      FIG. 36  is a perspective view of an electronic mathematical model builder  10  according to the present invention. The illustrated embodiment  10  includes a personal computer with a processor  14 , a memory  20 , an internal hard disc for mass storage  22 , a CD-ROM drive, an audio capability, a display  12 , a keyboard  16 , and a pointing device, such as a track ball or a mouse  18 . In  FIG. 36 , the image of  FIG. 4  is shown on the display screen. The display  12  may have a touch sensitive display screen. It will be appreciated by those skilled in the art that the actual hardware implementation of the system is a matter of design choice. Thus, the model builder may be distributed across a network connected to a server, e.g. it may be provided by an on-line service for example via the Internet. For example, the computer  10  may be a portable computer that can be connected to the Internet via a mobile phone or via a wireless network, e.g. a hot spot, or the user may be connected to the Internet via a broadband connection, e.g. utilising the user&#39;s TV.  
         [0174]      FIGS. 38-43  illustrate another embodiment of the function builder of the present invention.  
         [0175]     In  FIG. 38  two data panels, Grid 1   30 , and Grid 2   32 , are created by dragging and dropping from the grid button  34 . The properties of a panel may be changed or adjusted by double-clicking at the upper left corner  36  of the panel as illustrated in  FIG. 39 .  
         [0176]     The illustrated embodiment of the present invention provides a tool for constructing functions or formulas in the electronic mathematical model builder. The function builder may be displayed or minimized as illustrated in  FIG. 38  and  39  respectively by clicking the buttons  38 . Clicking the new function button  40  in  FIG. 40  in the tools palette  43  of the model builder creates a new function.  
         [0177]     In this embodiment the model builder comprises a tabbed pane  41  with a number of tabs to organise the different types of elements, e.g. components, functions, databases, budget, in the model builder. The tabbed pane comprises a function explorer  42 . The different types of built-in functions (e.g. general, statistical, logical and financial) and user-defined functions are arranged as components in a tree structure. The function component in the function explorer can be added to a function in the function builder  44  by drag and drop techniques as illustrated by the two graphical symbols for the logical functions IF  46  and EQUALTO  48  in  FIG. 40 .  
         [0178]     The graphical symbols in the function builder correspond to function components, and have one or more input  50  and/or output  52  ports depending on the nature of the component.  
         [0179]     The function components of a function may be panels with data, e.g. input from a keyboard, database, etc., constants or any mathematical function, such as a user defined function or any conventional mathematical function.  
         [0180]     The  FIGS. 41 and 43  illustrate individual and independent positioning of a panel in the display of the model. In  FIG. 41  the panel IF 3   54  is positioned on sheet  1 , while the panel IF 3   54  is moved to sheet  2  in the display in  FIG. 43 . Each panel of the model is thus easily moved between different sheets in the display of the model without the positioning of a panel affecting the functions in the model. The Component Explorer  56  in the tabbed pane  41  provides a comprehensive view of the components of the model.  
         [0181]     The user may store the formula in a library of user-defined formulas cf.  58  in  FIG. 42  in a similar way as described in connection with  FIGS. 30 and 34 .