Stepper Motor Dir/Step help program.

Anyway my big question is how can i program the arduino so that i can control both the motor relatively

You need to step each motor one step at a time. You need to figure put which one needs to step the most times to get the pair where you want. Say that one needs to step 10 times while the other needs to step 8. In a loop, you step one motor 1.0 step and the other motor 0.8 steps. Notice that the values are NOT ints. You keep track of the position that the (slower) motor should be at (0, 0.8, 1.6, 2.4, etc.). Each time the position becomes greater than 1, step and decrement the value by 1.

So, the positions become 0.0, 0.8, 1.6 -> 0.6, 1.4 -> 0.4, 1.2 -> 0.2, 1.0 -> 0.0, 0.8, 1.6 -> 0.6, etc.

Each place where the -> is shown, you step and decrement. Meanwhile, the other motor steps every time.

The result will be a stair step arrangement, rather than a slope. How that impacts your process depends on how many steps are needed to move your whatever, and how precise that movement needs to be. For metal cutting CNC machines, they are usually geared, so moving the head 1.0" in one direction requires hundreds of steps. The difference between 1048 steps and 1048.5 is not going to make much difference.