22import static org.junit.jupiter.api.Assertions.assertFalse;
23import static org.junit.jupiter.api.Assertions.assertTrue;
25import javax.vecmath.Point3d;
27import org.junit.jupiter.api.Test;
28import org.openscience.cdk.Atom;
29import org.openscience.cdk.interfaces.IBond;
30import org.openscience.cdk.silent.Bond;
32import denoptim.exception.DENOPTIMException;
48 for (
int i=0; i<size; i++)
50 Atom a =
new Atom(
"C",
new Point3d());
52 for (
int j=0; j<i; j++)
71 inspector.reportTimeoutIncidents =
false;
75 inspector.reportTimeoutIncidents =
false;
85 Atom c1 =
new Atom(
"C",
new Point3d(1,1,1));
86 Atom c2 =
new Atom(
"C",
new Point3d(2,2,2));
87 Atom o =
new Atom(
"O",
new Point3d(3,3,3));
91 v.
addBond(
new Bond(c1,c2,IBond.Order.SINGLE));
92 v.
addBond(
new Bond(c2,o,IBond.Order.DOUBLE));
106 v2.
getAtom(0).setPoint3d(
new Point3d(6,6,6));
126 v2.
getAtom(0).getBond(v2.
getAtom(1)).setOrder(IBond.Order.TRIPLE);
static APClass make(String ruleAndSubclass)
Creates an APClass if it does not exist already, or returns the reference to the existing instance.
void setAPClass(String apClass)
Set the Attachment Point class.
void setDirectionVector(Point3d dirVec)
Sets the end of the 3D vector defining the direction of the AP in 3D.
Class representing a continuously connected portion of chemical object holding attachment points.
IBond removeBond(int position)
void addAP(int atomPositionNumber)
Adds an attachment point with a dummy APClass.
AttachmentPoint addAPOnAtom(IAtom srcAtm, APClass apc, Point3d vector)
Add an attachment point to the specifies atom.
Fragment clone()
Returns a deep copy of this fragments.
IAtom getAtom(int number)
void removeAP(AttachmentPoint ap)
boolean isomorphismExists()
Checks if an isomorphism exists between the two fragments.
Unit test for isomorphism inspector.
void testIsomorphismExists()
static Fragment makePathologicalFragment(int size)
AttachmentPoint getAP(int i)
Get attachment point i on this vertex.