Hi, I am currently working on a personal project, everything is going very well. I use a water meter that outputs a pulse each 250ml, has really good precision, 2% error.
I wanted to implement a way to be able to close a valve in case the water pipe broke, I know that said situation would probably mean a high water flow in a short amount of time.
I can send my data to a Firebase database each hour.
So based on this information, how can I use some statistics with my stored data to tell if the flow could mean a broken water pipe? I am currently not calculating water flow, so I am open to suggestions.
The flow characteristics will change. You will never observe a zero, and the average flow MAY change, but unless you know more about the end use you could not really test for that. However the outflow from a broken pipe will be smooth, while the demand from your end use would I suppose change; so you could do the stats to look for zeros, and also check the kurtosis.
typical flow
toilet flush possible 2 water volumes and possible multiple flushes.
hand washing
clothes machine
dish washer
refrigerator water dispensor
freezer ice maker
shower
water the garden
wash the car
in all cases, there is a start, a flow, a stop.
at the end of each stop, there should be no flow.
possible water use conditions:
wake up, turn on the shower to let it warm up, take shower.
pour water for coffee
how can you determine what is a leak or what is desired use ?
you could have an 'away' setting.
a button that turns off the main valve to the whole house.
I can see adding a button next to the hose. maybe a menu. allow 50 liters, then shut off. put the hose in the garden.. press the button
not much help, but it does seem the water leak sensor seems to be the most valuable answer so far.
Look at what's available to solve this - you can get water cutoff valves already - how do they work?
The simplest thing would simply be to decide that continuous flow for some time period indicates a leak. Perhaps you should be looking for a high rate for whatever that period is.
I read about a fancier system yesterday that learns your pattern of usage and if something unusual happens (why are you showering at 4am?) it texts you to ask if everything is ok. If you don't respond, it turns the water off.
jerrymedi:
Hi, I am currently working on a personal project, everything is going very well. I use a water meter that outputs a pulse each 250ml, has really good precision, 2% error.
I wanted to implement a way to be able to close a valve in case the water pipe broke, I know that said situation would probably mean a high water flow in a short amount of time.
I can send my data to a Firebase database each hour.
So based on this information, how can I use some statistics with my stored data to tell if the flow could mean a broken water pipe? I am currently not calculating water flow, so I am open to suggestions.
Consider where the water comes from. Does the actual source EVER stop the water for repairs? Does the water ever stop flowing when the electricity stops? Does you meter stop reporting when the electricity goes away? Will you have backup power for your Arduino system?
Also, is the water pressure at the source ever change?
Paul
Thanks, guys for all the replies. To put more information:
I don't know when the water will be cut off, the device will be a household water meter, so it's different per house. I have a schedule based on "X liters per X amount of days" already. I can store a lot of sample data, each hour I could store the total liters used and highest flow recorded? I also believe that "acceleration" could be useful, for example, how much does the water flow increments in a matter of "X" seconds, a broken pipe should be like a spike compared to normal water usage.
So my device would be sitting in a stranger's house, no way to know beforehand his water usage. My device should also be able to run in batteries for 3 years at least, but that's on my to-do list because I need an electric engineer to help me with that
So here is my list of possible useful info:
Max flow per water pipe diamater. (Considering my device has a 1/2 inch on each end).
How much can the water flow increment in a short period of time?
Average water flow.
The hour, day, and maybe a month where the data is acquired. (As some said, why are you showering at 3: am).
Ability to let the user know if there is an alert, and have him tell the app if it is right or not.
So I believe that in order for this to work, somehow I need to detect that the current water flow is too high, maybe using point 1 and 2, then send it to Firebase and have it do some math, return an indicator, like a percentage, and decide if it is too high, alert the user. If the user says its all fine, then increment the limit for the alerts.
So, your device may be setting in a rental house and not know when a tenant left and the house was vacant and a month later a different tenant moved in. Your device may be in a house that is vacant for 3 weeks while the tenants are on vacation. Zero water usage. They return and you alarm when they begin using water again.
The elderly parents move into the house to live with one of their children. The water usage goes way up and you alarm for broken pipe.
Paul
Paul_KD7HB:
So, your device may be setting in a rental house and not know when a tenant left and the house was vacant and a month later a different tenant moved in. Your device may be in a house that is vacant for 3 weeks while the tenants are on vacation. Zero water usage. They return and you alarm when they begin using water again.
The elderly parents move into the house to live with one of their children. The water usage goes way up and you alarm for broken pipe.
Paul
Well, I guess that's how statistics work? That's why I could set a timer for the alert so the user can tell if it is right or not.. Then the more time they spend on the house, the better data I get. Or I could tell the owners if they feel the alarms are firing too much, then check if there was a long period of time and mark it as "empty house", so It doesn't make it into the equation.
Hi,
I think the OP can better describe what he is trying to do.
I think he is trying to detect a water leak on a property, not in a pipe but in a network of pipes in a home or flat or unit by monitoring the inflow at the property boundary.
He wants to monitor A SINGLE PIPE to detect a leak in the others it supplies.
What does he/she quantify as a "leak"?
A dripping tap, a dripping elbow joint under the floor? (Basically both the same flow).
A running tap to fill a sink or bath or running a shower, a broken pipe with water FLOWING? (Both basically the same thing.)
More than one tap on at a time.
So many valid supply and leaking combinations.
To do a proper leak-test, like a plumber does is, turns ALL outlets off , pressurizes the system and monitors if the pressure drops.
Unless late at night if you can guarantee that ALL the water outlets are closed, close the master valve to the property and measure the property water pressure for a predetermined time, this would be, in my opinion, the only reliable method.
TomGeorge:
Hi,
I think the OP can better describe what he is trying to do.
I think he is trying to detect a water leak on a property, not in a pipe but in a network of pipes in a home or flat or unit by monitoring the inflow at the property boundary.
He wants to monitor A SINGLE PIPE to detect a leak in the others it supplies.
What does he/she quantify as a "leak"?
A dripping tap, a dripping elbow joint under the floor? (Basically both the same flow).
A running tap to fill a sink or bath or running a shower, a broken pipe with water FLOWING? (Both basically the same thing.)
More than one tap on at a time.
So many valid supply and leaking combinations.
To do a proper leak-test, like a plumber does is, turns ALL outlets off , pressurizes the system and monitors if the pressure drops.
Unless late at night if you can guarantee that ALL the water outlets are closed, close the master valve to the property and measure the property water pressure for a predetermined time, this would be, in my opinion, the only reliable method.
Tom...
Sounds like the way to go is running healt checks each night, or during no water usage periods. So this could be a good service instead of trying to tell if the mother pipe broke or not
I think there will be hell to pay when a pipe really does break and the OP is not able to immediately report it!
For instance when a pipe freezes and breaks and there is no indication to the home owner.
Paul