OpenBioSim/sire

Add square root, power etc to units

chryswoods opened this issue · 2 comments

Add support for power, square root etc to GeneralUnit.

I've done this on the BioSimSpace side, but can rework when it's natively implemented in GeneralUnit. Feel free to look at my __pow__ implementation (which handles negative and fractional exponents too). This is based on the logic from your code snippet and code just be done directly in the sire layer.

I've added this to feature_merge2 :-)