Message Boards Message Boards

[BOOK] Interactive Computational Geometry: A Taxonomic Approach

Posted 9 years ago
10 Replies
42 Total Likes


Jim Arlow, Interactive Computational Geometry: A Taxonomic Approach.

Clear View Training

Wolfram Notebook Archive


enter image description here

Hello community,

I have just published a new book in CDF format called "Interactive Computational Geometry". Ed Pegg of Wolfram suggested I notify the community. The book comprises text, plus 53 interactive Demonstrations of a selection of some of the most fundamental computational geometry algorithms.

Note: The book is written for Mathematica 10, but will work OK in Player 9 (until Player 10 is released). There are 3 demonstrations that are Mathematica 10 specific that don't work in Player 9. These are simple demos of Mathematica 10 features, and don't really detract from the rest of the book.

Full book is embedded below.

POSTED BY: Jim Arlow
10 Replies

enter image description here -- you have earned Featured Contributor Badge enter image description here Your exceptional post has been selected for our editorial column Staff Picks and Your Profile is now distinguished by a Featured Contributor Badge and is displayed on the Featured Contributor Board. Thank you!

POSTED BY: Moderation Team

Sam, thank you for your comments. I'm glad you like the book. Eric Schulz did an inspiring job, both with his book and presentation. I worked somewhat differently to Eric, largely because my audience is different. In particular, I expect my audience to be familiar with Wolfram Language code (at least to some degree), and the code itself is a major part of the book. As such, I did not need to hide input cells etc. as Eric did. Eric was also much smarter than me when it came to creating writers tools! I confess that I just worked in Mathematica to develop the text, with no special tools. My workflow was as follows:

0) Create rough idea and outline for book.

1) Decide on a topic for a chapter.

2) Assemble references.

3) Write some text.

4) Develop algorithms/code/demonstrations (Manipulate).

5) Consolidate algorithms/code/demonstrations into text (cut and paste).

6) Loop to 2) until satisfied.

7) Top and tail book (add Introduction, TOC and Bibliography).

Obviously, in reality this is a very iterative process, and I would be working on several chapters at once, and reorganising the book as I went along based on logical dependences between the computational geometry algorithms.

Despite the fact that I didn't create any authors tools, it was still a very good experience writing a book using Mathematica as an authoring environment, and I would recommend it to any author. It is easier in many ways than creating iBooks or ePubs. ePub is just a non-starter for interactive books, and even iBooks requires you to "kick-down" into HTML5 for many things. Everything in my book was done directly in Mathematica and the Wolfram Language.

In terms of my own tips for authors:

1) Develop the code/algorithms/demonstrations in separate notebooks, and make sure you have them tested and working before you paste them into the main text.

2) Export to CDF often to check it all works. There are some things (such as importing packages) that work in notebooks, but that don't work in CDFs. It is good to find out about these things sooner rather than later!

3) Use a Literate Modelling style for describing algorithms/code. You can find out more about Literate Modelling here. It is a technique that makes it very easy to describe models/code in a precise way.

4) Be very careful about defining symbols and tidying up the namespace (using Clear) when developing code/algorithms and tests. I know this is just Mathematica best practice, but when your text gets quite large, it becomes very important in order to avoid mysterious errors.

5) Save a new version of the text every time you make a significant change. Mathematica can crash, and it is pain to loose work. Also, you sometimes need to roll back to a previous version in order to fix an error or help with debugging. Obvious - but worth repeating.

6) Don't trust Mathematica CDF Preview! In Mathematica you might expect "File/CDF Preview/CDF Player" to preview the CDF in the current CDF Player. I have just found that it doesn't. For example, a CDF that works fine in Mathematica 10 "File/CDF Preview/CDF Player" doesn't work in the downloaded version of Player, because that is still version 9. So the version of Player in Mathematica and the downloadable version of Player may be out of step.

POSTED BY: Jim Arlow

Jim, this is a nicely done book, congratulations! I am very happy to see another CDF book done with a professional quality in addition to calculus and physics ones. Any good tips for future authors, any advice? Eric Schulz, author of the calculus book did a great talk - Publishing a CDF ebook: an Author's Perspective - about details of the process. I wonder if you followed a similar path.

POSTED BY: Sam Carrettie

i don't like the CDF's in the demos at all. the inner core of code (which is what interests me), is wrapped within one or more layers of display commands such Manipulate. i would like to see are programs stripped of all these display commands so i can see what is being calculated, not what is being displayed.

POSTED BY: Richard Gaylord

The book looks great! One nice feature of using symbolic content like you do is that the CDF file is actually quite small. The content is defined as plaintext and evaluated at runtime, keeping the size well below that of some mathematical ebooks with embedded images.

POSTED BY: Jesse Friedman

Jesse, thank you very much for your kind words about the book. Yes - the book is very small (1.6MB) considering the number of figures. I have published several other books, both paper, conventional eBooks and interactive iBooks for iPad. From an authors perspective, CDF has a very, very nice workflow because the interactive features are all in the Wolfram Language, rather than having to drop down in HTML5 as you do for iBooks. It frustrates me that when I write books about UML and BPMN (my main areas of expertise), I can't ship "live" models in the same way I can ship "live" mathematics with CDF. Wolfram is really ahead of the game here!

POSTED BY: Jim Arlow

Thanks for the suggestion James - I think it is an excellent idea. I made the first few chapters available for free from the book website. For your convenience, here is a direct link to the free sample.

POSTED BY: Jim Arlow

Jim, be aware that the sample will not look 100% OK with the current CDF player (based on Mathematica 9). The InfiniteLine command is new in Mathematica 10 and is not included in CDF Player 9.

POSTED BY: Gustavo Delfino

Thanks for the warning Gustavo. Yes - you are correct. Everything works OK if you use Mathematica 10 - "Preview CDF", but if you open the file in a downloaded version of Player (which is currently version 9), you get an error for the three Mathematica 10 specific demonstrations. Fortunately, none of these demonstrations are key, because I added them just to demonstrate some new Mathematica 10 features - they do not affect the algorithms or the rest of the book in any way. I will put a note on the book website explaining this for Player 9 users. Hopefully Player 10 is not too far off!

Actually, there is a really interesting and important point for CDF authors here - I assumed (and I think most reasonable people would), that "File/CDF Preview" in Mathematica 10 previews your document in the current version of the CDF Player. We now know that it doesn't - it uses some other version built in to Mathematica 10. I will add this to my post about advice for CDF authors.

POSTED BY: Jim Arlow
Posted 9 years ago

Your book appears interesting. May I suggest that you make a chapter (or portion) available for free, so that people can sample before they buy? (On Amazon, one can often read the first chapter of a book before making a purchase decision.)

POSTED BY: James Stein
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
or Discard

Group Abstract Group Abstract