Guys, please look at this block formula. The block formula returns wrong result which is completely different from the manual calculation. Please see the images from app inventor and the formula.
Please download and post each of those event block(s)/procedures here ...
(sample video)
We can't load your blocks into our Blocks Editor if you use screen copy/paste on them.
Also, if you switch all blocks to external inputs their nesting becomes clearer and they fit the screen better.
I believe we could do with some more brackets in the written formula to indicate what the operators (+-x/) apply to
A reference to the original formula would also help.
You now have a gang of three making demands McCarthy
We also need sample values for all the variables (e.g. Water Percent) and what the HGS_Percent should be when calculated using those sample values.
I can not see arithmetic operators used correctly in blocks accordence to manual formul. Also need to apply operator precedence using.
I have pasted the original formula along side the block formula.
Typical value of the variables are:
Water Percent = 97
Volume of Salt = 0.03
Oil Percent = 0
Salt Water WT = 8.36
Mud Weight = 8.8
The result should be HGS Percent = 0.33
Thanks for the observation. I will re-run it and see.
Got same wrong result. I may have pasted the adjusted block formula where I took out the bracket and subsequently the subtraction sign changed to arithmetic. Please if you may, run the block formula and see if you will obtain the right result 0.33. Thanks a lot for all your assistance.
Many thanks for the reply. Please how did you arrange your block formulas vertically. Thanks a lot.
Hi Mareshu, how do I rearrange the blocks the way you did? Thanks a lot.
Right click on a block
select external inputs
Right click on blocks switch between external and inline inputs
Thanks a lot. I really appreciate.
@all, thanks a lot for the assist. I got my result. This community has been very helpful.