TABLE OF CONTENTS
::pwtk::pwi::replaceCoor
SYNOPSIS
proc ::pwtk::pwi::replaceCoor {coorLines {lengthUnit ""}} {
PURPOSE
Overwrite the ATOMIC_POSITIONS card with the new atomic coordinates as specified by coorLines in such a way that the old if_pos(:) records are maintained (the fixed components will remain fixed even if $coorLines does not have the if_pos(:) fields. This requires that $coorLines contain the same number of atoms as the current (old) ATOMIC_POSITIONS card.
BEWARE: works for non-path calculations !!!
ARGUMENTS
- coorLines -- atomic coordinates in form:
atmSym1 x1 y1 z1 atmSym2 x2 y2 z2 ...
- lengthUnit -- unit in which atomic coordinates in $coorLines are specified (optional, default = {}, which means the length unit used in ATOMIC_POSITIONS card)
SOURCE
set atmPos [::pwtk::pwi::coorToAtmPos $coorLines] if { $lengthUnit == "" } { set lengthUnit [::pwtk::input::cardGetFlags ATOMIC_POSITIONS] } ATOMIC_POSITIONS $lengthUnit $atmPos ::pwtk::pwi::setNAtoms }