Skip to content

LPP-ERM-KMS/tomcat

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

39 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

TOMCAT [TOroidal Mode Conversion & Absorption Tool]

Compiling

TOMCAT is a wave equation solver based on [Van Eester & Koch, Plasma Phys. Control. Fusion 40 (1998) 1949-1975]. Full documentation can be found on the website nevertheless a short overview is given below.

Cloning & Building

Tomcat is designed to be ran on unix-like machines such as linux-based OSes and macos. To install tomcat, start by cloning the repository to a location you'd like:

    git clone https://github.com/LPP-ERM-KMS/tomcat.git

In the src folder, the folder BLAS holds an old version of BLAS which tomcat leverages, compile this by navigating into the folder and calling make:

    cd tomcat/src/BLAS
    make

Having compiled blas, a file called libblas_TOMCAT_git.a should have been created. Now it is time to compile tomcat, tomcat is a series of fortran codes located in the folder "fortran_sources". For a simple compilation, if you have gfortran installed a compilation script is located in the "scripts" folder:

    cd ../scripts
    ./compile_tomcat

This will create two executables in the "build" folder, one titled "tomcat" and one titled "tomcat_currentdrive" which represent two distinct functionalities of tomcat which are explained in :doc:Usage. Installation is not strictly necessary as the binary can be ran as is but for those interested:

Installating the binary

Having built tomcat it can be installed by adding the "build" folder to PATH, for example by adding::

    export PATH="~/Programs/tomcat/src/build:$PATH"

to bashrc or by copying the executables to a location already in PATH like /usr/bin on linux devices.

Basic usage

To run tomcat, an input file specifying the parameters needs to be passed, an example input file is found in the "input_files" folder titled "Input_TestModBC", an explanation of the input file can be found in :doc:Input, copying this over to a directory in which you'll run the simulation (here tomator_sim), tomcat can be run as (assuming you have installed tomcat, if not the same can be done calling the executable)

    tomcat < Input_TestModBC > Output_TestModBC

This should run tomcat, generating multiple files in the folder titled e.g fort.23, fort.60,... an Output_TestModBC file, a TimeOfRun.dat file and and Input_PrepPlotCD_self_generated.dat file, this last file may be passed to tomcat_currentdrive to calculate the aspects of current drive::

    tomcat_currentdrive < Input_PrePlotCD_self_generated.dat > Output_PrePlotCD

This then creates more fort.* files and the files CurrentDrive_Main_Output.dat, CurrentDrive_Output4Ernesto.dat, CurrentsFile and Output_PrePlotCD.

About

Wave equation solver based on [Van Eester & Koch, Plasma Phys. Control. Fusion 40 (1998) 1949-1975]

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published