lattice spacing after clear

Hi Axel,

Here's the input file and output file. The purpose is to scan the
primitive vector length for energy.

What I notice is from the output is the incorrect lattice spacing after
the clear in the do loop on the second iteration.

Thanks again,
John

Dear Lammps-users,

I am having a problem where I do

lattice diamond $a
...
clear
...
lattice diamond $a

The issue is that I get output for the first lattice command:
lattice � � � � diamond ${a}
lattice � � � � diamond 3.55645087
Lattice spacing in x,y,z = 3.55645 3.55645 3.55645

But I get for the output for the second (and subsequent) lattice command:
lattice � � � � diamond ${a}
lattice � � � � diamond 3.787389238
Lattice spacing in x,y,z = 1.28307 1.28307 1.28307

I don't know if this is a bug - Is there a way to change the
lattice scale when looping for a scan?

there is too little information to give a qualified answer.
the explanation has to be in the parts that you don't show.

my guess would be that you have inconsistent units
before and after the "clear".

axel.

Thanks,
John

------------------------------------------------------------------------------

For Developers, A Lot Can Happen In A Second.

Boundary is the first to Know...and Tell You.
Monitor Your Applications in Ultra-Fine Resolution. Try it FREE!

check.in (649 Bytes)

check.out (14.8 KB)

Hi Axel,

Here's the input file and output file. The purpose is to scan the
primitive vector length for energy.

What I notice is from the output is the incorrect lattice spacing after
the clear in the do loop on the second iteration.

yes, because you jump to the label "loop",
but before that label, you change your units
to metal. after the clear, this doesn't happen
and thus you don't get metal units, but lj units
(the default) and for lj units the lattice parameter
has a different meaning. check out the attached
file instead:.

axel.

check-ak.in (645 Bytes)

Very nice, thanks Axel!

John