- AdvectionDiffusion.set_rate_BC(pores, rates=None, total_rate=None, mode='merge', **kwargs)¶
Apply constant rate boundary conditons to the specified locations.
pores (array_like) – The pore indices where the condition should be applied
rates (float or array_like, optional) – The rates to apply in each pore. If a scalar is supplied that rate is assigned to all locations, and if a vector is supplied it must be the same size as the indices given in
total_rate (float, optional) – The total rate supplied to all pores. The rate supplied by this argument is divided evenly among all pores. A scalar must be supplied! Total_rate cannot be specified if rate is specified.
mode (str, optional) –
Controls how the boundary conditions are applied. The default value is ‘merge’. Options are:
Adds supplied boundary conditions to already existing conditions, and also overwrites any existing values. If BCs of the complementary type already exist in the given locations, those values are kept.
Deletes all boundary conditions of the given type then adds the specified new ones (unless locations already have BCs of the other type)
The definition of
quantityis specified in the algorithm’s
alg.settings['quantity'] = 'pore.pressure'.