  ________________________________________________________________________
 /                                                                        \
|                !JULIA v1.10: Quadratic Julia Plotter                     |
|                              18 May 1991                                 |
|                              by Mike Curnow                              |
 \________________________________________________________________________/ 

Introduction
============
!Julia is a fast desktop Julia plotter that provides virtually unlimited
exploration of the quadratic Julia set. It provides full zooming, restart
and colouring facilities, and multi-tasks where appropriate. It uses fast
integer arithmetic to magnifications of around 60,000, then switches to
floating point there on. The Julia image is displayed in 256 colours.

A brief guide to usage.
----------------------
Double click on the filer icon, then click on the icon-bar icon to display
the initial Julia set. Press Menu and then select Zoom. Use the left mouse
button to zoom in, and the middle button to zoom out. Press the right button
to start the redraw operation. At low magnifications the machine will be
locked until the redraw is complete (usually less than 3 minutes).

At high magnifications (you will notice the dramatic speed decrease) you can
return to the desktop while plotting continues, by pressing Menu twice and
selecting Hide.

The Display menu option gives access to previous images and various colour
modifications, whilst Hide temporarily closes the window. Note however that
when in full screen mode that the desktop is still active - its just that
the other windows are hidden.

The screen can be saved by using the Save option. Saved drawings may be
reloaded by simply dragging the saved sprite onto the !Julia icon, allowing
zooming to re-commence.

Full Operation Information
==========================
!Julia requires a considerable amount of storage : 300k for itself, 160k for
a Mode 15 screen and 60k for the shared C library, so be prepared. The Julia
plot is displayed as a full screen window which may be hidden at any time by
selecting Hide from the menu.

Automatic Last Display Save
---------------------------
All operations which modify the Julia image will save the current display in
memory, except for Invert which is self cancelling. The prior image may be
recalled by selecting Previous from the menu. Thus you can zoom in to
inspect an area, then quickly back out to the previous display. To maintain
further images use the load and save facilities.

The Menu Options
----------------
The menu options are available from the icon bar or from the full screen
window. All options except Zoom and Hide will work from the icon bar, though
obviously you will not see colour effects until you open the window.
Pressing Adjust instead of Select will keep the menu open.

ZOOM: Activates the zoom box and re-plotting process. Moving the mouse moves
the box, even beyond the edge of the screen. The mouse buttons have the
following effect:

    Left: Zoom in
  Middle: Zoom out (max. 2 times magnification)
   Right: Start zoom

On pressing Start the new display will be drawn. For magnifications up to
60,000 times it is not possible to interrupt the re-draw. For higher
magnifications, the plotting will commence in dedicated mode (which is the
fastest) until you press Menu, at which time desktop mode is re-entered. The
plotting will continue in the background and the screen will not be
automatically updated.

To see the state of the display when in background mode, Hide the screen
then click on the icon bar as normal. Dedicated mode will be re-entered and
the screen will be drawn in synch with the plotting. If you are in desktop
mode when plotting completes, !Julia will automatically display the
completed screen by opening a full screen window.

Background plotting allows you to carry on using other desktop applications,
though you will notice some reduction in speed (Nb. entering commands such
as *BASIC will halt all desktop operations!). Background plotting will take
much longer, so if you leave the machine it is best to re-enter dedicated
mode by clicking on the icon bar to re-open the Julia window.


FACTORS: leads to a submenu which displays and allows entry of the variables
that are used to create the Julia plot.
  XY        : shows the X and Y values of each corner of the screen.
              These can only be modified by Zooming.
  Levels    : the number of iterations before stopping each calculation.
              Higher numbers will take longer but show more detail at higher
              magnifications. Values >256 will cause colour wrap around.
  cReal &
  cImaginary: constants used as part of the Julia calculation.
              Varying these alters the form of the Julia image.


DISPLAY: leads to a submenu allowing alteration of the current displayed
image.
  Hide      : closes the full screen window. It may be re-opened by
              clicking on the iconbar.
  Invert    : Inverts the colours used for the display. This can improve
              looks. Selecting invert again restores the colours.
  B&W       : converts the display to Black & White. This will show how the
              image will look if printed.
  Grey      : converts the display to 12 grey levels, which can produce a
              better printed image than B&W. Use Invert before grey to
              change the order of grey tones.
  Cycle     : Simulates animation by continuous cycling of the colour by 1, 
              except for black which is left unchanged.
              To change the direction use Invert prior to animation.
              The mouse buttons whilst in animation operate as follows:
                Select: pause the animation
                Menu  : end the animation
                Adjust: re-start after a pause
              Animation works best where there are spirals of colours -
              it can be quite an hypnotic effect!
  Previous  : restores the previous image, ie. to the state before the last
              image alteration (except Invert).
  Initial   : restores the display to the initial Julia set.


SAVE: allows the current Julia image and parameters to be saved as a sprite.
The name of the sprite can be over typed before selecting. The default value
of <JuliaS$Dir> is the directory in which !Julia resides. You can change
this by editing the !Run file within !Julia. A "Save As" icon is not
presented since this would be of little use in full screen mode.

!Julia sprites are totally compatible with !Paint, !Draw etc. They contain
additional information however to allow them to be re-used within !Julia.
Thus you can save a position and carry on examination some time later. To
reload a Julia sprite simply drag it onto the !Julia icon - a full screen
window will be opened to display the image.

Note that !Julia sprites are saved in Mode 13 format though they are
displayed in Mode 15 for desktop ease of use. !Julia sprites use the AFG1
sprite format for storing parameter information : contact AFG for further
details on AFG1.

QUIT: Exits !Julia. No warning is given if a redraw is in progress our if
you have not saved the current position.


Background Operation Notes
--------------------------
Background redraw is automatically cancelled if any of the image alteration
menu options are selected, or if a new sprite is loaded. The normal way to
stop a re-draw is to select Previous.

Changing any of the Julia factors during re-draw will have immediate effect.

Resuming A Plot
---------------
A saved Julia sprite can be used as the new starting point for investigation
by simply dragging it's filer icon onto the !Julia icon. Only !Julia sprites
are accepted.

Julia Algorithm
---------------
The routine used to calculate the image is as follows:

   iter=0
   finished=FALSE
   xSq=x*x
   ySq=y*y
   do 
     iter=iter+1
     y=x*y
     y=y+y-cImaginary
     x=xSq-ySq-cReal
     xSq=x*x
     ySq=y*y
     distanceSq=xSq+ySq
     if distanceSq>=4 then finished=TRUE
   while (iterno<MaxIt AND NOT finished)
   if finished=TRUE then colour=iterno
   else colour=0

where x and y are calculated for each pixel displayed, and MaxIt is the
maximum iterations before plotting. Note the use of inverse colours. These
are plotted directly to the screen (ie. the physical colours) and are
plotted this way for better effect. This algorithm was taken from the
excellent book: Dynamical Systems & Fractals by Becker & Drfler, CUP.


Programming
-----------
!Julia is written in C except for the integer plot routines and colour cycle
(JuliaAsm) which are in ARM assembler for maximum speed. Contact me if you
would like to know how to call JuliaAsm and use it within your own programs.
The cycling routine comes from !AFGSprite.

History
-------
1.00 April 1991 : Created and released for AFG launch within 2 weeks.
1.10 May   1991 : Added cycling routine for coffee table browsers!

To come (a wish list):
Load a sprite from the menu.

Automatically update the save sprite name on a numerical basis.

Compressed sprite files.

Direct input of X & Y values.

Batch operation - ie. create a text file of co-ordinates, feed it into
!Julia, go to sleep, then come back to find loads of nice sprites on your
disk (this will definitely require sprite compression).

Many more image manipulation facilities.

A faster floating point routine (the speed difference is embarassing!).

I may consider a background integer routine, but I am the lucky owner of an
ARM-3 which does the integer plot in under 30 seconds, 6 seconds flat out!


Final Boring Copywright Notice
==============================
The copywright of this material belongs to Mike Curnow except for the !Help
application which belongs to J Rling. This software may be passed on to
others as long as NO CHARGES ARE LEVIED except to cover costs.


Archimedes Fractal Group (AFG)
==============================
This software is part of the Archimedes Fractal Group collection. If you
have obtained this software outside of the AFG and would like to find out
more about Fractals on the Archimedes, contact me (the AFG administrator) at
the address below. Send a SAE and a disk to get a free AFG demo disk.

Mike Curnow,
30 Bowen Drive,
West Dulwich,
London
SE21 8PN

                       
                   <<<< MAY THE CHAOS BE WITH YOU! >>>>
