WillPower.Math 1.0.2025.8

dotnet add package WillPower.Math --version 1.0.2025.8
                    
NuGet\Install-Package WillPower.Math -Version 1.0.2025.8
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="WillPower.Math" Version="1.0.2025.8" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="WillPower.Math" Version="1.0.2025.8" />
                    
Directory.Packages.props
<PackageReference Include="WillPower.Math" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add WillPower.Math --version 1.0.2025.8
                    
#r "nuget: WillPower.Math, 1.0.2025.8"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package WillPower.Math@1.0.2025.8
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=WillPower.Math&version=1.0.2025.8
                    
Install as a Cake Addin
#tool nuget:?package=WillPower.Math&version=1.0.2025.8
                    
Install as a Cake Tool

WillPower.Math

A library intended to provide calculations not provided within System.Math. Objects include FiscalCalculator, Amortization, PaymentInstallment, Randomizer and Degree.

Extensions

  • System.DateTime.MonthDifference(System.DateTime) : Caculates the absolute number of months between provided DateTimes.

  • WillPower.Amortization.TotalInterest() : Returns the total interest amount in a loan schedule.

  • System.DateTime.DaysInMonth() : Returns the number of days in the month and year of the provided DateTime.

  • System.DateTime.DaysInYear() : Returns the number of days in the year of the provided DateTime.

  • System.Double.RoundHigh(System.Double = 2) : Rounds to the highest double value at the provided precision value (or 2).

  • System.Double.RoundLow(System.Double = 2) : Rounds to the lowest double value at the provided precision value (or 2).

  • System.Double.RoundFlat(System.Double = 2) : Rounds to the nearest double value at the provided precision value (or 2).

  • System.DateTime.FirstOfTheMonth() : Returns the first day of the month and year of the provided DateTime.

  • System.DateTime.EndOfTheMonth() : Returns the last day of the month and year of the provided DateTime.

Sample Code

	// Amortization
	WillPower.Amortization paymentSchedule = WillPower.FiscalCalculator.AmortizeLifeOfLoan(DateTime.Today, 36, 25000, 4.5m, WillPower.FiscalPeriod.Monthly);
	foreach (WillPower.PaymentInstallment payment in paymentSchedule.Schedule)
	{
		...
	}
	// Randomizer
	int randomValue = WillPower.Randomizer.GetInt(0, 100);
Product Compatible and additional computed target framework versions.
.NET net8.0 is compatible.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed.  net9.0 was computed.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  net10.0 was computed.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
  • net8.0

    • No dependencies.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
1.0.2025.8 171 8/26/2025
1.0.2025.3 123 3/21/2025
0.2021.8.26 885 8/26/2021