Interplay between Xholon and Wikipedia

Ken Webb 2011-11-20T18:18:36Z

Xholon and Wikipedia can interact with each other in many ways.

Build it

This describes how to create a Xholon application that is informed by Wikipedia content.

Part 1 Inheritance hierarchies and classes

Part 2 Composite structure hierarchies and objects

Part 3 Other relationships between classes and objects

Part 4 Types of object properties

Part 5 Values of object instance properties

Part 9 Scalable Vector Graphics (SVG)

Try it

Run the initial version of the finished application. (This requires Java 1.6).

If the Java Console is enabled, then after a few time steps, the app will repeatedly display something like:

Mercury: 9118.645875646738
Venus: 2611.156824322119
Earth: 1365.9169380369435
Mars: 588.054778777641
Jupiter: 50.465364764015256
Saturn: 15.012033723419389
Uranus: 3.7138672928371683
Neptune: 1.5109447200572361
These are the solar constants for each planet in Watts. This is the average amount of solar energy received at the planet each second per square meter. The value calculated for Earth by the Xholon application (about 1366 Watts per square meter), is close to the measured value reported in Wikipedia or the slightly higher value here.

Sunspots slightly alter the amount of energy the Sun radiates, and tend to increase and decrease in quantity over an 11-year period. They introduce a small variablity to the Xholon application, and are a useful test. Select the following line of XML, and drag and drop, or copy and paste, it to the Sun node in the Xholon tree (called Sun:star_7 or something similar). If the application is running and not paused, you should start to see a periodic variation in the numbers that are displayed in the Java Console.


Press the Refresh button, and look for the SunspotCycleAO node as a child of Sun. That part of the composite structure hierarchy should now be:

 <Star roleName="Sun">
   <SunspotCycleAO />

All of the Java source code is available under an open-source license. Some of the source code can be accessed from the application while it's running. To see how SunspotCycleAO has been implemented in Java:

return to main page