The damage formula shown below has been self tested by me. The defense formula has been fetched from in-game files and it matches with in-game data (if you apply the defense formula then highlight Defense on your profile, you'll find the same value). The boss defense values at end of this section are from Eden~♡#2724 on Discord (translator) and the original owner of the table from KR (for providing the values)
Here are my calculation steps:
While calculating AB damage dealt values I use "BD start" as a fixed
value and change AB starting from "AB start" with increments of "AB step
value" until I reach total of values provided in "number of steps".
Then when calculating BD damage dealt I use "AB start" as a fixed value
and change BD starting from "BD start" with increments of "BD step
value" until I reach total of values provided in "number of steps".