How many unlabelled groups of 10 people can be formed?
There is a group of 500 people , each are from 6 different country and with 3 different profession. How many groups of 10 people can be formed with below condition. 1) no individual should belong to more than one group. 2)every group should have at least one person from every country. 3)every group should have at least 2 people from each profession.
See also questions close to this topic

If (n+2C5) = 12(nC3), what is n?
If (n+2C5) = 12(nC3), find n.
I have tried taking the long way of breaking down what (n+2C5) and 12(nC3) are. However, it has led me to a weird algebraic line where n was multiple powered
The tip is to use the property: (nCk) = n/k(n−1Ck−1)

How to nicely plot a permutation matrix
I have a string of letters:
x < c("a","o","s","d", "#")
(# meaning beginning or end)
and a vector of english words:
engl < c("#so#", "#sad#", "#do#", "#as#", "#Dads#", "#do#")
we can creat a matrix of all possible combinations of the letters in
x
like this:df < as.data.frame(outer(x, x, FUN = paste0)) dimnames(df) < list(x, x)
df:
aa ao as ad a# oa oo os od o# sa so ss sd s# da do ds dd d#
#a#o #s #d ##
Lets assume I want to know how often each of these combinations occurs in english by searching vector engl and filling the dataframe df with the distribution, answering the question column or rowwise "what is the percentage of the distribution of d":
So in the case given here, we would have
0 0 1 2 0 0 0 0 0 2 1 0 0 0 3 1 2 1 0 1 2 0 1 3 0
How can I go about this, as str_count doesn't work with matrixes?
In a next step I would want to display the matrix in a heatmaplike fashion,

What is the total count of digits from 1 to N such that number of odd digits in the number is even and no of even digits are odd?
I want to count the numbers which follows above. e.g. from 1 to 10 there are four such nos. which are 2,4,6,8.

Count rows in variable range in Excel
I have established, in Excel VBA, a range biased off of the location of two values in a data set. The row numbers of the start and stop in the range will change with data entry so I needed to create a range that will always offset from a set area. I now need to count the number of rows/values in the range so that once I copy the data in the range I can then remove the duplicates without altering the original list. How can I count the number of rows in my range?
I have attempted to use
copyrange.Rows.Count
but got error 438Sub count_ID_List() Set botrow = Cells.Find("Stud ID") 'Finds the first row of the count section of the invitory' Set toprow = Cells.Find("Stud Part Number") 'Finds the top row of the company invintory' Set copyrange = Range(toprow.Offset(1, 0).Address, botrow.Offset(12, 1).Address) Set copyto = Range(botrow.Offset(1, 0), botrow.Offset(1, 0)) copyrange.Copy (copyto) 'this is where i would like to then remove duplicates from the newly copied data' End Sub

python, measure unique elements by row ignoring specific values
I have a data frame of 6 columns where each entry has a sequence of numbers.
pd.DataFrame(FixByteOrderUnique) Out[518]: 0 1 2 3 4 5 0 58 68 58 59 1 1 1 59 69 59 58 1 1 2 93 94 93 33 1 1 3 58 59 58 68 1 1 4 92 94 92 33 1 1 5 59 58 59 69 1 1 6 57 48 57 79 1 1 7 15 26 15 101 1 1
I want per line to measure the number of unique elements ignoring in the count the numbers: 1,100,101 and 102. Valid numbers are from [0,99].
What I did was to make a lambda function that ignores in the counting the 1
def myfunc(row): if 1 in row.values: return row.nunique()  1 else: return row.nunique()
and then call my function like this
pd_sequences['unique'] = pd.DataFrame(FixByteOrderUnique).apply(myfunc, axis=1)
How I can include inside my lambda function to check if the number is from [0,99] to be eligible for the uniqueness counting?
Thanks a lot Regards Alex

Python OpenCV caffemodel object detection and counting by using caffemodel when they crossing a rectangle area or an area of interest
I used code from pyimagesearch for object counting and detection when they cross horizontal line as people move up and down in video. I want to detect people and count them when they come from any direction. I want them detected in an area of interest for example detect them when they are inside a rectangle. How can I do this? Here is the URL of the example I am using:
https://www.pyimagesearch.com/2018/08/13/opencvpeoplecounter/

Computational Theory
I am very new to the computational theory, and I was just trying to figure about one question. Is the following statement true? L(M) = L(M1) ∩ L(M2), where M1 and M2 are DFAs.
I was thinking about the case when L(M1) = {} and L(M2) ≠ {}. I got that L(M) = L(M1) ∩ L(M2) = {}. However, I am not sure if L(M) can accept both L(M1) and L(M2). I remember something about that every language contains an empty set.

PowerBI  Referencing a previous/next row to calculate derivitaves (calculus)
I am trying to create a column that applies numerical differentiation and integration on another column but do not know how to reference a previous row.
My example data has columns: x  y  y'
A formula for differentiation is :
y' = y(x+h)y(xh) / 2h
In excel, this is really easy.
C3 = (B4B2)/2*(A3A2)
Here is an example of this code being executed in Excel:
Image The equation for y: y = 0.1*x^3 + x^2
However, in PowerBI i have no idea how to actually call a previous or next row's value.
I merely wish to calculate the y' column that formula.