Volume of part filled cylinder (On SIDE)-VBForums

# Thread: Volume of part filled cylinder (On SIDE)

1. ## Volume of part filled cylinder (On SIDE)

How Can I Find The Area Of The Blue In the Picture

Red Line - Height of water (H)
Yellow Line - Chord

please dont overly compicate things diffrent color lines are just to helf you understand The Yellow line indicates the fill level of a cylinder on its side. How can I Calculate the volume of the water?

2. ## Forgot Picture

oOPS

3. V = 1/3*pi*h^2(3r-h)

4. I Made This Function with the formula u gave me and it returns 0

Private Const PI As Long = 3.14
Private Function GetAreaCovered(Height As Long, Radius As Long) As Currency
Dim Tmp As Currency

Tmp = (1 / 3) * PI * Height ^ 2 * (3 * Radius) * Height
End Function

5. are you after the area or the volume?
you forgot to return the value and its not the same function either

6. are you after the area or the volume?
you forgot to return the value and its not the same function either

7. I want the volume of the water inside the cylinder. is this how i would do it?
VB Code:
`Private Const PI As Long = 3.14Private Function GetVolume(Height As Long, Length as Long,Radius As Long) As CurrencyDim Tmp As Currency Tmp = (1 / 3) * PI * Height ^ 2 * (3 * Radius) * HeightGetVolume = Tmp * LengthEnd Function`

#### Posting Permissions

• You may not post new threads
• You may not post replies
• You may not post attachments
• You may not edit your posts
•

Featured