Using `awk`, taking values from shell variables:
awk -v n="$worker_machine" -v m="$executors_per_node" \
'BEGIN { printf("%d\
", 0.93 * (n / m - 1)) }' /dev/null
The `awk` script doesn't get any input as usual, so we use `/dev/null` as input file and do our calculation and output in a `BEGIN` block.
Using `bc`:
sum=$( printf '0.93 * (%d / %d - 1)\
' "$worker_machine" "$executors_per_node" | bc )
printf '%.0f\
' "$sum"
Using `dc`:
sum=$( printf '%d\
%d\
/\
1\
-\
0.93\
*\
p\
' "$worker_machine" "$executors_per_node" | dc )
printf '%.0f\
' "$sum"