I have been using fix-gcmc for a while to perform MC moves during a simulation which I would like to carry out on a variety of molecules. But, as the latest documentation lays out “When using fix gcmc in combination with fix shake or fix rigid, only GCMC exchange moves are supported, so the argument M must be zero.”
My question is rather general as to the reason why performing MC moves are absent, as of now, in LAMMPS for rigid molecules. And, if I want to get into the cpp files and look to modify some lines of code to put in the ability to have MC move options, where should I ideally look to implement the same? Any amount of help would be highly appreciated.
There are no MC moves for rigid molecules in fix gcmc because that cannot be easily done inside that fix.
For example the rigid fixes maintain per rigid object data about position, orientation, moments of inertia, velocities etc. and update those during time integration.
any change to atom positions outside of that will not update those data structures and thus futile. For insertion/deletion special functions had to be added to communicate the operation to the affected fixes so that they update their corresponding internal data structure. You would have to do the same if you want to do MC moves. This would be more complex than insertion/deletion, so it would require a good understanding of the LAMMPS MD code. For that reason, it is not possible to point you to a specific section of the fix gcmc code where you would need to make changes. You would have to properly read and understand both the entire code of fix gcmc and the affected fixes and whatever else is required and only then can you consider making changes.
Mind you, fix gcmc is very complex and convoluted as it is, so any changes are likely to introduce bugs in other functionality, so great care would be required to implement this.
Depending on the use case, it may also be worth considering to implement this feature not in fix gcmc but in e.g. the affected rigid fix.