phpman > man > pnmarith(1)

Markdown | JSON | MCP    

TLDR: pnmarith (tldr-pages)

This command has been superseded by `pamarith`.

  • View documentation for the current command
    tldr pamarith
pnmarith(1)                            General Commands Manual                           pnmarith(1)



NAME
       pnmarith - perform arithmetic on two portable anymaps

SYNOPSIS
       pnmarith -add|-subtract|-multiply|-difference|-minimum|-maximum.  pnmfile1 pnmfile2

DESCRIPTION
       Reads  two  portable anymaps as input.  Performs the specified arithmetic operation, and pro‐
       duces a portable anymap as output.  The two input anymaps must be the same width and height.

       The arithmetic is performed between corresponding pixels in the two anymaps, as if maxval was
       1.0,  black  was 0.0, and a linear scale in between.  Results that fall outside of [0..1) are
       truncated.

       The operator -difference calculates the absolute value of pnmarith  -subtract  pnmfile1  pnmfile2, i.e. no truncation is done.

       All flags can be abbreviated to their shortest unique prefix.

SEE ALSO
       pbmmask(1), pnmpaste(1), pnminvert(1), pnm(5)

AUTHOR
       Copyright  (C)  1989,  1991  by  Jef  Poskanzer.   Lightly modified by Marcel Wijkstra <wijk‐
       stra AT fwi.nl>



                                           26 August 1993                                pnmarith(1)

Generated by phpman v3.7.12 Author: Che Dong Under GNU General Public License
2026-06-13 06:57 @216.73.216.28
CrawledBy Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)
Valid XHTML 1.0 TransitionalValid CSS!