-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathAngularJerkMagnitude.g.cs
More file actions
37 lines (32 loc) · 2.07 KB
/
AngularJerkMagnitude.g.cs
File metadata and controls
37 lines (32 loc) · 2.07 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
// Copyright (c) ktsu.dev
// All rights reserved.
// Licensed under the MIT license.
// <auto-generated />
namespace ktsu.Semantics.Quantities;
using System.Numerics;
/// <summary>
/// Magnitude (Vector0) quantity for the AngularJerk dimension.
/// </summary>
/// <typeparam name="T">The numeric storage type.</typeparam>
public record AngularJerkMagnitude<T> : PhysicalQuantity<AngularJerkMagnitude<T>, T>, IVector0<AngularJerkMagnitude<T>, T>
where T : struct, INumber<T>
{
/// <summary>Gets a quantity with value zero.</summary>
public static AngularJerkMagnitude<T> Zero => Create(T.Zero);
/// <summary>
/// Creates a new <see cref="AngularJerkMagnitude{T}"/> from a value in RadiansPerSecondCubed.
/// </summary>
/// <param name="value">The value in RadiansPerSecondCubed.</param>
/// <returns>A new <see cref="AngularJerkMagnitude{T}"/> instance.</returns>
/// <exception cref="System.ArgumentException">Thrown when the resulting magnitude would be negative.</exception>
public static AngularJerkMagnitude<T> FromRadiansPerSecondCubed(T value) => Create(Vector0Guards.EnsureNonNegative(value, nameof(value)));
/// <summary>
/// Subtracts two AngularJerkMagnitude values, returning the absolute difference as a non-negative AngularJerkMagnitude.
/// Magnitude subtraction stays a magnitude (per the unified-vector model).
/// </summary>
[System.Diagnostics.CodeAnalysis.SuppressMessage("Usage", "CA2225:Operator overloads have named alternates", Justification = "Physics quantity operator")] public static AngularJerkMagnitude<T> operator -(AngularJerkMagnitude<T> left, AngularJerkMagnitude<T> right) => Create(T.Abs(left.Quantity - right.Quantity));
/// <summary>
/// Multiplies AngularJerkMagnitude by Duration to produce AngularAccelerationMagnitude.
/// </summary>
[System.Diagnostics.CodeAnalysis.SuppressMessage("Usage", "CA2225:Operator overloads have named alternates", Justification = "Physics quantity operator")] public static AngularAccelerationMagnitude<T> operator *(AngularJerkMagnitude<T> left, Duration<T> right) => Multiply<AngularAccelerationMagnitude<T>>(left, right);
};