Hello all!
I am currently trying to build a polyimide system that contains imide functional groups using the PCFF force field:
RN(C(=O)R’)(C(=O)R’')
and based on going through the force field typing rules I am pretty sure that the nitrogen here should be the atom type n (generic sp2 nitrogen (in amides)). Currently I’m just trying to build a single monomer unit as a test. When building these systems, the N is classified erroneously as either na (sp3 nitrogen in amines) or as n_2 (nitrogen in carbamate).
I have attempted to add a new rule for classifying it to pcff_templates.dat in the following manner:
type: n
! nitrogen in imide group (added by SJL)
template: (>N(-C(=O))(-C(=O))(-))*
atom_test: 1
hybridization: SP3
aromaticity: NON_AROMATIC
end_test
atom_test: 2
hybridization: SP2
end_test
atom_test: 4
hybridization: SP2
end_test
atom_test: 6
allowed_elements: C, H
end_test
end_type
But based on the output of the build process, it seems like it does not even go through the test when trying to classify it:
**
core/field/apply/rules.c:353 [seg1] site = 4, connect = 0
core/field/apply/rules.c:88 [3] N {0, 4} {-1, -1} 0 -2 -1 0
core/field/apply/rules.c:88 [2] C {0, 3} {0, 4} 0 0 -1 0
core/field/apply/rules.c:88 [1] C {0, 2} {0, 3} 1 1 -1 0
core/field/apply/rules.c:57 [0] C {0, 1} {0, 2} 1 1 -1 0
core/field/apply/rules.c:57 [0] C {0, 7} {0, 2} 1 -2 -1 0
core/field/apply/rules.c:88 [1] O {0, 6} {0, 3} 0 -2 -1 0
core/field/apply/rules.c:88 [2] C {0, 0} {0, 4} 0 0 -1 0
core/field/apply/rules.c:88 [1] O {0, 67} {0, 0} 0 -2 -1 0
core/field/apply/rules.c:88 [1] C {0, 1} {0, 0} 1 1 -1 0
core/field/apply/rules.c:57 [0] C {0, 2} {0, 1} 1 1 -1 0
core/field/apply/rules.c:57 [0] C {0, 12} {0, 1} 1 -2 -1 0
core/field/apply/rules.c:88 [2] H {0, 5} {0, 4} 0 -2 -1 0
core/field/apply/rules.c:364 depth = 3
seg1:4 ^5N(^5C(^6c(:^6c)(:^6c))(=O))(^5C(^6c(:^6c)(:^6c))(=O))(H)
core/field/apply/rules.c:212 [na, n4]
Debug: core/field/rule.c:446 -1 na 0 N()()()
Debug: core/field/rule.c:446 -1 n3m 0 ^3N()()()
Debug: core/field/rule.c:446 -1 n4m 0 ^4N()()()
Debug: core/field/rule.c:446 -1 n4m 0 ^4N()()()
Debug: core/field/rule.c:446 -1 n_2 0 N(~[C|H])(C(=O))(H)
core/field/apply/rules.c:215 match =
{type → 121, comment → “nitrogen in carbamate”, element → “N”, test → {
flag → {aromatic → exclude}},
connect → {
{element → {“C”, “H”}},
{element → “C”,
connect →
{element → “O”, test → {flag → {bond → double}}}},
{element → “H”, test → {flag → {bond → single}}}}}
core/field/apply/rules.c:378 match = 0x1461310
core/field/apply/rules.c:444 type[4] = n_2
**
I think it’s likely I just am missing something as far as the rules of writing new classifications are concerned. Is there a reason why EMC would ignore the new rule I’ve written? Based on the build.out print it seems like it is only testing the atom types na, n3m, n4m, and n_2.