Hello  Pshemak!
"if" structures are not hard, at least if you have some experience e.g. with 
Javascript.
But for your problem you don't need that; the "connect" command will set the 
bond type based on distance, very easily, for all frames at a time.

> Let's say I have some "boundary" conditions (in angstroms, totally arbitrary 
> for the purpose of this 
> example):
>     C-O 1.44 and less is "single", more than 1.44 but less than 1.55 is 
> partial, 
>     and more than 1.55 is no bond
>     C-Br 1.92 and less is single, more than 1.92 but less than 2.07 is 
> partial and 
>     more than 2.07 is no bond

select all;
connect (_C) (_O) delete;
connect 1.441 1.55 (_C) (_O) partial;
connect 1.44 (_C) (_O) single;

connect (_C) (_Br) delete;
connect 1.921 2.07 (_C) (_Br) partial;
connect 1.92 (_C) (_Br) single;
 
I am not sure about wether the given limits will be taken as "less than" or 
"less or equal than".


------------------------------------------------------------------------------
_______________________________________________
Jmol-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jmol-users

Reply via email to