Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F91667627
PaqAtcUtility.cpp
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Wed, Nov 13, 06:50
Size
2 KB
Mime Type
text/x-c
Expires
Fri, Nov 15, 06:50 (2 d)
Engine
blob
Format
Raw Data
Handle
22304072
Attached To
rLAMMPS lammps
PaqAtcUtility.cpp
View Options
// ATC transfer headers
#include "PaqAtcUtility.h"
#include "ATC_Method.h"
#include "FE_Engine.h"
namespace
ATC
{
//--------------------------------------------------------
//--------------------------------------------------------
// Class PaqAtcUtility
//--------------------------------------------------------
//--------------------------------------------------------
//--------------------------------------------------------
// Constructor
//--------------------------------------------------------
PaqAtcUtility
::
PaqAtcUtility
(
ATC_Method
*
atc
,
AtomType
atomType
)
:
atc_
(
atc
),
atomType_
(
atomType
),
myNlocal
(
NULL
)
{
switch
(
atomType_
)
{
case
ALL:
myNlocal
=
&
ATC_Method
::
nlocal_total
;
break
;
case
INTERNAL:
myNlocal
=
&
ATC_Method
::
nlocal
;
break
;
case
GHOST:
myNlocal
=
&
ATC_Method
::
nlocal_ghost
;
break
;
case
PROC_GHOST:
myNlocal
=
&
ATC_Method
::
nproc_ghost
;
break
;
default
:
// default cases to avoid compiler warnings
break
;
}
}
//--------------------------------------------------------
// nlocal
//--------------------------------------------------------
int
PaqAtcUtility
::
nlocal
()
const
{
return
(
atc_
->*
myNlocal
)();
}
//--------------------------------------------------------
// nlocal_total
//--------------------------------------------------------
int
PaqAtcUtility
::
nlocal_total
()
const
{
return
atc_
->
nlocal_total
();
}
//--------------------------------------------------------
// nsd
//--------------------------------------------------------
int
PaqAtcUtility
::
nsd
()
const
{
return
atc_
->
nsd
();
}
//--------------------------------------------------------
// dt
//--------------------------------------------------------
double
PaqAtcUtility
::
dt
()
const
{
return
atc_
->
dt
();
}
//--------------------------------------------------------
// atc_to_lammps_map
//--------------------------------------------------------
const
Array
<
int
>
&
PaqAtcUtility
::
atc_to_lammps_map
()
const
{
return
(
atomType_
==
INTERNAL
)
?
(
atc_
->
internal_to_atom_map
())
:
(
atc_
->
ghost_to_atom_map
());
}
//--------------------------------------------------------
// fe_engine
//--------------------------------------------------------
const
FE_Engine
*
PaqAtcUtility
::
fe_engine
()
const
{
return
atc_
->
fe_engine
();
}
};
Event Timeline
Log In to Comment