# # spec file for package perl-Math-Symbolic # # Copyright (c) 2024 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed # upon. The license for this file, and modifications and additions to the # file, is the same license as for the pristine package itself (unless the # license for the pristine package is not an Open Source License, in which # case the license is the MIT License). An "Open Source License" is a # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. # Please submit bugfixes or comments via https://bugs.opensuse.org/ # %define cpan_name Math-Symbolic Name: perl-Math-Symbolic Version: 0.613.0 Release: 0 # 0.613 -> normalize -> 0.613.0 %define cpan_version 0.613 License: Artistic-1.0 OR GPL-1.0-or-later Summary: Symbolic calculations URL: https://metacpan.org/release/%{cpan_name} Source0: https://cpan.metacpan.org/authors/id/S/SM/SMUELLER/%{cpan_name}-%{cpan_version}.tar.gz Source100: README.md BuildArch: noarch BuildRequires: perl BuildRequires: perl-macros BuildRequires: perl(Module::Build) BuildRequires: perl(Parse::RecDescent) Requires: perl(Parse::RecDescent) Provides: perl(Math::Symbolic) = %{version} Provides: perl(Math::Symbolic::AuxFunctions) = %{version} Provides: perl(Math::Symbolic::Base) = %{version} Provides: perl(Math::Symbolic::Compiler) = %{version} Provides: perl(Math::Symbolic::Constant) = %{version} Provides: perl(Math::Symbolic::Custom) = %{version} Provides: perl(Math::Symbolic::Custom::Base) = %{version} Provides: perl(Math::Symbolic::Custom::DefaultDumpers) = %{version} Provides: perl(Math::Symbolic::Custom::DefaultMods) = %{version} Provides: perl(Math::Symbolic::Custom::DefaultTests) = %{version} Provides: perl(Math::Symbolic::Derivative) = %{version} Provides: perl(Math::Symbolic::ExportConstants) = %{version} Provides: perl(Math::Symbolic::MiscAlgebra) = %{version} Provides: perl(Math::Symbolic::MiscCalculus) = %{version} Provides: perl(Math::Symbolic::Operator) = %{version} Provides: perl(Math::Symbolic::Parser) = %{version} Provides: perl(Math::Symbolic::Parser::Precompiled) = %{version} Provides: perl(Math::Symbolic::Parser::Yapp) Provides: perl(Math::Symbolic::Parser::Yapp::Driver) = 1.50.0 Provides: perl(Math::Symbolic::Variable) = %{version} Provides: perl(Math::Symbolic::VectorCalculus) = %{version} Provides: perl(Parse::RecDescent::Math::Symbolic::Parser::Precompiled) %undefine __perllib_provides %{perl_requires} %description Math::Symbolic is intended to offer symbolic calculation capabilities to the Perl programmer without using external (and commercial) libraries and/or applications. Unless, however, some interested and knowledgable developers turn up to participate in the development, the library will be severely limited by my experience in the area. Symbolic calculations are an active field of research in CS. There are several ways to construct Math::Symbolic trees. There are no actual Math::Symbolic objects, but rather trees of objects of subclasses of Math::Symbolic. The most general but unfortunately also the least intuitive way of constructing trees is to use the constructors of the Math::Symbolic::Operator, Math::Symbolic::Variable, and Math::Symbolic::Constant classes to create (nested) objects of the corresponding types. Furthermore, you may use the overloaded interface to apply the standard Perl operators (and functions, see OVERLOADED OPERATORS) to existing Math::Symbolic trees and standard Perl expressions. Possibly the most convenient way of constructing Math::Symbolic trees is using the builtin parser to generate trees from expressions such as '2 * x^5'. You may use the 'Math::Symbolic->parse_from_string()' class method for this. Of course, you may combine the overloaded interface with the parser to generate trees with Perl code such as '$term * 5 * 'sin(omega*t+phi)'' which will create a tree of the existing tree $term times 5 times the sine of the vars omega times t plus phi. There are several modules in the distribution that contain subroutines related to calculus. These are not loaded by Math::Symbolic by default. Furthermore, there are several extensions to Math::Symbolic available from CPAN as separate distributions. Please refer to SEE ALSO for an incomplete list of these. For example, Math::Symbolic::MiscCalculus come with 'Math::Symbolic' and contains routines to compute Taylor Polynomials and the associated errors. Routines related to vector calculus such as grad, div, rot, and Jacobi- and Hesse matrices are available through the Math::Symbolic::VectorCalculus module. This module is also able to compute Taylor Polynomials of functions of two variables, directional derivatives, total differentials, and Wronskian Determinants. Some basic support for linear algebra can be found in Math::Symbolic::MiscAlgebra. This includes a routine to compute the determinant of a matrix of 'Math::Symbolic' trees. %prep %autosetup -n %{cpan_name}-%{cpan_version} %build perl Build.PL --installdirs=vendor ./Build build --flags=%{?_smp_mflags} %check ./Build test %install ./Build install --destdir=%{buildroot} --create_packlist=0 %perl_gen_filelist %files -f %{name}.files %doc Changes examples README TODO Yapp.yp %changelog