Avizo* XPand* Modules with Intel® Math Kernel Library

Table of Contents

Introduction

Avizo*  is a software application which enables users to perform interactive visualization and computation on 3D data sets, where users manipulate data and module components. Data and modules can be interactively connected together, creating a visual processing network whose output is displayed in a 3D viewer. With the Avizo* XPand* extension, Avizo can also be extended by programmers. The Avizo XPand extension permits creation of new custom components for Avizo such as file readers and writers, computation modules, and even new visualization modules, using the C++ programming language. On Windows*, in order to add custom extensions to Avizo with the Avizo XPand extension, you will need Microsoft Visual Studio* 2010 and its Service Pack 1. Moreover, to develop customized Avizo XPand computation modules, it is often necessary to employ the Intel® Visual Fortran Composer XE 2011. These numerical computations in Fortran often rely on the Intel® Math Kernel Library (Intel® MKL) to successfully build in Microsoft Visual Studio* 2010. This article demonstrates how to build Intel® Visual Fortran projects with Intel MKL, and how to use the C++ programming language to integrate these projects with the Avizo XPand extension, effectively bypassing the need for High Performance Computing (HPC).

One can use Intel® Parallel Studio XE 2013 SP1 within the Microsoft Visual Studio* 2010 Integrated Development Environment (IDE). This article provides information for linking your application with Intel MKL from Microsoft Visual Studio* 2010 and Intel® C++ Composer XE and Intel® Visual Fortran Composer XE 2013 SP1. For purposes of demonstration, we will incorporate an application for use with Avizo* software (v8.1). Avizo* is a general-purpose commercial software application for scientific and industrial data visualization and analysis.

In order to begin, we first must ensure that Avizo* is correctly integrated within Microsoft Visual Studio* 2010.

Creating an Avizo* XPand* Project

a) Open Avizo v8.1.

b) On the main menu, select XPand > Development Wizard > Set local Avizo directory > Copy example package to start building your application in the <project directory>.

c) Close and re-open Avizo v8.1.

d) On the main menu, select XPand > Development Wizard > Add package to local Avizo directory to name your application <project name>.

e) Select XPand > Development Wizard > Add component > compute module.

f) Add component in package: <project name>.

g) Select Create Build System > All local packages > Visual Studio 2010 projects > OK.

Creating an Intel® Visual Fortran Project

a) Open Intel Parallel Studio XE 2013 SP1 within the Microsoft Visual Studio 2010.

b) On the main menu, select File > Open > Project/Solution > to open the <project name>.sln (i.e., Microsoft Visual Studio Solution file) in the <project directory>.

c) Select File > Add > New Project > Intel Visual Fortran > Console Application > Empty Project. Enter <project name> and <project directory>.

Adding necessary sources of Avizo XPand Project to Intel Visual Fortran project

The next steps are performed inside the Solution Explorer window. To open it, select View > Solution Explorer from the main menu.

a) Right-click the Source Files folder under <project name> and select Add > Existing Item... from the drop-down menu. The Add Existing Item - <project name> window opens.

b) Browse to the Avizo <project directory>, for example, <project directory>\<project name>. Select the supporting files with extension ".f" or ".f90" (i.e., Fortran source files).

c) From the main menu, select Build > Configuration Manager. Select Active solution configuration > Release, and Active solution platform > x64 and then Close. It is important to note here that Win32 will not work for our application.

d) From the Solution Explorer, right-click the <project name> and select Properties. From Configuration Properties > General > Output Directory, set to <project directory>\bin\arch-Win64VC10-Optimize > Apply.

Configuring project properties to use Intel MKL

a) Select the <project name>.

b) On the main menu, select Project > Properties to open the <project name> Property Pages window.

c) Set the Intel MKL include dependencies.

  1. Select Configuration Properties > Fortran > General. In the right-hand part of the window, select Additional Include Directories >> <Edit...>. The Additional Include Directories window opens.

  2. Type the Intel MKL include directories in quotes: "<mkl directory>\include". Click OK to close the window.

d) Select Configuration Properties > Fortran > Preprocessor. In the right-hand part of the window, select Preprocess Source File > Yes (default is No). This step is recommended because some examples require preprocessing.

e) Set library dependencies

  1. Select Configuration Properties > Linker > General. In the right-hand part of the window, select Additional Library Directories >> <Edit...>. The Additional Library Directory window opens.
  2. Type the directory with the Intel MKL libraries in quotes, that is, "<mkl directory>\lib\<architecture>", where <architecture> in our case is intel64. Click OK to close the window.

  3. Select Configuration Properties > Linker > Input/. In the right-hand part of the window, select Additional Dependencies and type the libraries required. For our particular example (i.e., intel64 math kernel library PARDISO), the required libraries will be:

    mkl_intel_ilp64.lib
    mkl_intel_thread.lib
    mkl_core.lib
    libiomp5md.lib

  4. Select Configuration Properties > Linker > Command Line > Additional Options. Type /DLL > Apply > OK.
  5. From the main menu, select Build > Build Solution. As seen below, the Intel Visual Fortran component of the project has built successfully.

Converting Fortran source files for use with Avizo XPand

a) Typical Fortran programs will consist of some basic commands, and calls to subroutines. However, when using Intel Visual Fortran for applications with Intel MKL and Avizo XPand, we will need to modify the structure of the Fortran source files.

b) For example, before our modifications in .f90, we have

PROGRAM SPFLOW

 USE DOMAIN_DECLARATIONS
 USE SPFLOW_DECLARATIONS
 USE NETWORK_DECLARATIONS

 IMPLICIT NONE
 INTEGER :: I,J
 REAL*8 :: VAL1, VAL2, DSECND
 LOGICAL :: NCHECK

 WRITE(*,*) ' Reading inputs...'
 CALL INITIALIZERUN

 WRITE(*,*) ' Reading networks...'
 CALL INITIALIZENETWORK

 WRITE(*,*) ' Initialize arrays...'
 CALL INITIALIZEARRAYS

! CALL CHECKNETWORK

 CALL CPU_TIME(VAL1)
 ! Initialize the current run and check the initial condition                                                                             
 WRITE(*,*) ' Initialize run...'
 IF (PBC) THEN
    WRITE(*,*) ' Periodic boundary condition...'
    ! Single-phase flow                                                                                                                   
    WRITE(*,*) ' Current code only works for non-periodic networks...'
 ELSE
    WRITE(*,*) ' Non-periodic boundary condition...'
    ! Single-phase flow                                                                                                                   
    WRITE(*,*) ' Single phase simulation...'
    CALL SPPERM2
 ENDIF

 call deallocateARRAYS
 CALL CPU_TIME(VAL2)

 WRITE(*,*) ' Simulation time(elapsed CPU time,s)=:', (VAL2-VAL1)/7.84

 END PROGRAM
    

c) After our modifications, we will have something like...

SUBROUTINE SPFLOWDEMO &
(FILEINin,PERIODICin,CONVERSIONin,MUNWin, &
                    PBCin,DELTAPin,THETA1in,PHI1in,THETA2in, &
                    PHI2in,THETA3in,PHI3in,PREFin,METHOD_HCMABin,TESTin,IMUNWin, &
                    NBOUNin,matrixk11in,matrixk12in,matrixk13in,matrixk21in, &
                    matrixk22in,matrixk23in,matrixk31in,matrixk32in,matrixk33in) 
                    
!DEC$ ATTRIBUTES DLLEXPORT :: SPFLOWDEMO
!DEC$ ATTRIBUTES REFERENCE :: SPFLOWDEMO
!DEC$ ATTRIBUTES REFERENCE :: FILEINin 
!DEC$ ATTRIBUTES REFERENCE :: PERIODICin 
!DEC$ ATTRIBUTES REFERENCE :: CONVERSIONin 
!DEC$ ATTRIBUTES REFERENCE :: MUNWin 
!DEC$ ATTRIBUTES REFERENCE :: PBCin 
!DEC$ ATTRIBUTES REFERENCE :: DELTAPin 
!DEC$ ATTRIBUTES REFERENCE :: THETA1in 
!DEC$ ATTRIBUTES REFERENCE :: PHI1in 
!DEC$ ATTRIBUTES REFERENCE :: THETA2in 
!DEC$ ATTRIBUTES REFERENCE :: PHI2in 
!DEC$ ATTRIBUTES REFERENCE :: THETA3in 
!DEC$ ATTRIBUTES REFERENCE :: PHI3in 
!DEC$ ATTRIBUTES REFERENCE :: PREFin 
!DEC$ ATTRIBUTES REFERENCE :: METHOD_HCMABin 

!DEC$ ATTRIBUTES REFERENCE :: TESTin 
!DEC$ ATTRIBUTES REFERENCE :: IMUNWin
!DEC$ ATTRIBUTES REFERENCE :: NBOUNin

!DEC$ ATTRIBUTES REFERENCE :: matrixk11in
!DEC$ ATTRIBUTES REFERENCE :: matrixk12in
!DEC$ ATTRIBUTES REFERENCE :: matrixk13in

!DEC$ ATTRIBUTES REFERENCE :: matrixk21in
!DEC$ ATTRIBUTES REFERENCE :: matrixk22in
!DEC$ ATTRIBUTES REFERENCE :: matrixk23in

!DEC$ ATTRIBUTES REFERENCE :: matrixk31in
!DEC$ ATTRIBUTES REFERENCE :: matrixk32in
!DEC$ ATTRIBUTES REFERENCE :: matrixk33in

! Expose subroutine SPFLOWDEMO to users of this DLL
! MS$ATTRIBUTES DLLEXPORT,ALIAS:'SPFLOWDEMO' :: SPFLOWDEMO

 USE DOMAIN_DECLARATIONS
 USE SPFLOW_DECLARATIONS
 USE NETWORK_DECLARATIONS
 
 
        IMPLICIT NONE
        
        INTEGER :: I,J
        REAL*8 :: VAL1, VAL2, DSECND
        LOGICAL :: NCHECK
        CHARACTER(200) :: FILEINin
        INTEGER :: METHOD_HCMABin,NBOUNin
        REAL*8 :: MUNWin
        LOGICAL :: PERIODICin,PBCin
        REAL*8 :: DELTAPin,PREFin

        REAL*8 :: THETA1in,THETA2in,theta3in
        real*8 :: phi1in,phi2in,phi3in
        REAL*8 :: CONVERSIONin
        REAL*8 :: TESTin,IMUNWin
        REAL*8 :: matrixk11in
        REAL*8 :: matrixk12in
        REAL*8 :: matrixk13in
        REAL*8 :: matrixk21in
        REAL*8 :: matrixk22in
        REAL*8 :: matrixk23in
        REAL*8 :: matrixk31in
        REAL*8 :: matrixk32in
        REAL*8 :: matrixk33in    
       

FILEIN=FILEINin 
PERIODIC=PERIODICin 
CONVERSION=CONVERSIONin 
MUNW=MUNWin 
PBC=PBCin 
DELTAP=DELTAPin 
THETA1=THETA1in 
PHI1=PHI1in 
THETA2=THETA2in 
PHI2=PHI2in 
THETA3=THETA3in 
PHI3=PHI3in 
PREF=PREFin 
METHOD_HCMAB=METHOD_HCMABin 

TESTin=25


 !WRITE(*,*) ' Reading inputs...'
 CALL INITIALIZERUN(IMUNWin)
 
 !WRITE(*,*) ' Reading networks...'
 CALL INITIALIZENETWORK

 !WRITE(*,*) ' Initialize arrays...'
 CALL INITIALIZEARRAYS(NBOUNin)
 

! CALL CHECKNETWORK
 !CALL CPU_TIME(VAL1)
 ! Initialize the current run and check the initial condition                                                                             
 !WRITE(*,*) ' Initialize run...'
 IF (PBC) THEN
  !  WRITE(*,*) ' Periodic boundary condition...'
    ! Single-phase flow                                                                                                                   
   ! WRITE(*,*) ' Current code only works for non-periodic networks...'
 ELSE
   ! WRITE(*,*) ' Non-periodic boundary condition...'
    ! Single-phase flow                                                                                                                   
   ! WRITE(*,*) ' Single phase simulation...'
    CALL SPPERM2(matrixk11in,matrixk12in,matrixk13in, &
        matrixk21in,matrixk22in,matrixk23in, &
        matrixk31in,matrixk32in,matrixk33in)
 ENDIF

 call deallocateARRAYS
 !CALL CPU_TIME(VAL2)

! WRITE(*,*) ' Simulation time(elapsed CPU time,s)=:', (VAL2-VAL1)/7.84
RETURN
 END SUBROUTINE
    

d) In this way, we have converted the .f90 source program into a subroutine. This is done such that the Fortran source code can be wrapped with C++ to make a graphical user interface (GUI) for use with Avizo. If no GUI is implemented, the user will have to call on an input file in order to get the information to the Fortran program. An example input file can be seen below.

Using Visual C++ to add a GUI to the Intel Visual Fortran project

a) The Avizo XPand Development wizard has automatically generated a C++ source and header for our project, which can be found in the <project directory>. Upon examination, our source reads:

#include <QApplication>

#include <hxcore/HxMessage.h>
#include <hxfield/HxUniformScalarField3.h>

#include "tensork.h"

HX_INIT_CLASS(tensork,HxCompModule)

tensork::tensork() :
    HxCompModule(HxUniformScalarField3::getClassTypeId()),
    portAction(this,"action",QApplication::translate("tensork", "Action"))
{
    portAction.setLabel(0,"DoIt");
}

tensork::~tensork()
{
}

void tensork::compute()
{
    if (portAction.wasHit()) {
        theMsg->printf("do something\n");
    }
}
    

and our header reads:

#ifndef TENSORK_H
#define TENSORK_H

#include <hxcore/HxCompModule.h>
#include <hxcore/HxPortDoIt.h>

#include "api.h"

class TENSORK_API tensork : public HxCompModule
{
    HX_HEADER(tensork);

  public:

    tensork();
    ~tensork();

    HxPortDoIt portAction;

    virtual void compute();
};

#endif 
    

b) From some simple modifications to our source and header, we can realize a GUI in Avizo. This can be accomplished by referencing the Fortran subroutine SPFLOWDEMO, where the variables entered into the GUI are represented by 'ports' and are initially filled with some default values.  For example, a simple modification to the source will output the results to the Avizo console, like:

#include <QApplication>
#include <hxcore/HxMessage.h>
#include <hxspreadsheet/HxSpreadSheet.h>
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include "mkl_pardiso.h"
#include "mkl_types.h"
#include "mkl_spblas.h"
#include "tensork.h"

 extern "C" {void SPFLOWDEMO(const char* FILEINin, bool* PERIODICin, double* CONVERSIONin, double* MUNWin, 
                    bool* PBCin, double* DELTAPin, double* THETA1in, double* PHI1in, double* THETA2in, 
                    double* PHI2in, double* THETA3in, double* PHI3in, double* PREFin, const int* METHOD_HCMABin,
                    double* TESTin, double* IMUNWin, const int* NBOUNin, double* matrixk11in, double* matrixk12in,
                    double* matrixk13in, double* matrixk21in, double* matrixk22in, double* matrixk23in,
                    double* matrixk31in, double* matrixk32in, double* matrixk33in);} 
                    
        
    
    
HX_INIT_CLASS(tensork,HxCompModule)

tensork::tensork() :
    HxCompModule(HxSpreadSheet::getClassTypeId()),
    
    //port FILEIN
    portInputc(this,"inputc",QApplication::translate("tensork", "Inputc")),
    
    //port for work directory - used for FILEIN 
    portWorkDir(this,"directory",QApplication::translate("tensork", "directory")),
    
    //port PERIODIC
    portVoxTags(this,"creatImageWithTags",QApplication::translate("tensork", "creatImageWithTags"),2),
    
    //port CONVERSION
    portInputg(this,"inputg",QApplication::translate("tensork", "Inputg")),
    
    //port MUNW
    portInputh(this,"inputh",QApplication::translate("tensork", "Inputh")),
    
    //port PBC
    portPBC(this,"creatPBC",QApplication::translate("tensork", "creatPBC"),2),
    
    //port DELTAP
    portDELTAP(this,"inputDELTAP",QApplication::translate("tensork", "InputDELTAP")),
    
    //port THETA1
    portTHETA1(this,"inputTHETA1",QApplication::translate("tensork", "InputTHETA1")),
    
    //port PHI1
    portPHI1(this,"inputPHI1",QApplication::translate("tensork", "InputPHI1")),
    
    //port THETA2
    portTHETA2(this,"inputTHETA2",QApplication::translate("tensork", "InputTHETA2")),
    
    //port PHI2
    portPHI2(this,"inputPHI2",QApplication::translate("tensork", "InputPHI2")),
    
    //port THETA3
    portTHETA3(this,"inputTHETA3",QApplication::translate("tensork", "InputTHETA3")),
    
    //port PHI3
    portPHI3(this,"inputPHI3",QApplication::translate("tensork", "InputPHI3")),
    
    //port PREF
    portPREF(this,"inputPREF",QApplication::translate("tensork", "InputPREF")),
    
    //port METHOD_HCMAB
    portMinVoxThroat(this,"enterMinimum",QApplication::translate("tensork", "enterMinimum")),   
    
    //port for starting module  
    portAction(this,"action",QApplication::translate("tensork", "Action"))
    
{

    //port FILEIN
    portInputc.setLabel("Input (.psn) filename:");
    portInputc.setValue("sandmnp42p.psn");
    
    //port for work directory - used for FILEIN 
    portWorkDir.setLabel("please select workspace directory");
    
    //port PERIODIC
    portVoxTags.setLabel("Periodic network structure (T/F):");
    portVoxTags.setLabel(0,"True");
    portVoxTags.setLabel(1,"False");
    portVoxTags.setValue(1);
    
    //port CONVERSION
    portInputg.setLabel("Conversion factor(voxel-->cm):");
    portInputg.setValue(1);
    
    //port MUNW
    portInputh.setLabel("Viscosity of defending phase(g/(cm*s)):");
    portInputh.setValue(1e-2);
        
    //port PBC
    portPBC.setLabel("Periodic boundary conditions (T/F):");
    portPBC.setLabel(0,"True");
    portPBC.setLabel(1,"False");
    portPBC.setValue(1);
    
    //port DELTAP
    portDELTAP.setLabel("Periodic pressure gradient(g/(cm*s2)):");
    portDELTAP.setValue(0.1);
    
    //port THETA1
    portTHETA1.setLabel("Flow direction (angle 1: y axis):");
    portTHETA1.setValue(60);
    
    //port PHI1
    portPHI1.setLabel("Flow direction (angle 2: z axis):");
    portPHI1.setValue(45);
    
    //port THETA2
    portTHETA2.setLabel("Flow direction (angle 1: y axis):");
    portTHETA2.setValue(45);
    
    //port PHI2
    portPHI2.setLabel("Flow direction (angle 2: z axis):");
    portPHI2.setValue(45);
    
    //port THETA3
    portTHETA3.setLabel("Flow direction (angle 1: y axis):");
    portTHETA3.setValue(30);
    
    //port PHI3
    portPHI3.setLabel("Flow direction (angle 2: z axis):");
    portPHI3.setValue(30);
    
    //port PREF
    portPREF.setLabel("Reference pressure for PBC(g/(cm*s2)):");
    portPREF.setValue(0);
    
    //port METHOD_HCMAB 
    portMinVoxThroat.setLabel("Method of absolute conductivity(see gij table):");
    portMinVoxThroat.setValue(0);   
    
    portAction.setLabel(0,QApplication::translate("tensork", "Action"));
}

tensork::~tensork()
{
}

void tensork::compute()
{
    // Access the input data object. The member portData (which is of
    // type HxConnection) is inherited from the base class HxModule.
    HxSpreadSheet* field = (HxSpreadSheet*) portData.source();
    
    // Check whether the input port is connected
    if (!field) return;

    // Check whether doIt button was hit
    if (!portAction.wasHit()) return;

    // Get the input parameters from the user interface:
    
    //port FILEIN
    const char* WorkD = portWorkDir.getValue();
                QString Netfile = portInputc.getValue();
                Netfile.insert(0,"/");
                Netfile.insert(0,WorkD);
                QByteArray ba = Netfile.toLocal8Bit();
    
    const char* FILEIN = ba.data();
                
                theMsg->printf(FILEIN);
                
    //PERIODIC
    bool        PERIODIC;
        if (portVoxTags.getIndex() != 0)
            PERIODIC = false;
        else
            PERIODIC = true;
            
    //port CONVERSION
    double      CONVERSION  = portInputg.getValue();
    
    //port MUNW
    double      MUNW        = portInputh.getValue();
    
    //port PBC
    bool        PBC;
        if (portPBC.getIndex() != 0)
            PBC = false;
        else
            PBC = true;
            
    //port DELTAP
    double      DELTAP      = portDELTAP.getValue();    
    
    //port THETA1
    double      THETA1      = portTHETA1.getValue();
    
    //port PHI1
    double      PHI1        = portPHI1.getValue();
    
    //port THETA2
    double      THETA2      = portTHETA2.getValue();
    
    //port PHI2
    double      PHI2        = portPHI2.getValue();
    
    //port THETA3
    double      THETA3      = portTHETA3.getValue();
    
    //port PHI3
    double      PHI3        = portPHI3.getValue();
    
    //port PREF
    double      PREF        = portPREF.getValue();
    
    //port METHOD_HCMAB
    const int           METHOD_HCMAB    = portMinVoxThroat.getValue();
    
    
    double      TEST;
    double      IMUNW;

    double      matrixk11;
    double      matrixk12;
    double      matrixk13;

    double      matrixk21;
    double      matrixk22;
    double      matrixk23;

    double      matrixk31;
    double      matrixk32;
    double      matrixk33;


    int NBOUN;
        
    
                    
    SPFLOWDEMO(FILEIN, &PERIODIC, &CONVERSION, &MUNW, 
                    &PBC, &DELTAP, &THETA1,&PHI1,&THETA2, 
                    &PHI2, &THETA3, &PHI3, &PREF, &METHOD_HCMAB, &TEST, 
                    &IMUNW, &NBOUN, &matrixk11, &matrixk12, &matrixk13,
                    &matrixk21, &matrixk22, &matrixk23, &matrixk31,
                    &matrixk32, &matrixk33);    
    
    
    theMsg->printf("# of boundary pores= %u",NBOUN);

    theMsg->printf("Kxx=: %f\t"
        "Kxy=: %f\t"
        "Kxz=: %f\n",matrixk11,matrixk12,matrixk13);

    theMsg->printf("Kyx=: %f\t"
        "Kyy=: %f\t"
        "Kyz=: %f\n",matrixk21,matrixk22,matrixk23);

    theMsg->printf("Kzx=: %f\t"
        "Kzy=: %f\t"
        "Kzz=: %f\n",matrixk31,matrixk32,matrixk33);
    
    theMsg->printf("Done.");
    
    
}
    

Moreover, we can modify the header:

#ifndef TENSORK_H
#define TENSORK_H

#include <hxcore/HxCompModule.h>
#include <hxcore/HxPortDoIt.h>
#include <hxcore/HxPortText.h>
#include <Amira/HxPortRadioBox.h>
#include <Amira/HxPortFloatTextN.h>
#include <Amira/HxPortIntTextN.h>
#include <hxcore/HxPortDirectory.h>

#include "api.h"    

class TENSORK_API tensork : public HxCompModule
{
    HX_HEADER(tensork);

  public:

    tensork();
    ~tensork();

    HxPortDoIt portAction;

    virtual void compute();
    
    HxPortText      portInputc;
    HxPortRadioBox      portVoxTags;
    HxPortFloatTextN    portInputg;
    HxPortFloatTextN    portInputh;
    HxPortRadioBox      portPBC;   
    HxPortFloatTextN    portDELTAP;     
    HxPortFloatTextN    portTHETA1;     
    HxPortFloatTextN    portPHI1;       
    HxPortFloatTextN    portTHETA2;
    HxPortFloatTextN    portPHI2;
    HxPortFloatTextN    portTHETA3;
    HxPortFloatTextN    portPHI3;       
    HxPortFloatTextN    portPREF;
    HxPortIntTextN      portMinVoxThroat;
    HxPortDirectory     portWorkDir;    
    
};

#endif
    

c) After we have modified the source and the header from the <project directory>, it is necessary to update the VC++ Project > Properties. This can be accomplished from Configuration Properties > General > Output Directory, set to <project directory>\bin\arch-Win64VC10-Optimize > Apply.

d) Next, select Configuration Properties > Linker > General. In the right-hand part of the window, select Additional Library Directories >> <Edit...>, add <project directory>\src\<project name>\x64\Release, etc., as seen below.

e) We will also need to update the general properties for C/C++, such as the Additional Include Directories. This can be seen below.

f) Moreover, the Additional Dependencies in the Linker > Input will have to be customized for your particular application.

g) Next, we will need to modify the resource file (i.e, .rc) located in <project directory>\share\resources generated automatically by Avizo XPand Development Wizard. For example,

module -name     "tensork" \
       -primary  "HxUniformScalarField3" \
       -class    "tensork" \
       -category "Local" \
       -package  "tensork" \
       -icon     "TVDefCompute"
    

will become...

module -name     "tensork" \
       -primary  "HxSpreadSheet" \
       -class    "tensork" \
       -category "PoreSim" \
       -package  "tensork" \
    

h) After we have added the necessary headers to our VC++ project (e.g., mkl_pardiso.h), we can successfully build a dynamic link library (i.e., .dll) for use with Avizo.

i) The .dll file generated by Microsoft Visual Studio 2010 can be used by Avizo as a GUI, effectively replacing the need for the .in file as typically used by high-performance computers (HPCs). The Avizo GUI can be seen below.

j) The console window in Avizo will display identical results as would the HPC. This is useful, as it allows users with little or no HPC experience to access the same information simply by entering some input parameters into the Avizo GUI as seen above.

k) We have verified the results of the Avizo GUI simply by comparing the output for the same Fortran source codes on the HPC. As seen below, the results are identical, confirming the success of the Visual C++ and Intel Visual Fortran projects with Intel Parallel Studio for Intel MKL applications.

Acknowledgements

I would like to thank Dr. Hartmut Kaiser for useful and fruitful discussions. I would also like to thank Dr. Karsten Thompson for inviting me to participate with the PoreSim research consortium.

Resources

http://phys.lsu.edu/~fmoxley

For more complete information about compiler optimizations, see our Optimization Notice.