Material studio to LAMMPS

Hi
I have created a substrate plus a protein in material studio and I successfully converted the file using msi2lmp. But I don’t know how to do NVT on the .data file.
Can someone please help?

Maybe it would be useful to search for some LAMMPS tutorials to help you get started ^^

1 Like

I don’t know any tutorials for an NVT on a .data file that’s converted from material studio.
If you know any, I would appreciate if you could send it here.
I constantly face errors when I try to use normal NVT script.

Why would a data file from material studio be any special? Also, saying that you constantly face error - without telling us what error - with a normal (what is a normal script?) nvt script wont get you very far here.

You need to provide useful details, LAMMPS version, error message, minimal input script, etc., see the forum rules.

Thank you for your kind comment. I have uploaded the corresponding files to a folder on my Google Drive and have shared a link to the folder because new users are not able to attach files on this website.
I would appreciate it if you could review the files and provide any feedback you may have. Thank you in advance for your time and assistance.

https://drive.google.com/drive/folders/1w5tQbzb3Jj5cFPJj7cK83q2iwR3cKU44?usp=sharing

You get

ERROR: Cannot use read_data add before simulation box is defined

because you are using the ‘add append’ keyword, which is only meant for importing data on an already existing system. Have a look at that page.

It would still give me this error even if I removed the “add apend” part. The error would be something like " the add keyword isn’t used".
How else am I supposed to read the layer.data file and execute an NVT on it?

I see no reason why the error would be " the add keyword isn’t used". That does not make any sense.

After looking at your files, I have to strongly agree with @ceciliaalvares. You need to carefully study some LAMMPS tutorials and example inputs in the examples folder and learn how setting up simulations with LAMMPS works in general.
There are plenty of introductory tutorial materials around. The fact that you are trying to use a data file converted from materials studio does not make the tiniest difference. You need to take your time and learn the basics first. Then setting up your simulation will be much more straightforward and many of the items that are confusing you right now will not. You are trying save time by skipping ahead, but in the process are only slowing yourself down since you run into easily avoidable errors since you don’t know enough about what you are doing.

In addition, you need to pay closer attention to the documentation. It is not just a suggestion about how things might work, but the documentation sets the rules. If you get an error, then you are violated a rule or come across a bug. You cannot just enter something that looks OK to you and hope for the best. There are too many ways that things can go wrong and too few that are correct. As a beginner in using LAMMPS the chances are astronomically high that you are at fault when there is an error and not LAMMPS or the documentation. More importantly, there are many errors and flaws in simulations that are not syntax errors and thus may not be detected right away. If a simulation completes does not mean that it was correct.

Finally, I would be surprised if you will get a meaningful simulation after you have worked out all the trivial issues, since it looks like the original file you created in MS already has serious flaws that will prevent LAMMPS from running a stable simulation. One important step toward resolving such issues is to isolate where the problem is. Since your system has two different components, you should first set up a simulation for each component separately and figure out what kind of settings are required and debug the topology and geometry if the behavior is not as expected or unstable. What I am telling you here is all common sense stuff and standard best practices that you can learn (in person) from a reasonably experienced tutor.

I looked at almost all the examples in the lammps installation directory folder in my computer but none of them use read_data to create the system.
The reason I’m using that .data file is cause the two components are to be relaxed together for 1ns in an NVT ensemble.
I have uploaded the script and the error in the link I sent @simongravelle. I would appreciate it if you could check it out.

You have not told us how you installed LAMMPS and which version of LAMMPS you are using, so I cannot comment on that.

But if you download the LAMMPS source code there will be hundreds of inputs that use the read_data command (see below). Apart from that, just by studying and following the documentation you should have been able to avoid all the errors that you have posted so far.

But that won’t work, since the topology for one of the two components is flawed and cannot be used to perform such a simulation.

I have already looked at it and given you my recommendations. Let me re-iterate: even if you sort out all the syntax and semantics issues and correct your input, it will not work, because the original files passed to msi2lmp must have serious flaws.

lammps]$ grep -l read_data examples/*/in.* examples/*/*/in.* bench/in.*
examples/airebo/in.airebo
examples/airebo/in.airebo-0-0
examples/airebo/in.airebo-m
examples/airebo/in.rebo2
examples/amoeba/in.ubiquitin
examples/amoeba/in.water_box.amoeba
examples/amoeba/in.water_box.hippo
examples/amoeba/in.water_dimer.amoeba
examples/amoeba/in.water_dimer.hippo
examples/amoeba/in.water_hexamer.amoeba
examples/amoeba/in.water_hexamer.hippo
examples/body/in.body
examples/body/in.cubes
examples/body/in.squares
examples/body/in.wall2d
examples/cmap/in.cmap
examples/comb/in.comb3
examples/comb/in.comb.Cu2O.elastic
examples/comb/in.comb.HfO2
examples/coreshell/in.coreshell
examples/coreshell/in.coreshell.dsf
examples/coreshell/in.coreshell.thermostats
examples/coreshell/in.coreshell.wolf
examples/dreiding/in.dreiding
examples/eim/in.eim
examples/fire/in.meam.abcfire
examples/fire/in.meam.fire
examples/fire/in.neb.sivac.abcfire
examples/fire/in.neb.sivac.abcfire_mod
examples/fire/in.neb.sivac.fire
examples/fire/in.neb.sivac.fire_mod
examples/fire/in.neb.sivac.qm
examples/gjf/in.gjf.vfull
examples/gjf/in.gjf.vhalf
examples/grid/in.sph
examples/HEAT/in.lj.ehex
examples/HEAT/in.lj.hex
examples/HEAT/in.spce.ehex
examples/HEAT/in.spce.hex
examples/mc/in.mixed
examples/mc/in.pure
examples/mc/in.widom.lj
examples/mc/in.widom.spce
examples/mdi/in.series.alone
examples/mdi/in.series.driver
examples/mdi/in.series.driver.plugin
examples/mdi/in.snapshot.alone
examples/mdi/in.snapshot.driver
examples/mdi/in.snapshot.driver.plugin
examples/meam/in.meam
examples/micelle/in.micelle
examples/micelle/in.micelle-rigid
examples/mliap/in.mliap.so3.Ni_Mo
examples/mliap/in.mliap.so3.nn.Si
examples/mscg/in.mscg
examples/multi/in.powerlaw
examples/nb3b/in.nb3b
examples/neb/in.neb.hop1
examples/neb/in.neb.hop1.end
examples/neb/in.neb.hop2
examples/neb/in.neb.sivac
examples/peptide/in.peptide
examples/python/in.pair_python_coulomb
examples/python/in.pair_python_hybrid
examples/python/in.pair_python_long
examples/python/in.pair_python_melt
examples/python/in.pair_python_spce
examples/qeq/in.qeq.buck
examples/qeq/in.qeq.reaxc
examples/rdf-adf/in.spce
examples/rdf-adf/in.spce-cutoff
examples/reaxff/in.reaxff.rdx
examples/reaxff/in.reaxff.rdx-shielded
examples/reaxff/in.reaxff.tatb
examples/reaxff/in.reaxff.tatb-shielded
examples/relres/in.22DMH.real
examples/relres/in.22DMH.relres
examples/relres/in.22DMH.respa
examples/rigid/in.rigid
examples/rigid/in.rigid.atomfile
examples/rigid/in.rigid.atomvar
examples/rigid/in.rigid.early
examples/rigid/in.rigid.infile
examples/rigid/in.rigid.molecule
examples/rigid/in.rigid.nve
examples/rigid/in.rigid.nve.early
examples/rigid/in.rigid.poems
examples/rigid/in.rigid.poems2
examples/rigid/in.rigid.poems3
examples/rigid/in.rigid.poems4
examples/rigid/in.rigid.poems5
examples/rigid/in.rigid.property
examples/rigid/in.rigid.small
examples/rigid/in.rigid.small.infile
examples/rigid/in.rigid.tnr
examples/streitz/in.streitz.ewald
examples/streitz/in.streitz.wolf
examples/template/in.hybrid
examples/template/in.mol-data-mix
examples/template/in.tmpl-data-mix
examples/tersoff/in.hBN_shift
examples/threebody/in.mos2.sw.mod
examples/vashishta/in.vashishta.sio2
examples/vashishta/in.vashishta.table.sio2
examples/VISCOSITY/in.cos.1000SPCE
examples/ASPHERE/box/in.box
examples/ASPHERE/box/in.box.mp
examples/ASPHERE/dimer/in.dimer
examples/ASPHERE/dimer/in.dimer.mp
examples/ASPHERE/line/in.line
examples/ASPHERE/line/in.line.srd
examples/ASPHERE/star/in.star
examples/ASPHERE/star/in.star.mp
examples/ASPHERE/tri/in.tri.srd
examples/ASPHERE/vesicle/in.vesicle
examples/COUPLE/lammps_spparks/in.lammps
examples/COUPLE/multiple/in.chain
examples/PACKAGES/agni/in.adatom
examples/PACKAGES/agni/in.vacancy
examples/PACKAGES/awpmd/in.h_atom
examples/PACKAGES/awpmd/in.h_molecule
examples/PACKAGES/bocs/in.methanol
examples/PACKAGES/charge_regulation/in.chreg-acid
examples/PACKAGES/charge_regulation/in.chreg-acid-real
examples/PACKAGES/charge_regulation/in.chreg-polymer
examples/PACKAGES/colvars/in.peptide-colvars
examples/PACKAGES/colvars/in.peptide-colvars2
examples/PACKAGES/colvars/in.peptide-spring
examples/PACKAGES/colvars/in.peptide-spring2
examples/PACKAGES/dielectric/in.confined
examples/PACKAGES/dielectric/in.nopbc
examples/PACKAGES/e3b/in.e3b-tip4p2005
examples/PACKAGES/edip/in.edip-SiC
examples/PACKAGES/ees/in.fix_wall
examples/PACKAGES/ees/in.fix_wall_region
examples/PACKAGES/entropy/in.entropy
examples/PACKAGES/extep/in.extep-bn
examples/PACKAGES/filter_corotate/in.bpti
examples/PACKAGES/filter_corotate/in.peptide
examples/PACKAGES/gauss_diel/in.gauss-diel
examples/PACKAGES/gauss_diel/in.gauss-diel-cg
examples/PACKAGES/gauss_diel/in.gauss-diel-split
examples/PACKAGES/gle/in.h2o-quantum
examples/PACKAGES/gle/in.h2o-smart
examples/PACKAGES/hdnnp/in.hdnnp
examples/PACKAGES/imd/in.bucky-plus-cnt
examples/PACKAGES/imd/in.bucky-plus-cnt-gpu
examples/PACKAGES/imd/in.deca-ala_imd
examples/PACKAGES/imd/in.deca-ala_imd-gpu
examples/PACKAGES/imd/in.deca-ala-solv-filter_imd
examples/PACKAGES/imd/in.deca-ala-solv_imd
examples/PACKAGES/ipi/in.graphene
examples/PACKAGES/manybody_table/in.spce
examples/PACKAGES/manybody_table/in.spce2
examples/PACKAGES/manybody_table/in.spce_sw
examples/PACKAGES/mesont/in.film_mesocnt
examples/PACKAGES/mofff/in.hkust1
examples/PACKAGES/mofff/in.hkust1_long
examples/PACKAGES/momb/in.system
examples/PACKAGES/mop/in.compute_stress_mop
examples/PACKAGES/orient_eco/in.orient_eco
examples/PACKAGES/pafi/in.pafi
examples/PACKAGES/plumed/in.peptide-plumed
examples/PACKAGES/quip/in.gap
examples/PACKAGES/quip/in.molecular
examples/PACKAGES/quip/in.sw
examples/PACKAGES/rhok/in.pinning
examples/PACKAGES/scafacos/in.scafacos
examples/PACKAGES/scafacos/in.scafacos.cw.ewald
examples/PACKAGES/scafacos/in.scafacos.cw.fmm
examples/PACKAGES/scafacos/in.scafacos.cw.p2nfft
examples/PACKAGES/scafacos/in.scafacos.cw.p3m
examples/PACKAGES/scafacos/in.scafacos.ewald
examples/PACKAGES/scafacos/in.scafacos.fmm
examples/PACKAGES/scafacos/in.scafacos.hsph.direct
examples/PACKAGES/scafacos/in.scafacos.hsph.fmm
examples/PACKAGES/scafacos/in.scafacos.hsph.p2nfft
examples/PACKAGES/scafacos/in.scafacos.p2nfft
examples/PACKAGES/scafacos/in.scafacos.p3m
examples/PACKAGES/smtbq/in.smatbAgCuPancake
examples/PACKAGES/smtbq/in.smtbq.Al2O3
examples/PACKAGES/srp/in.srp
examples/PACKAGES/srp_react/in.srp_react
examples/PACKAGES/tally/in.force
examples/PACKAGES/tally/in.pe
examples/PACKAGES/tally/in.stress
examples/PACKAGES/temper_npt/in.temper_npt
examples/PACKAGES/tmd/in.tmd
examples/QUANTUM/LATTE/in.ch4
examples/QUANTUM/LATTE/in.ch4.plugin
examples/QUANTUM/LATTE/in.graphene
examples/QUANTUM/LATTE/in.graphene.plugin
examples/QUANTUM/LATTE/in.series
examples/QUANTUM/LATTE/in.series.plugin
examples/QUANTUM/LATTE/in.sucrose
examples/QUANTUM/LATTE/in.sucrose.plugin
examples/QUANTUM/LATTE/in.uo2
examples/QUANTUM/LATTE/in.uo2.plugin
examples/QUANTUM/LATTE/in.water
examples/QUANTUM/LATTE/in.water.min
examples/QUANTUM/LATTE/in.water.min.plugin
examples/QUANTUM/LATTE/in.water.plugin
examples/QUANTUM/NWChem/in.series
examples/QUANTUM/NWChem/in.series.plugin
examples/QUANTUM/NWChem/in.water.mm
examples/QUANTUM/NWChem/in.water.qmmm
examples/QUANTUM/NWChem/in.water.qmmm.plugin
examples/QUANTUM/NWChem/in.zeolite.mm
examples/QUANTUM/NWChem/in.zeolite.qmmm
examples/QUANTUM/NWChem/in.zeolite.qmmm.plugin
examples/QUANTUM/PySCF/in.mixture.mm
examples/QUANTUM/PySCF/in.mixture.qmmm
examples/QUANTUM/PySCF/in.mixture.qmmm.plugin
examples/QUANTUM/PySCF/in.water.qmmm
examples/QUANTUM/PySCF/in.water.qmmm.plugin
examples/reaxff/AB/in.AB
examples/reaxff/AuO/in.AuO
examples/reaxff/CHO/in.CHO
examples/reaxff/ci-reaxFF/in.ci-reax.CH
examples/reaxff/FC/in.FC
examples/reaxff/FeOH3/in.FeOH3
examples/reaxff/HNS/in.reaxc.hns
examples/reaxff/RDX/in.RDX
examples/reaxff/VOH/in.VOH
examples/reaxff/water/in.water.acks2
examples/reaxff/water/in.water.acks2.field
examples/reaxff/water/in.water.qeq
examples/reaxff/water/in.water.qeq.field
examples/reaxff/ZnOH2/in.ZnOH2
examples/SPIN/read_restart/in.spin.read_data
bench/in.chain
bench/in.chain.scaled
bench/in.chute
bench/in.chute.scaled
bench/in.rhodo
bench/in.rhodo.scaled

Examples that you mentioned are pretty helpful and I followed the guidelines for an NVT simulation similar to those that you sent and it still gives errors.
I optimized their geometry in MS with cvff force field and fed the file to msi2lmp. Could you please point out the flaws and explain in what ways I can fix them?
Thanks in advance

I have given my suggestions but you keep ignoring them, so I am choosing to ignore you.

1 Like

As a general remark: you cannot provide vague information and expect precise feedback. If you want help, you need to clearly state what you did, what the error was, and why this error seems inconsistent with the current LAMMPS documentation.

Keep in mind that the people answering here are doing so in their free time, so you cannot expect them to run your script and correct the errors.

1 Like

I didn’t mean to disrespect you and I’m sorry about that.
I have actually followed your recommendations step by step and successfully resolved the problem and executed an NVT on the system. I’m processing the output right now.
But I don’t see the flaws you mentioned about the topology and I’m now even more confused since the NVT was executed without an error.

You are absolutely right, and please rest assured that I respect and appreciate both your suggestions and those of other dear contributors. While some errors may be due to my limited knowledge of LAMMPS, I do my best to work through them on my own before asking for help, unless I encounter a serious challenge in the process.
Here’s a possible revision:

Additionally, I would like to point out that when the discussion began, I was a new user of the website and did not have the ability to upload files. This made it difficult for me to share complete files and errors. However, I will do my best to adhere to the laws of the forum and provide as much relevant information as possible.