Code development platform for open source projects from the European Union institutions

Skip to content
Snippets Groups Projects
Commit 9fe2f0df authored by Markus Quaritsch's avatar Markus Quaritsch
Browse files

more expressive error message

parent 9c1082a9
No related branches found
No related tags found
No related merge requests found
......@@ -24,10 +24,10 @@ namespace TUGraz.VectoCore.Utils
MeterPerSquareSecond deceleration)
{
if (deceleration >= 0) {
throw new VectoException("Deceleration must be negative!");
throw new VectoException("Deceleration must be negative! a: {0}", deceleration);
}
if (v2 > v1) {
throw new VectoException("v2 must not be greater than v1");
throw new VectoException("v2 must not be greater than v1 v1: {0} v2: {1}", v1.Value(), v2.Value());
}
return ((v2 - v1) * (v1 + v2) / deceleration / 2.0).Cast<Meter>();
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment