Crates.io | vegas-lattice |
lib.rs | vegas-lattice |
version | 0.9.0 |
source | src |
created_at | 2017-09-12 05:56:41.946162 |
updated_at | 2024-09-19 10:11:24.960513 |
description | CLI and library to work with lattices |
homepage | https://github.com/odarbelaeze/vegas-lattice-rs |
repository | https://github.com/odarbelaeze/vegas-lattice-rs |
max_upload_size | |
id | 31469 |
size | 141,372 |
A little tool to build lattices and samples out of patterns written in rust.
vegas-lattice-rs
can be used as a standalone executable in order to build
yourself some lattices and otherwise it can be used as a rust crate (library).
If you have cargo
installed in your system, you can grab the executable from
crates.io using:
cargo install vegas-lattice
after runing that you will have an executable vegas-lattice
in your system
that will run as expected.
If you intent to use it as a library just add the the following line to your
Cargo.toml
:
vegas-lattice = "*"
Pin it at will when you're done, since this is an actively developed package.
I'd recommend to alias vegas-lattice
to something shorter, since the
pipelines can get really complex real quick.
alias vl=vegas-lattice
Now, lets write a basic example,
vl bcc \
| vl expand --along-x 10 --along-y 10 --along-z 5 \
| vl alloy A Fe+ 50 Fe 50 \
| vl alloy B Fe+ 50 Fe 50 \
| vl into xyz
This command will create a 10x10x5 bcc lattice, and will turn half the iron sites into iron + and after that it will transform the lattice into an xyz file representation.
Notice that you can pipe the output of one command to the next one using the standard io.