-
Trying to calculate actual current form the power and voltage values on a Sanxing SX631 using Special Commands. The problem is that voltage is given in V (volts) and power is given in kW (kilowatts) so unit conversion by 1000 is needed to obtain current in A (ampers). This doesn't work with Special Commands. The formula we all learned in middle school physics class is W = V x A so we can get A = W / V. In this specific case we would either need A = kW * 1000 / V or A = kW / V / 1000. Translated to SML, this would look like below:
These are 231.5 V and 2.147 kW respectively. Result is 0.009 A while it should be 9,274 A. Output version1: Output version2: Output version3: Output version4: What am I doing wrong? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
i just checked the math function and it mostly works as expected. BUT |
Beta Was this translation helpful? Give feedback.
i just checked the math function and it mostly works as expected. BUT
indeed the scaling factor is not used here
and immediate numbers in this math option must be positive integers and LOWER then max decode lines
both fixed in my fork (please test)