From DaqWiki
Jump to navigation Jump to search

Physica Links

Extrema links


Primary PHYSICA repository has moved from SVN on ladd00 to GIT on bitbucket:

To get the latest version use: git clone

As of November-2018:

For questions on how to build and run physica, please contact Konstantin Olchanski


PHYSICA is a high level, interactive programming environment with user friendly graphics and sophisticated mathematical analysis capabilities. Over 200 numeric and character functions are provided, as well as over 30 operators, providing all of the operations of simple calculus, along with powerful curve fitting, filtering and smoothing techniques, and employing a dynamic array management scheme allowing arrays limited in size only by system resources. Algebraic expressions of arbitrary complexity are evaluated using a lexical scanner approach. Line graphs, histograms and pie charts, as well as contour, density and surface plots are available. The user interface is a command language with a simple to use and easy to learn syntax, incorporating basic elements of a structured programming language including conditional branching, looping and subroutine calling constructs.

PHYSICA was developed at TRIUMF by Joe Chuma, Fred Jones and other


The old PHYSICA home page from TRSHARE/~chuma is here: (thanks to Kelvin Raywood)

The user guide and the reference guide are here:


Historic PHYSICA executables are available here:

If none of them work for you, follow these instructions to build PHYSICA from sources.

Build on Linux

Only 32-bit PHYSICA is known to work. 64-bit is known to not work. When building on 64-bit Linux, many 32-bit "devel" packages need to be installed.

The Linux Makefile builds 3 flavours of the physica executable:

  • physica : normal dynamically linked executable
  • physica-static : fully static executable (no shared libraries), same as old versions of physica. Cannot be built on SL5/SL6 because they do not supply libX11.a static libraries
  • physica-half-static : link as many libraries as possible statically. This is the recommended executable for general use. It can only be built on 32-bit SL5. (SL6 do not provide many 32-bit static libraries).


Build on MacOS

This was tested on MacOS 10.6, 10.7, 10.8, 10.9.

NOTE: this g77 does not work on MacOS 10.10 - incompatible LLVM "as"

  • install required libraries using MacPorts
    • install MacPorts: download the MacPorts-xxx-Lion.pkg from, install
    • sudo /bin/sh
    • port -v selfupdate
    • port upgrade outdated
    • port install gd2 +universal ### (will take forever because it thinks it needs to build most of everything)
    • port install readline +universal ### up to MacOS 10.6, not needed on MacOS 10.7, 10.8
    • port install readline +universal libpng +universal gd2 +universal ### on MacOS 10.9, will take a long time to install many packages
  • svn checkout
  • cd physica
  • make physica
  • ./physica
  • ### or on MacOS 10.9:
  • make physical-half-static
  • ./physica-half-static
  • @rangauss.pcm