The probability that you roll 4+ is the probability that you roll a 4, a 5, or a 6. Each of these events has probability $\frac{1}{6}$; so, the probability of rolling 4+ is $\frac{3}{6}=\frac{1}{2}$.
For your other scenario, note that the event that you get a 5+ when you are allowed on re-roll can be broken up in to two disjoint events: event $A$, in which you roll a 5+ on the first try; and event $B$, in which you roll a number 1-4 on your first attempt, and either a 5 or 6 on the second.
Then $P(A)=\frac{2}{6}=\frac{1}{3}$, since this is the event that you roll either a 5 or a 6. For $B$, we have
$$
P(B)=\frac{4}{6}\cdot\frac{2}{6}=\frac{2}{9},
$$
since you must roll a 1, 2, 3, or 4 on the first attempt and either a 5 or 6 on the second. So, overall, the probability of getting 5+ when you allow one re-roll is
$$
P(A\text{ or }B)=P(A)+P(B)=\frac{1}{3}+\frac{2}{9}=\frac{5}{9}.
$$
(Note that we have used here that $A$ and $B$ are disjoint possibilities.)
So, you are more likely to get a 5+ with a re-roll allowed than to get a 4+ with no re-roll.
The probability of rolling any given side of a six sided die is equal, so the probability of rolling any of certain collection of numbers, e.g. $\{1,2,3,4\}$ is just the size of the collection over 6, here $4/6 = 2/3$. In your case it seems like you want to feed in a finite sequence of $N$ numbers between 1 and 6 and want to know the probability that if you roll $N$ die that the $j$the roll is $\leq$ the $j$th element of your sequence precisely $b$ times. Since the probability of rolling any given sequence is equal, really we just want to count how many ways this can happen and they will divide by the total number of possible dice roll outcome, which is just $6^N$.
Some notation: call the sequence of upper bounds $X$ and the sequence of dice rolls $D$, so these are both sequences of length $N$ and we are looking to count the number of $D \in \{1,...,6\}^N$ s.t. $D_j \leq X_j$ precisely $b$ times.
This is perhaps hard to immediately count, but it we fix any size $b$ subset $S$ of $\{1,...,N\}$, we can count the number of ways that $D_j \leq X_j \iff j \in S$. Then we just sum over all these $S$.
For some fixed such $S$, we see that $D_j \leq X_j \iff j \in S$ iff for $j \in S$, $D_j \in \{1,...,X_j\}$ and for $j \not \in S$, $D_j \in \{X_j+1,...,6\}$. Thus there are $\left(\prod_{j\in S} X_j\right) \left(\prod_{j \in S^C} (6-X_j)\right)$ different $D$ such that $D_j \leq X_j \iff j \in S$.
Therefore the total number of ways to satisfy your property is $\sum_{S \subseteq \{1,...,N\}, |S| = b} \left(\prod_{j\in S} X_j\right) \left(\prod_{j \in S^C} (6-X_j)\right).$ The probability is then that quantity over $6^N$. This can be easily computed with code.
Edit: Here's Python code.
import itertools
#number of die rolled
N=5
#your number b
b=2
#your vector of upper bounds
X=[1,1,1,1,1]
number_of_ways = 0
#make a list of integers 0,...,N-1
base_set =[]
for i in range(N):
base_set.append(i)
#some error checking
if len(X) != N:
print("Make your X vector the right length")
if not (0 <= b <= N):
print("b not in correct range")
#iterate throough the subsets of {0,...,N-1} of size b and add up the number of ways as I describe
for S in list(itertools.combinations(base_set,b)):
temp = 1
for i in range(N):
if i in S:
temp = temp*X[i]
else:
temp = temp*(6-X[i])
number_of_ways+= temp
#normalized by the total number of ways
probability = number_of_ways/6**N
print(probability)
Best Answer
I will handle the case where the die of the high infantry gets an increase of 2. The same approach can then be used to determine the probabilities when adding any other number.
If the light infantry throws a 1 or 2, then the high infantry always wins. If the light infantry throws a 3, the probability of a victory for the high infantry equals $\frac{5}{6}$ (throw higher than 1). Throwing a 4, we find a probability of $\frac{1}{6}$ for a tie (throw 2) and $\frac{4}{6}$ for a victory (throw higher than 2). Applying the same to rolls of 5 and 6, and we find, for the events $V$ (high infantry wins), $T$ (a tie) and $L$ (high infantry loses):
$$P(V) = \frac{1}{6} \left( 1 + 1 + \frac{5}{6} + \frac{4}{6} + \frac{3}{6} + \frac{2}{6} \right) = \frac{26}{36} = \frac{13}{18}$$
$$P(T) = \frac{1}{6} \left( 0 + 0 + \frac{1}{6} + \frac{1}{6} + \frac{1}{6} + \frac{1}{6} \right) = \frac{4}{36} = \frac{1}{9}$$
$$P(L) = 1 - P(V) - P(T) = \frac{6}{36} = \frac{1}{6}$$