next up previous contents
Next: Error messages Up: User's Manual Previous: A list of the   Contents

A simple example of arithmetical network

Figure 7: The simulation $\to $ Get All Values command in action
\includegraphics[scale=1]{getallvalues.ps}

In order to demonstrate the fact that this software can be used by non-mathematicians as well, let us give you an example taken from the world of economics: the simple interest calculation.

Given the ``official'' formula : $i = {c*r*n\over{100*360}}$, where :

$i$ is the interest
$c$ is the capital
$r$ is the rate in %
$n$ is a number of days

Let us translate this into an arithmetical network using AriNET. We first have to declare our variables:

(defvariable i c r n)

We can now define the corresponding arithmetical network:

(defconstraint (i = (c * r * n) / (100 * 360)))

Notice the blank spaces between c * r * n are required. When omitted the systems considers c* to be the name of a variable.

Now by using the GUI command: simulation $\to $ Get All Values, we inquire whether the computer already found solutions for our arithmetical network. As we did not yet assign a value to any of the variables it is not surprising AriNET was not able to solve anything so far! We now assign a value to the variables c r n:

(set-value! c 1000 'user)
(set-value! r 2.5 'user)
(set-value! n 125 'user)

By executing the command simulation $\to $ Get All Values again, we find out the program gave a value for to our interest (i=8.680555555555555). (see figure 7)

Now, suppose the rate remain 2.5, the number of days 125 but the capital is unknown. If we assign 8.681 to the interest, then the system should be able to calculate a capital of about 1000:

(forget-value! c 'user)
(set-value! i  8.681 'user)
(get-value c)

No surprise! The system returns a capital of 1000.0511999999999, which is about what we expected.

You can access this example (and many more) by using the Misc $\to $ Example 4: Simple Interest menu item.


next up previous contents
Next: Error messages Up: User's Manual Previous: A list of the   Contents
dominique 2003-06-02