Developing Internet resources for online teaching mathematics With Scientific Notebook

Miroslaw Majewski

Inter-University Institute of Macao


Abstract: In this paper I show how using a computer program called Scientific Notebook we can produce interactive material for online courses. I also point out the most important features of Scientific Notebook, which allow us to enrich this material and turn web sites into a valuable tool for online teaching of mathematics as well as developing online support for traditionally taught courses.

I then describe what can be done to improve the integration of SNB documents with a web server. Finally I show just how useful can be SNB tests for online and online-supported teaching of mathematics.


The idea of using the Internet for displaying mathematical concepts is not new. Since the beginning of the Internet educators and scientists have published a number of mathematical documents on the WWW. The major problem in this undertaking is the ability to display mathematical formulae on web pages. Documents on the WWW are coded in HTML, which is a kind of programming language for describing size and shape of characters, description of styles, tables and other components of a web page. HTML does not have the appropriate tags for coding mathematical formulae.

In recent years MathML, which is an extension of HTML, was developed. MathML contains all the possible tags for coding formulae. However, most existing browsers do not display MathML tags and future when these tags will be rendered at least by Netscape and Internet Explorer seem to be rather distant. Meanwhile many impatient developers of the WWW content started using pictures to display mathematical objects – formulae and diagrams (see 7, 8, 10]). This method is quite inefficient and time consuming. Imagine that a single page of mathematical text may contain hundreds of formulae. This means you need to maintain hundreds or thousands of pictures on the web site. Moreover, the reader of such a web page will have to download all these pictures to his computer. Imagine, how much time this could take?

An example of such web site is the E. Weisstein’s World of Mathematics website [16]. The development of this web site took about 8 years. You can also find a few other web sites on the Internet that use this method of publishing mathematics. Most of them were started long time ago and their authors have already given up updating the contents.

One of the most interesting methods of publishing mathematics on WWW was developed at Triad Computing Inc. (TCI). The key to this method is the replacement of HTML by TeX and LaTeX typesetting languages (see [4, 6]). TeX is a world standard for publishing mathematical and technical documents. LaTeX is one of its dialects. There are already millions of articles and books that were developed and electronically stored in TeX and LaTeX format. This gigantic library is ready to be displayed on the WWW if we accept TCI’s solution.

TCI and recently MacKichan Software, has produced a word processor, known as Scientific Notebook (SNB), for developing LaTeX documents. SNB serves at the same as a web browser for LaTeX files. Additionally, SNB offers some other features that are not available in web browsers or in other programs designed for developing mathematical content. Describing these features is the major goal of this paper.

Dynamic versus static display of mathematics

HTML documents on the web are quite static. We can read them like a paper book. We can improve them by adding some Java applets and other active elements that will display animations of graphs and visualization of some concepts, however the major part will still be just a read-only document.

At the same time mathematics is very dynamic. While teaching mathematics we transform formulae, solve equations, plot graphs, etc. Imagine that we downloaded a mathematical web page. In order to change any formula on this page we have to develop it in a computer graphics program, save as a computer file and then embed it into our document. We would have to do the same with graphs, diagrams and other elements.

Now imagine quite a different situation. After downloading a mathematical web page, the student can recalculate each part of this document in the web browser. He can change coefficients of equations and explore alternative solutions. He can plot graphs of modified functions or animate them to see the shape of curves and surfaces better. Finally, he can take the whole document, add the solutions of the enclosed problems to it and post the final document to his instructor for grading.

Dynamic web documents, like what I described above, can be a very attractive alternative to the static web content. A number of computer programs can be used to develop such dynamic web content. You can use Maple V, Mathematica and Scientific Notebook. However, only SNB can satisfy mathematics educators, due to its attractive price and some other features that will be mentioned later. You can find more information about using SNB in teaching mathematics in [2, 5, 11, 12].

Why Scientific Notebook

People using telephone lines to browse Internet already know how important is the size of files that are downloaded by a web browser. Especially in online education, the size of files plays an important role. Students cannot afford to waste time while taking part in an online lecture or communicating with their instructor. This means that while developing web content we shall keep in mind the size of produced files and make them as small as possible.

SNB saves its documents in LaTeX, which is the most compact format of describing mathematics. LaTeX files are very small and may contain formulae, so we do not need hundreds of separate pictures for formulae. We also do not need to develop separate pictures with graphs.

Formulae in SNB documents are live. The secret of this feature is the Maple computing engine enclosed with SNB. Whenever we wish to calculate a formula in an SNB document, Maple V takes care of our formula, produces result and then this result is placed back in the document. At the same time SNB takes care of our interaction with Maple kernel. We do not need to know even a single Maple command to obtain results. At the moment SNB version 3.5 is distributed with two computing engines – Maple V R5.1 and MuPAD. MuPAD is a computer algebra system produced by group of scientists and students at the University of Paderborn in Germany. Many people believe that MuPAD computing kernel is even superior to those in some other CAS tools. In the future, it will be possible to type MuPAD code directly in SNB documents. This will give us an opportunity to trace algorithms in SNB and perform recursive operations programmed by users.

Scientific Notebook as an authoring tool

SNB contains two elements: the computing kernel and the word processor that acts as a user-friendly interface for this kernel. Besides of the communication with computing kernel this program is considered as one of the easiest to use mathematical word processors. Two its features are important.

Formulae in SNB documents are a part of the text and are not embedded elements like in most other word processors. This makes access to the formula quite easy. Just put the cursor onto it and type mathematics. You do not need to call an external formula editor as you do in MS Word and other programs.

In order to edit a formula, you do not need to click on hundreds of buttons and go through many dialog boxes. Just type it. There are a few important key sequences to insert roots, fractions, integrals, large operators, etc. For instance, in order to type Math: square root of (sin x)/x  just type [Ctrl][r] to obtain radical, then type [Ctrl][f] to obtain fraction and then type the rest of the formula. The formula editor in SNB had gained a lot of attention. The same formula editor was used in Ami Pro – one of the first Windows word processors – and later in Word Pro. At the moment the formula editor in Word2000 has implemented the same concept of editing a formula and the same key sequences.

In SNB documents, formulae are displayed in red to distinguish them from ordinary text.

Mathematical plots on the web

Graphs on the HTML pages are usually GIF or JPG files. Which means that their quality is not the best and files are large. When printing such documents, the quality of graphs is usually much worse.

In SNB web pages graphs are represented by formulae and drawn on the computer screen with the use of Maple or MuPAD computing kernel. Therefore, the graphs do not form separate files. SNB uses a vector format to display graphs on the screen, which doesn’t lose its quality when we resize or squeeze the picture to extreme sizes.

Some more complicated graphs take a bit more time to be drawn on the screen. Usually this is still faster than downloading large GIF or JPG file. You may also consider of replacing live plots by their snapshots. You may ask SNB to save a snapshot of a plot and then embed it into document. SNB snapshots are produced as WMF files, which are vector files and their size and quality does not change with the size of the picture on the screen. SNB also supports many other graphical formats. However, you always have to keep in mind that the size of graphics files is very important.

I mentioned before that SNB documents are saved as TeX files. We can also save them as RAP files, where both text and embedded graphs will be wrapped together into one single file. This helps a lot in maintenance of the web site.

Mathematical quizzes on the web

We need to test our students in order to know how much they have learned and what kind of problems they encounter while learning the subject. Most known web based tests are single purpose multiple-choice tests. This means that every time a student accesses the test page he gets the same test. Such tests can be used only once and every time we are develop such a test we have to do all the work from scratch. This is very time consuming. However, it is not possible to do more intelligent tests without having a computing engine.

SNB has two good computing engines and very powerful test builder. Tests in SNB are not just multiple-choice tests. If you like, you can use multiple-choice design; however you may ask your student to directly write his response, and this response will be evaluated in SNB. In order to understand how SNB tests work, we have to go through the whole process, step by step.

Step 1 – program your test questions

Programming test files is quite logical. For each question you have to define variables for the question, write down question statement and define some choices. Here is an example of a programmed question:

Conditions: (r<p)&((pmod100)<>0)
  r is what percent of p?
· a+5
· a+1
· a  correctchoice
· a-1
Fixed None of these.

Just reading the above code you may have noticed that variable r is a random integer taken from the interval {2, 3, 4, 5, … , 19} and p is a random number from {10, 11, …, 39}, thus a which is obtained from two random numbers will change its value depending on r and p  respectively. Finally, given conditions reduce the choice of r and p to only specific situations.

The two randomly generated numbers r and p will be inserted into the statement that will be displayed to student. The next part, the choices, will display 5 possible solutions to the student. The choices will be placed in random order – there is a general instruction that makes it for all questions. The correct choice is a and this line will occur somewhere between other choices in random location.

Step 2 - output

Each time a student loads such test into his computer he will get different output. Here are shown three of them.

Sample test question

Sample test question

Sample test question

Step 3 – marking results

After choosing one of the possible choices and clicking on the button [Submit] that is placed at the end of the test document student will obtain his grades in the following form:

Student: John Brown
Started: Thu Apr 06 15:39:08 2000
Finished: Thu Apr 06 15:39:31 2000
Elapsed: 7 minutes 23 seconds
· Question 1: You selected choice 4 (5/7). 
  The correct selection is choice 3 (343/20).
· Question 2: You selected choice 2 (82/2). 
  The correct selection is choice 1 (75/2).
· Question 3: You selected choice 4 (1350). 
  The correct selection is choice 3 (200/3).
· ..........
You got 0 points out of a possible 10.

SNB tests (QIZ files) can be placed on the web site like other TeX or RAP files. This makes our tests accessible to students at any time. They can open them, as many times as they wish and work with them like with traditional books of problems. But there is one important difference – this problem book is dynamic and changes whenever a student opens it. Many educators use SNB tests as a drill tool for improving the students’ knowledge of the subject, as well as their confidence in their knowledge.

Finally we have to think of how we collect the students’ marks. For online education it is very important that the SNB exam builder can post results to a database on the web server. This way we can find out: how many times student attempted to do the test, how much time he spent doing test, which questions were the most difficult for him, his score for each attempt, etc. We do not need to spend time marking students work and assignments. We also gather much more information about our students than using traditional methods. This is especially important when we have large groups of students.

Designing mathematical pages

For about 500 years calligraphers and later printers learned how to design printed documents to grab as much as possible of the readers’ attention. They learned a lot about the psychology of human reception. With the invention of computers these things still remain true. Only one thing has changed – web documents require more attention, as reading text on the computer screen is much more difficult than reading a newspaper or book. Thus designing issues for the web are even more important than those for the paper documents. Such things like the use of fonts, colors and grids must be very carefully considered.

Pages designed in HTML can be very colorful and appealing to readers. We can use various colors, banners, rulers, tables for formatting text and pictures, etc. It was always surprising for me that many mathematical web pages look rather ugly. Usually they have just white or gray background and black, often, ragged characters. The reason can be a lack of designing skills as well as the limitations forced by using pictures to represent formulae.

Very often, the size of the formulae is different than the size of the text. We must remember that in most web browsers, the user can change the size of characters displayed on his screen. At the same time pictures with formulae will still have the same size, thus making the displayed text very messy.

SNB documents look quite different. The whole text is formatted accordingly to the used style sheet. This makes the whole document very consistent. The concept of styles is exactly the same like in HTML. We deal with body text, header 1, header 2,…, lists and other elements that can be applied to the whole paragraphs. We may also define styles that we can apply locally: bold, italic, etc.

The user can define his own set of styles and use it for all his web site creations: both documents and tests. Creating such a style sheet is quite easy and it can be done while typing text. After finishing the document we have to also save our styles in a separate file; thus, we obtain a ready set of our favorite styles.

SNB comes with a number of professionally designed styles – for articles, books, lecture notes, online documents, etc. It is especially worth searching for good examples of styles in some online courses like [11, 15].

Other designing tools in SNB are similar to those that we have for traditional web pages. We can use tables for multicolumn formatting, banners and rulers, illustrations, etc.

Integration with web servers

Different web servers can deal with information published on the web site in slightly different ways. In a few cases you may find that web server as well as our browser doesn’t recognize RAP and QIZ files. In this situation, the RAP or QIZ file is downloaded to the temporary Internet files on our computer and opened in the web browser window as a text file. One may expect that such file will be opened in SNB according to its type. This problem can be solved easily on the web server side.

You can ask your webmaster to find the file with definition of mime types on the web server. For example, for Apache and WebCT servers on a UNIX machine this is the file mime.types which is usually located on the directory:

/[installation directory]/webct/webct/server/conf/mime.types 

The contents of the file mime.types, is a list of file types that shall be recognized by the web server. There are two columns. The left column contains the file type and the right column possible extensions of files of this type. Here you may find TeX related entries: 

application/x-latex     latex
application/x-tex       tex
application/x-dvi       dvi
application/x-texinfo   texinfo texi

Note that there is a separate entry for TEX files but there are no entries for RAP and QIZ files. This explains why TeX files are handled properly by web server and SNB but RAP and QIZ not. So, using any text editor available on your server expand the TEX entry into:

application/x-tex       tex rap qiz

This shall solve all your problems. Sometimes it is also worth to do some tuning of the web browser on the client side. This can be very important when you use links from HTML pages to an SNB document. Such modifications are especially important, on both server side as well as browser side, when we use a WebCT server for online teaching. You can find more detailed information about integration of SNB documents and WebCT in [13].


Education online means much more than only displaying documents on the web site. This also concerns teaching of mathematics online. However, perfect preparation of documents for the web is the first and very important step. All traditional methods are unsatisfactory and there are many reasons why they should be avoided. Using SNB for producing mathematical content for online teaching solves many problems with displaying mathematics online as well as adds a number of attractive features.

The three the most important features of SNB for online teaching mathematics are:

  1. The ability of producing dynamic content for the web.
  2. The ability of using formulae for coding graphs of functions and other mathematical documents rather than pictures in GIF or JPG format.
  3. The ability of producing online tests, marking them and submitting scores to the database on the web server.

SNB gained already a lot of attention from mathematics educators. Many professors are using SNB as an electronic whiteboard for their lectures, while some others are producing electronic books on CDs or on the web (see [11, 12]). A number of large and small universities have decided to use SNB for their online education. Between them are the Texas A&M University (see [1, 14, 15]), the Concordia University, and the Hong Kong Open University.

In the last year, the  Inter-University Institute of Macao started using WebCT and SNB for teaching Mathematics Education courses. These courses are taken stationary. However, a web site is used to support learning and to extend contact with teaching professors. By using a hit counter on the main page of each course I found that my students access lecture notes each night many times. Web site with SNB documents became for them a source of information that they can access at any time.


  1. Allen D., Rahe M. – Multimedia Calculus, Texas A&M University, 1998.
  2. Majewski M. - Evaluation of Scientific Notebook as a Tool in Mathematics Education, PNG Journal of Mathematics Computing and Education, Vol. 3 No. 1, pp. 25-38, 1997. Available also as an electronic publication at MacKichan Software, Internet address:, 1997.
  3. Majewski M. - How to Integrate Scientific Notebook documents with HTML files on a WWW site, electronic publication, TCI Resource Center, Brooks & Cole Publishing (now MacKichan Software), Internet address:, 1997,

  4. Majewski M. - TCI-Web -- Method of Publishing Mathematics on the Internet, Electronic publication, TCI Resource Center, Brooks & Cole Publishing (now MacKichan Software), Internet address: 1998.
  5. Majewski M. - Scientific Notebook - an Interactive Approach in Teaching Mathematics, in Proceedings of the International Conference on the Teaching of Mathematics, John Wiley & Sons,1998.
  6. Majewski M. - Publishing Live Mathematics on the WWW, PNGJMCE vol. 4, pp. 63-72, 1998.
  7. Majewski M. - HTML Approach in Publishing Mathematics on the WWW, PNGJMCE vol. 4, pp. 53-63, 1998.
  8. Majewski M. - Publishing Mathematics on the World Wide Web, Blackwell Science Oxford, Journal of Computer Assisted Learning, 1999, vol. 15, nr. 2, pp.139-148.
  9. Majewski M. - Experiences in Teaching Mathematics with Scientific Notebook, Mathematics for the 21st Century, SEACME-8 conference proceedings, Manila, 1999, pp. 267-275.
  10. Majewski M. - A Survey on Methodology of Publishing Mathematics on the WWW, (A summary of my previous papers and reports related to publishing mathematical concepts on the Internet).
  11. Majewski M. - Teaching Mathematics with Scientific Notebook, The Challenge of Diversity -Symposium on Undergraduate Mathematics, Delta 99, pp. 118-125, 2000.
  12. Majewski M. - Why we need Scientific Notebook for Teaching Mathematics, Mathematics 2000 Festival, University of Melbourne, 10-13 January 2000.
  13. Majewski M. - How to integrate Scientific Notebook and WebCT server, The Math/Science-Online Newsletter, Texas A&M University, 2000.
  14. Stecher M. – WebAlg – An on-line college algebra course, The Math/Science-Online Newsletter, Winter 1999/2000, Texas A&M University.
  15. WebAlg Group – College Algebra,  A Web Based, Interactive, Multimedia College Algebra,
  16. Weisstein E. – Eric Weisstein’s World of Mathematics, at  , 2000.

© M. Majewski, 10/06/2000