User guide
#endif
Endof#if-#else-#endifcodeblock.
#include
Includecodefromanotherfileinprogram.
#lineson
Compileprogramwithlinenumberandfilename
records.
#linesoff
Compileprogramwithoutlinenumberandfilename
records.
#srcfile
Insertsourcefilenamerecordatthispoint(currently
usedwhendoingdatalooptranslation).
#srcline
Insertsourcefilelinenumberrecordatthispoint
(currentlyusedwhendoingdatalooptranslation).
The#definestatementcanbeusedtodefineabstractconstants.Forexample,you
coulddefinethedefaultgraphicspagesizeas:
#define hpage 9.0
#define vpage 6.855
andthenwriteyourprogramusinghpageandvpage.GAUSSwillreplacethemwith
9.0and6.855whenitcompilestheprogram.Thismakesaprogrammuchmorereadable.
The#ifdef-#else-#endifdirectivesallowyoutoconditionallycompilesectionsof
aprogram,dependingonwhetheraparticularflagvariablehasbeen#define'd.For
example:
#ifdef log_10
y = log(x);
#else
y = ln(x);
#endif
9-6
GAUSSUser Guide