Simply, Sequential Workflow should be used if you have a series of straight steps , that mean you can't achieve the next step until the previous step has already finished and this depends on your business requirement.
Bussiness example for Sequential workflow : (vacation workflow)
let's consider the company business requirement for vacation system consists of three sequential steps
- request a vacation to your direct manager.
- the direct manager will receive your vacation request then decide to approve or reject if he rejects the workflow will be ended if accept your request will send to your department manager to get the final decision.
- the department manager will receive your request only if it has been approved by direct manager and if he accepts so the vacation request approved and workflow will be finished else the workflow will be finished with respect status
As you can see it depends on your business requirement where the workflow steps executed in sequence and the next step can't start until the previous step finished.
Regarding State Machine Workflow represents a set of states , it is suitable for complex processes that mean you can run a set of state in parallel or random where the next step may not depend on the previous step to complete and also you can mix parallel steps with sequential steps based on your business requirement.
Bussiness example for state machine workflow : (the participants in an HR workflow)
you might move an employment resume from state to state. The resume might be in a state of being considered, interviewing, or archiving for future.
The resume might be re-activated or updated at any time. Because there is no linear path of steps for the resume, it would be excessively hard to produce conditional rules to capture all possible paths.
In these situations, you would want to manage your workflow as a series of states and transitions. Use the state machine workflow template to get started there.”
Hope it helps you