 Hello, this is Hans van der Kwas senior lecturer at IHGDALFT Institute for Water Education. In this video I am going to demonstrate how the flow accumulation functions of PC Raster work. We will use the tools that are included in the PC Raster QDS resource sharing plugin repository. Installation is explained in another video. The first tool that we will look at is the AccuFlux tool. All these tools they come with documentation, if you click the link it will open the page where the tool is explained. And for this tool we need the LDD map and a map with materials. Both are rusters. LDD is the local drain direction map which has the flow direction in the PC Raster format. And here we get some more information about how these accumulation functions work. Basically they route the materials over the local drain direction map and it adds up the materials from the upstream cells in the cell that we consider. Let's apply it. We have a local drain direction map and we have a rainfall map which for each pixel the amount of precipitation in millimeters. This is annual precipitation in this case. And with this we can calculate the discharge by accumulating the values. It's a very simple model because there are no losses assumed, there is no evaporation. So it's not very realistic. We set the projection and add some styling. Let's use blues. And here we see accumulated rainfall and rivers come out. And the units are in millimeters total discharge per year. So if you need it in cubic meters per second you need to do conversion. You can do it with the map algebra in the Raster calculator. Now here I have a map with nitrogen load. And each pixel has the amount of nitrogen in kilograms. And I'm going to also accumulate this in the catchment using the same way. And here we get the accumulated amount of nitrogen kilogram per year. Here are some boundary effects. To make this a bit more realistic we're going to try a few other ACU tools that are available. The first one is the ACU fraction flux and ACU fraction state. And if we click the link then we find the documentation and there it gives an explanation that you can define a transport fraction. So only a certain fraction is moved out of the cell during the accumulation. So here in this example you see what happens if it's a constant of 0.5 and we see that the material of 6 half of it will remain in the cell and half of it will move downstream to the next cell and adds up to the material that's there etc etc. So in this way we can remove a fraction and then we can have the output of the flux and of the state. So the state is the remainder in the cell. Let's apply this. Use the local drain direction map and then the pollution of nitrogen and then the transport fraction which is this layer which is a value between 0 and 1 of the fraction that is removed and then I run it and it produces the flux and the state map. This is the flux. You see it's different than what we had before with the end load. It's styled and we have the states and that's also styled and we see that there is an outlier value there. If I make it smaller we see more contrast. So now we know when we apply a transport fraction that a part will move to the next cell and that is what we find in the flux layer and part will remain and that's what we find in the state layer. Sometimes however you don't want a fraction to be removed but you want it only to be removed when it exceeds a certain threshold. Then use the accoutreshold flux and accoutreshold state tools. Let's have a look at the documentation and here you see that it has the same form as the others but we need to give the threshold value and transport will only occur if a certain threshold of losses has been reached and material less than the threshold will be stored and the rest will be moved to the next cell. Let's try it but we need to define this threshold layer and I'm going to make a new layer with the spatial tool and I define there a constant threshold of 10 to save it as a scalar and I can use the LDD as a mask or any of the other layers as a matter. I'm going to call that threshold. So only if there's 10 units exceeded we start to move the materials. So let's go to the accoutreshold flux tool and after defining all the inputs we can run it and check the results and here we see the result. There are some other accoutools that work in a similar way. This is the accoutravel time flux and there you need to give a velocity as an input and then it can use that velocity to determine when the material moves downstream. That would use the travel time and you can also combine that with a fraction and there's also a possibility to use the accoutrigger flux where it will only start flowing downstream when a certain trigger value has been reached. So in this video you've seen several options to route materials over the drainage direction.