Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options
 
PerlMonks  

comment on

( #3333=superdoc: print w/replies, xml ) Need Help??

Yes the image helped, I can see from that that perhaps this is what happens. To calculate a two's complement number take the difference of the highbit masked number, with the complement mask of the highbit number. The number being negative when the highbit is set, essentially saying complement mask minus the highbit mask number.

We could use pairs of numbers, such that the 'highbit' could be any binary number and the difference found between that and its pair then resolves into an integer. It's a different way of storing and operating on the numbers.

update added example code

=head1 polynumber binary pairs (bifields?) 0 00_00 -1 1 00_01 01_00 -2 2 00_10 10_00 -3 3 00_11 11_00 =cut

But, we get overlaps.

=head1 polynumber binary pairs (bifields?) overlaps 1 -2 10_01 01_10 -1 1 01_10 10_01 -3 0 00_11 11_11 =cut

note: row polynumbers are read opposite significant highbit first. That is, if these are 'N'etwork order they should be read 'V'ax order. This illustrates the concept.

edit added whitespace, and note

In reply to Re^6: Can I access and use UV types from perl? by Don Coyote
in thread Can I access and use UV types from perl? by Don Coyote

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":



  • Are you posting in the right place? Check out Where do I post X? to know for sure.
  • Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
    <code> <a> <b> <big> <blockquote> <br /> <dd> <dl> <dt> <em> <font> <h1> <h2> <h3> <h4> <h5> <h6> <hr /> <i> <li> <nbsp> <ol> <p> <small> <strike> <strong> <sub> <sup> <table> <td> <th> <tr> <tt> <u> <ul>
  • Snippets of code should be wrapped in <code> tags not <pre> tags. In fact, <pre> tags should generally be avoided. If they must be used, extreme care should be taken to ensure that their contents do not have long lines (<70 chars), in order to prevent horizontal scrolling (and possible janitor intervention).
  • Want more info? How to link or or How to display code and escape characters are good places to start.
Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others examining the Monastery: (5)
As of 2022-05-18 09:11 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Do you prefer to work remotely?



    Results (70 votes). Check out past polls.

    Notices?