Umrechnung Kilometer pro Stunde (km/h) -> Beaufort (Bft)

Dieses PHP-Script rechnet Geschwindigkeitswerte von Kilometer pro Stunde (km/h) in Werte der Beaufortskala (Bft) um. Anwendungsgebiet ist zum Beispiel die Umrechnung von Windgeschwindigkeiten in der Meteorologie.

<?php
/*
    This Software calculates a beaufort value by given kilometers per hour.

    Copyright (C) 2020 Guido Richter / tintenkobold.de

    This program is free software: you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
    the Free Software Foundation, either version 3 of the License, or
    (at your option) any later version.

    This program is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU General Public License [http://www.gnu.org/licenses/] for more details.
*/

function kmh2bft($kmh)
{
	return round(($kmh/3.6/0.836) ** (2/3));
}

?>

Schreibe einen Kommentar