Very very basic guide to CalcMe
Live demos
There are several live demos on this page. If you click into the area containing the CalcMe parameters, it will open in CalcMe. Try it out, change the parameters or options. You won't break anything.How does CalcMe work?
You can write mathematics, and CalcMe will perform the calculations for you.
The CalcMe sheet is divided into three main areas:
Calculate
- Write what you would like to compute
- Click Calc or Enter
The default action is Calc but you can choose the most appropriate one at your convenience
LIVE DEMO
Graph
- Write the equation or figure you would like to plot
- Click Plot action
New
From this moment on, it's possible to download the graphic plotter as a square image in PNG format of the size you desire. Take advantage of this new CalcMe feature to save the generated images directly to your device.
Define
- Store a computation in a variable
- Use it later
New
There is a new procedure to define variables in CalcMe using the code editor. You can see the problems intended to be solved with it and the expected user interaction here.
Arithmetic
Mathematical operations in CalcMe are represented by a symbol associated with a keyboard key.
Operation | Symbol | Keyboard |
---|---|---|
Sum | + | |
Substraction | - | |
Multiplication | * or · | |
Division | / | |
Square root | Ctrl+. | |
Root | Ctrl+, | |
Power | Ctrl+↑ |
LIVE DEMO
You can compute the quotient and remainder of a division or factorize a number into prime factors. You can also compute the greatest common divisor or the least common multiple of a set of numbers.
LIVE DEMO
Vector and Matrix constructor
Vectors
Vector are constructed with square brackets []
, and the elements are separated by commas ,
.
You can sum vectors or compute their scalar product.
LIVE DEMO
Matrices
Matrices are vectors of vectors, that is, vectors whose elements are vectors. You can create matrices with two different syntaxes
As vectors, you can sum and multiply matrices (as long as their dimensions are compatible).
LIVE DEMO
Basic operations
As you have previously seen, you can work with vectors and matrices and perform basic arithmetic with them. However, you can do many more things: you can compute the cross product between two vectors, check if they are linearly independent; a matrix can be inverted or raised to a whole power, you can also compute its rank or its determinant.
LIVE DEMO
Element access
You can access a specific element of a vector using subindices, that start on 1. In the same way, you can retrieve an element of a matrix
LIVE DEMO
Polynomials and expressions
Polynomials are created with a number multiplied by a variable raised to a power.
LIVE DEMO
You can sum, multiply, divide and, for instance, find roots of polynomials.
LIVE DEMO
You can also create more complex expressions and operate with them.
LIVE DEMO
Differentiation
There are plenty of ways to compute the derivative of a function or expression.
Using a prime | ' |
Using the symbol | |
Using the action | |
Using the command | differentiate |
LIVE DEMO
Integration
There are also plenty of ways to compute the integral of a function or expression.
Using the symbol | |
Using the action | |
Using the command | integrate |
LIVE DEMO
Limit
It is possible to compute the limit of a function or expression. Moreover, you can also take one-sided limits.
LIVE DEMO
Taylor expansion
You can compute the Taylor series of a real function at a given point. If you are interested in the terms up to some order, you can cut the series too.
LIVE DEMO
Series
You can determine whether a series is convergent, as well as calculating the sum of a convergent series in most cases.
LIVE DEMO
Geometry
CalcMe allows us to deal with geometrical figures such points, lines, planes and conic sections. You can also create polygons and polyhedra, both in 2D and 3D. It is also possible to compute the distance between figures, the angle they form or the symmetry with respect to an object.
Points, lines and planes
It is possible to work in 2 or 3 dimensions. To create points you simply define its components.
LIVE DEMO
Given two points or a point and a vector, you can construct a line.
LIVE DEMO
In a similar way, you can, for instance, construct a plane given three points.
LIVE DEMO
Figures
LIVE DEMO
Solving
Equations
It is possible to solve an equation or a system of equations exactly.
LIVE DEMO
You can also use a numerical method to solve more complicated equations.
LIVE DEMO
You can also use a numerical method to solve more complicated equations.
LIVE DEMO
Inequations
It is also possible to find the solution to an inequation.
LIVE DEMO
Statistics
There are a lot of functions useful for statistical calculations such as mean, quantile, quartile, etc. You can see the complete list here.
LIVE DEMO
Probability
The most common probability distributions are also available. Analytical expressions for density and distribution functions are also available if possible.
LIVE DEMO
Combinatorics
Combinations, permutations or variations of a set of numbers can be calculated. Be careful, though: results are very large.
Counting | Symbol |
---|---|
Variations or k-permutations of n | |
Permutations | |
Combinations | |
Variations with repetition or n-tuples of m-sets | |
Permutations with repetition | |
Combinations with repetition | |
Binomial coefficient | |
Factorial You can also write ! with the keyboard. |
LIVE DEMO
Units and currencies
You can work with units, convert one into another (if it makes sense) and do basic operations with them. Units need to be introduced via the symbols available under the Units of measure tab. Discover more about the units or prefixes you can use here.
LIVE DEMO
Currencies are similar to units but you cannot convert one into another. Check all the available currencies here.
LIVE DEMO
Randomness
Algorithm lines option
As you may use these commands to generate an algorithm for a Wiris Quizzes question, we show how to create them through the sheet and using the code editor. You can see more details about it here.The random function in CalcMe is adaptable to many cases of use. For example, you will see how to remove the "0" from a random selection. The normal command would be like:
LIVE DEMO
CalcMe sheet | CalcMe code editor |
---|---|
By default, this includes all of the numbers between -10 and 10. If given the requirements of the question, the number 0 needs to be excluded from the set, you can remove it with one simple instruction:
LIVE DEMO
CalcMe sheet | CalcMe code editor |
---|---|
You have to add brackets around the first list for this to work. This can, of course, work equally for any other number you need to exclude other than zero:
LIVE DEMO
CalcMe sheet | CalcMe code editor |
---|---|
The above would produce a random number between -10 and 10, except the number 8. You can even do this with more than one number:
LIVE DEMO
CalcMe sheet | CalcMe code editor |
---|---|
This would remove 8,-8, and 0 from the selection. As you can see, there are many more options when creating a random variable.
So far, you have retrieved integer numbers, but you can also work with real numbers.
LIVE DEMO
CalcMe sheet | CalcMe code editor |
---|---|
As a general rule, these real numbers will have as many decimal or significant figures as defined in the Application settings. You can adjust it by defining the step between the possible random values.
LIVE DEMO
CalcMe sheet | CalcMe code editor |
---|---|
Moreover, these random variables can also be selected from a concrete set of values or words. In the following section, you will see with more details on how to create this kind of sets.
LIVE DEMO
CalcMe sheet | CalcMe code editor |
---|---|
{}
and []
to exclude several numbers for the set of possible values when generating random variables. We use each of them as follows:[]
define arrays and matrices (arrays are supposed to contain the same data types).{}
define lists (lists can have different data types).
The random function can exclude values as long as the two parameters you pass are in the same format. In other words, if you include a list as a first parameter, you should pass a list as the second parameter as well.
Creating lists via comprehension
This section is a short guide to creating lists in CalcMe, using the commands
with
and where
. This method of defining lists is based on the common mathematical notation of "set comprehension" or "set-builder notation", for instance:
We will explain the commands through the following examples.
Algorithm lines option
As you may use these commands to generate an algorithm for a Wiris Quizzes question, we show how to create them through the sheet and using the code editor. You can see more details about it here.Example 1
At the most basic level, with
simply provides a more compact form of writing long lists. You can write
LIVE DEMO
CalcMe sheet | CalcMe code editor |
---|---|
or you could greatly simplify it to the following:
LIVE DEMO
CalcMe sheet | CalcMe code editor |
---|---|
The command where
comes in handy when you would like to have additional restrictions. For example, retrieve the even numbers only:
LIVE DEMO
CalcMe sheet | CalcMe code editor |
---|---|
Alternatively, you could, of course, have done this:
LIVE DEMO
CalcMe sheet | CalcMe code editor |
---|---|
Example 2
In the first example, the size of the list was fixed. However, comprehension is especially useful when defining lists of variable size. Here, for example, is a list with random elements, of random size
LIVE DEMO
CalcMe sheet | CalcMe code editor |
---|---|
As you may have noticed, the first expression does not explicitly depend on . You can think of as just a counter within a specified range. Then, you may or may not use it to define the list elements. It can also be any variable name you choose, as in the following:
LIVE DEMO
CalcMe sheet | CalcMe code editor |
---|---|
Example 3
The list comprehension notation can also be extended to more than one variable. In that case, you should specify the range for each variable used as a counter. For example, here is a list with all positive proper fractions in simplest terms, with a single-digit numerator and denominator:
LIVE DEMO
CalcMe sheet |
---|
CalcMe code editor |
Another recommendation illustrated in the above example is enclosing each condition after where
in parentheses if you have more than one joined by .
Example 4
Finally, note that the range for the counter variable can itself be a list, defined previously.
LIVE DEMO
CalcMe sheet | CalcMe code editor |
---|---|
Example 5
It is also possible to create matrices using this notation. For instance, creating a matrix with random coefficients is as simple as this:
LIVE DEMO
CalcMe sheet | CalcMe code editor |
---|---|
Programming
Algorithm lines option
As you may use these commands to generate an algorithm for a Wiris Quizzes question, we show how to create them through the sheet and using the code editor. You can see more details about it here.You can use some programming functions. You can see the basic ones here. For example, given a list created as described before, you can easily compute the square of the first primes.
LIVE DEMO
CalcMe sheet |
---|
CalcMe code editor |
User functions
Algorithm lines option
As you may use these commands to generate an algorithm for a Wiris Quizzes question, we show how to create them through the sheet and using the code editor. You can see more details about it here.
You can create custom functions. The random
command is very useful but it could be a bit tedious to write every time random(-10,10)
. Instead, you can create a function that generates a random number when called:
LIVE DEMO
CalcMe sheet | CalcMe code editor |
---|---|
This eases the creation of a matrix with random coefficients. Another more elaborated example is creating a function that constructs a tri-diagonal matrix given three numbers. Therefore, every time you would like to create a tri-diagonal matrix, you just need to call this function with the upper-diagonal, diagonal and lower-diagonal terms you would like the matrix to have.
LIVE DEMO
CalcMe sheet | CalcMe code editor |
---|---|