fix to ^ function