A method for determining a trajectory for a host vehicle H in order to as smoothly as possible avoid or mitigate a collision in a road environment including the host vehicle H and external objects, using an arrangement comprising processing means and at least one of a sensor system or a communication system, wherein the trajectory is constituted of n spline segments of degree d, and the n spline segments are divided by spline breakpoints, wherein a safety distance is preselected between any external objects and the host vehicle H when selecting the trajectory, and wherein the method includes the steps of - identifying the positions of one or more external objects in relation to the host vehicle H within a predefined distance using at least one of the sensor or communication systems (2, 3), - generating a plurality of trajectories that are valid for enabling the host vehicle H to pass any desired number of external objects using the processing means, - removing any trajectories intersecting with any other of the external objects using the processing means, and - estimating lateral position, lateral velocity, lateral acceleration and the lateral jerk that will act on the host vehicle H driving along any one of the trajectories, using the processing means, the method being characterized in that it further comprises: - selecting the trajectory for which the lateral jerk acting on the host vehicle H is minimized, using the processing means, the selected trajectory forming a tangent to a first point located at a preselected safety distance from a first external object, wherein the safety distance is selected dependent on a traffic situation, the external objects and the host vehicle H, wherein the spline breakpoints are selected independently from the positions of the external objects by the processing means, and the selection is based on the estimated amount of lateral jerk that would act on the host vehicle H if driven along any one of the trajectories. - identifying the positions of one or more external objects in relation to the host vehicle H within a predefined distance using at least one of the sensor or communication systems (2, 3), - generating a plurality of trajectories that are valid for enabling the host vehicle H to pass any desired number of external objects using the processing means, - removing any trajectories intersecting with any other of the external objects using the processing means, and - estimating lateral position, lateral velocity, lateral acceleration and the lateral jerk that will act on the host vehicle H driving along any one of the trajectories, using the processing means, the method being characterized in that it further comprises: - selecting the trajectory for which the lateral jerk acting on the host vehicle H is minimized, using the processing means, the selected trajectory forming a tangent to a first point located at a preselected safety distance from a first external object, wherein the safety distance is selected dependent on a traffic situation, the external objects and the host vehicle H, wherein the spline breakpoints are selected independently from the positions of the external objects by the processing means, and the selection is based on the estimated amount of lateral jerk that would act on the host vehicle H if driven along any one of the trajectories. - selecting the trajectory for which the lateral jerk acting on the host vehicle H is minimized, using the processing means, the selected trajectory forming a tangent to a first point located at a preselected safety distance from a first external object, wherein the safety distance is selected dependent on a traffic situation, the external objects and the host vehicle H, wherein the spline breakpoints are selected independently from the positions of the external objects by the processing means, and the selection is based on the estimated amount of lateral jerk that would act on the host vehicle H if driven along any one of the trajectories.