Problem with calculation formulas


I created on my application a popup to insert new payment. In this popup, there are 3 inputs.

  1. the quantity of missions done
  2. the remuneration per mission for the company (me)
  3. the remuneration per mission for my client (USER)

I try, for 3 hours now, to multiply the 1st and 2nd input => P1 and 1st and 3rd => P2 for having the global remuneration for the client, and me.
After, and I have a problem now, I try to calcul my commission so I do it :

P1 - P2. That’s not working. The result isn’t good. I try to fix it, but impossible to understand the error. ChatGPT too doesn’t fix it. When I inspect the formula, I have the correct values calculated but I have the impression the “-” isn’t used as well.

Anyone to help me ?

Thanks a lot !

try using math.js plugin for calculations, bubble doesnt handle stuff like this properly
math.js alows you to use parentheses and symbols ex: ((input1value)*(input2value)+29)*4

Try using this for complex formulas or just math

Try enabling the parentheses feature first to see if that solves your problem.

Don’t do this unless you have a very specific need… (or need exponents) just enable parentheses in version as @hergin says