Taken some classes from BDSup2Sub