Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Release Notes Form 4.2.0

Takahiro Ueda edited this pageMar 8, 2024 ·9 revisions

We introduce Form 4.2.0, a new minor release. We have made more than 360 revisions,including more than 50 bugfixes, and the introduction of more than 20 new features.

Three highlights of the new features areid all,Format O4, andPolyratfun expand.

id all

The statementid all generatesall matches instead of just the first:

CF v,f,s;L F = v(1,2,3,4);id all v(?a,?b) = f(?a)*s(?b);Print +s;.end
F =   + f*s(1,2,3,4)   + f(1)*s(2,3,4)   + f(1,2)*s(3,4)   + f(1,2,3)*s(4)   + f(1,2,3,4)*s  ;

This statement is useful, for example, to generate automorphisms of graphs.

Format O4

Format O4 is a new output mode for polynomials. It uses local search methodsto reduce the number of operations in the polynomial. Generally it producesbetter results and is faster than O3.For example:

S   a,b,c,d,e,f,g,h,i,j,k,l,m,n;L   G = (4*a^4+b+c+d + i^4 + g*n^3)^10 +        (a*h + e + f*i*j + g + h)^8 + (i + j + k + l + m + n)^12;Format O4,saIter=300; * use 300 iterations for optimization.sort#optimize G#write "Optimized with Horner scheme: `optimscheme_'"#write "Number of operations in output: `optimvalue_'"#clearoptimize.end
Optimized with Horner scheme: h,a,f,j,d,c,b,i,e,m,g,k,l,nNumber of operations in output: 1937

Polyratfun expand

ThePolyratfun, which is used for rational coefficients, now supportsexpansion. For example:

S ep;CF rat;Polyratfun rat;L F = rat(1+ep,ep^2 + 3*ep + 1);Print +s;.sortPolyratfun rat(expand,ep,5);Print +s;.end

produces

  F = + rat(ep + 1,ep^2 + 3*ep + 1)....  F = + rat(1 - 2*ep + 5*ep^2 - 13*ep^3 + 34*ep^4 - 89*ep^5)

Further changes are described in the Changelog below.

Changelog - Form 4.2.0 (2017-07-06)

Caveats

  • Duplicated labels in a module now give compiler errors, which were justignored in previous versions(#69)
  • Now FORM does not accept:= in defining expressions likeLocal F := 1; and gives compiler errors(84d7188,#293)
  • Introduction of pattern matching withminus vector may break programswritten for previous versions. Nowf(-v?) matches with bothf(-p)(wherev = p) andf(p) (v = -p) (but does not match with a genericvector-like object, e.g.,f(p+q), which is currently not supported).To avoid the latter match, one needs to usevector_ asf(-v?vector_).

Added

Textual manipulation on the output.

  • #Add
  • #CloseDictionary
  • #OpenDictionary
  • #UseDictionary

Storage for spectator terms.

  • CopySpectator
  • CreateSpectator
  • EmptySpectator
  • RemoveSpectator
  • ToSpectator

Setup parameters

  • tempsortdir setup parameter,$FORMTMPSORT environment variable and-ts command line option to specify a directory for sort files
  • wtimestats setup parameter,On/Off wtimestats statement and-W command line option to print the wall-clock time on the master(#127)
  • T (= 10^12) was added as an unit prefix for integer parameters

Preprocessor

  • activeexprnames_ andnumactiveexprs_ variables allow one to enumeratecurrently active expressions(#175)
  • optimvalue_ andoptimscheme_ variables provide additional informationfrom output optimization
  • pid_ variable gives the process identifier of the FORM process
  • toupper_() andtolower_() macros to convert text to upper/lower case
  • #AppendPath and#PrependPath to manipulate the FORMPATH at runtime
  • #If
    • isdefined() checks if an object has been defined
  • #ReverseInclude reads an input file but in reverse order
  • #SkipExtraSymbols adds a number of dummy extra symbols, which can be used tokeep extra symbols in previous output optimizations(forum?f=8&t=133)

Statements

  • ArgToExtraSymbol converts function arguments into external symbols(#137)
  • CommuteInset declares partially commutative sets(forum?f=8&t=131)
  • Delete ExtraSymbols removes extra symbols from the system(forum?f=8&t=133)
  • Format
    • O4 option to use local stochastic search for output optimization
    • QuadFortran option to print numbers as quadruple floating-point numbers inFortran compilers
  • Identify
    • all option generates all matches
  • If
    • occurs() checks if variables occur inside the current term
  • PolyRatFun
    • the second functionRAT as the reciprocal of apolyratfun
    • expand anddivergence options to expandpolyratfun with respect toa symbol
  • Table
    • zero-dimensional sparse tables, which behave as pure functions.Some examples can be found in#86
    • onefill option to fill table elements with1 by default
  • Transform
    • addargs to add function arguments
    • mulargs to multiply function arguments
    • selectargs,dropargs to select/drop some of function arguments(#86)
    • dedup to remove duplicates from function arguments(see also#158)

Set

  • vector_, the set of all declared vectors(#84)

Functions

  • id_ tries for simple replacements
  • mul_ performs polynomial multiplication(#49)
  • partitions_ generates all partitions of the arguments
  • perm_ generates all permutations of the arguments
  • putfirst_ moves a function argument to the first position(#86)

Changed

  • [parform]FillExpression is now available(#17)
  • The test suite was rewritten to work withoutstrace(#20)
  • Setup optionspath andincdir are now available as in the reference manual(#72)
  • Sets now can have negative vectors(#78)
  • Bracket andAntibracket now accept a set(#87)
  • #$var=... and#Inside are now allowed inside other statements(#135)
  • NowNTHREADS_ is always1 for the sequential FORM and ParFORM.(#159)

Fixed

  • [tform] Fixed a bug withCollect(#11)
  • [tform] Fixed a crash in factorizing a constant(#18)
  • Fixed failures of substitutions immediately afterPutInside/AntiPutInside(#30)
  • Fixed a bug oftransform,replace thatxarg_ acted only on symbols(#54)
  • Fixed a bug with combiningBracket+ andIntoHide(#61)
  • Fixed a bug thatPolyRatFun in functions always gave errors(#73)
  • Fixed a freeze with$x^n? in LHS(#77)
  • Fixed wrong results by simplifications on powers (exp_ function)(#90)
  • Put a runtime check for gamma matrix without spin line(#94)
  • Fixed failures in pattern matching with?a and symmetric functions(#117)
  • Fixed a bug thatrepeat is ignored for some of generated terms ofdd_(#121)
  • Fixed a behaviour of redefining hidden expressions that made duplicates(#129)
  • Fixed corrupted characters in printing the maximum negative integer(#139)
  • Fixed a crash ofBracket+ for large functions(#142)
  • Fixed a bug that a set of indices matched to a number(#153)
  • Fixed a bug inKeep Bracket which ran out the compressed buffer(#154)
  • Fixed a bug thatexpr[x] lost some terms withBracket+ for functions(#162)
  • FixedNormalize to work withf(-v) wherev is a vector(#163)
  • [tform] Fixed a crash ofexpr[x] withBracket+ and big expressions(#165)
  • Fixed a behaviour ofcount_ in functions(#167)
  • Fixed a bug that argument field wildcards were not expanded fordistrib_(#186)
  • Fixedgcd_ with0(#191)
  • Fixed a bug in the preprocessor that a comment character was eaten after a blcok construction(forum?f=3&t=135)
  • Fixed a bug in the compiler to parse arguments forArgImplode/ArgExplode(forum?f=3&t=169)
  • Fixed theArgument environment with sets of functions(forum?f=3&t=187)
  • [parform] Fixed bugs inInParallel(forum?f=8&t=158)
  • Fixed#write "%e",expr for Fortran(44cf65f,aecd000)
  • FixedDelete Storage(44cf65f)
  • Fixed theDoubleFortran mode that printed an integer as a floating-point number unnecessarily(e80f244)
  • Fixed an infinite loop bug in polynomial GCD and increased performance(58bb42d,726f55d,483d98f)
  • [parform] Fixed a failure in disabling parallelization for global $-variables(928e8c9)
  • Fixed a bug in factorization due to corruption of the coefficient in Hensel lifting(6f06e94)
  • [sequential form] Fixed a forgotten initialization of a pointer. This led to crashes with $-variables storing big polynomials(b32e53e)
  • Fixed signs with functions inside functions(baa5b36)
  • Fix a memory bug inMakeInteger(4cc67db)
  • [tform] Fixed a bug inHide(e73c865)
  • Fixed a bug that caused a hide file not deleted at termination(1e6bfda)
  • Fixed the compiler to correctly recognize!<vector or set> option of theToTensor statement(e9643be)
  • Fixed a silent crash due to workspace overflow in function pattern matching(a8b0f2d)
  • Fixed memory bugs at the startup that gave unreasonable crashes in some circumstances(9b58d87)
  • Fixed build errors and improved portability(7136dda,6990928,043727c)
  • Fixed a nasty bug inBracket+(1ddffec)
  • Fixed a rare bug inBracket+(0f784ed)
  • Fixed memory allocation for $-variables, which seemed to be problematic only on macOS(f6b7409)

And some other small bug fixes, improvements and code refactoring.

Clone this wiki locally


[8]ページ先頭

©2009-2025 Movatter.jp