-
I am having trouble doing a new function, I am trying to put in the formula to get the volume of a longitudinal section (based on and extended from a circle segment formula) of a cylinder. The link to the page with the calculator for this as well as the formula to do it yourself and some notes/explanations/etc is : So here is how I have entered the variables (as integer, maybe that is wrong?) : and the formula : I am using a depth of 2, a length of 20 and a radius of 5. Their calculator uses circumference instead of radius (but as you know the radius is just half of the circumference) and I used the same numbers in their calculator except for circumference of 10, to give me a check if I got my formula right. When I do the formula as above, here is the output I get from Qalculate :
If I do the formula like this : Qalculate returns :
So I thought maybe the -1 behind cos() needed to be in the () so I did the formula like this : Qalculate returns :
I am not that educated or skilled in math, but I can usually put in a formula from a webpage or something and get it right more often than not. But -175.163 723 3 is not the right answer according to the calculator on the site, the correct answer according to that is 223.6476 I want the function for some writing I am doing. They said "The result of the cos-1 function in the formula is in radians." in one of the notes. Could my calculator be set on something different and this is what is throwing the calculation off? As you can see on the calculator & formula webpage, they used Latex or something when entering the formula so they were able to do the division in ()'s as an over under. I took a best guess that ((\z−\x)/\z) might work in the formula in Qalculate the same way, maybe I messed that up? I would appreciate any assistance anyone can give me on getting the variables and formula right so that the function is accurate. And maybe an explanation of how I messed up the formula and/or the variables when I set it up. Thank you Edit : Being set to something besides radians is not the problem I don't believe, my Qalculate is set to radians. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 3 replies
-
You've replaced exponents with numbers that are not exponents (2, -1, 2). The correct expression is |
Beta Was this translation helpful? Give feedback.
You've replaced exponents with numbers that are not exponents (2, -1, 2).
The correct expression is
\y(\z^2 × arccos((\z − \x)/\z) − (\z − \x) × sqrt(2\z\x − \x^2))
(or\y(\z²cos⁻¹((\z−\x)/\z)−(\z−\x)sqrt(2\z\x−\x²)
, but use of cos⁻¹ instead of arccos or acos is not allowed when entering a function).