Change map in adb

Arndt Jonasson arndt at ttds.UUCP
Sun Jan 19 14:38:10 AEST 1986


Newsgroups: net.math
Subject: Re: A real problem! (Not a polar bear problem)
Summary: 
Expires: 
References: <509 at klipper.UUCP> <1096 at jhunix.UUCP> <2081 at umcp-cs.UUCP> <775 at mmintl.UUCP> <45 at yale.ARPA> <383 at faron.UUCP>
Sender: 
Reply-To: arndt at ttds.UUCP (Arndt Jonasson)
Followup-To: 
Distribution: net
Organization: The Royal Inst. of Techn., Stockholm
Keywords: 

In article <383 at faron.UUCP> bs at faron.UUCP (Robert D. Silverman) writes:
>> 
>>     Enough silly polar bear problems.
>>     Here's a problem that requires a little more sophistication:
>> 
>> 	The 3-4-5 triangle has integral area (area=6).
>> 	The 13-14-15 triangle has integral area (area=84).
>> 	Find all triangles with sides n-(n+1)-(n+2) that have
>> 	integral area.  
>> 
>>         Note:  This isn't an elementary problem.
>> 	I'll send the answer to anybody who wants it, and maybe even post 
>> 	it . . .
>> -- 
>> 					      Thomas Andrews
>> 					      andrews-thomas at yale
>
>Not to contradict you but the solution IS elementary. One need only know a 
>little elementary number theory including simple diophantine equations.
> 
>The area of a triangle is: SQRT( s (s-a) (s-b) (s-c)) where a,b,c are the
>lengths of the sides and s is the semi-perimeter. (Heron's formula) Substitute
> n, n+1, n+2 and we obtain:
>
>1/4 (n+1) sqrt( 3 (n+3) (n-1) )
>
>Thus we require that 3(n+3)(n-1) be a square, say A^2.
>
>Now it is easy to see that either n+3 or n-1 must be divisible by 3, so
>
>n = 0 or 1 mod 3. Further, A must be an multiple of 3, say 3h.
> 
>------------------------------------------------------------------------------
>
>Case 1: n = 1 mod 3
>
>Let n = 3 k + 1  for some k
>
>we obtain: k(3k+4) = h^2 
> 
>Solving for k we obtain via the quadratic formula:
>
>(-4 +/- sqrt(16 + 12h^2))/6
>
>And we require that 4 + 3h^2 be a square 
>
>------------------------------------------------------------------------
>
>Case 2:  n = 0 mod 3
>
>Let n = 3 k
>
>we obtain: (k+1)(3k-1) = h^2 
>
>again we obtain 4 + 3h^2 must be a square by solving for k.
> 
>
>-----------------------------------------------------------------------
>Combining these we find:
>
>k = (sqrt(4 + 3h^2) -1) / 3     or   k = (sqrt(4 + 3h^2) - 2) /3
>
>
> 
>We now must have 4 + 3h^2 = s^2  or  s^2 - 3h^2 = 4
>
>This is a (modified) Pells equation. Its solution is given by:
>
>		     P
>(1/2 (s + sqrt(3) h )	P = 0, 1, 2, ...
>       0           0
> 
>where s   and    h    are the least positive solution. (4,2)
>       0           0
> 
>One can also obtain new solutions via the linear recurrence relation:
>
>s  = 4s    -  s
> i     i-1     i-2
>
>This yields the sequence of solutions: s = (2, 4, 14, 52, 214, ...)
>				       h = (0, 2, 8,  30, 112, ...)
> 
>Note: One can derive the solution to the above by elementary means using
>a little theory about recurrence relations OR if you know some algebraic
>number theory by finding units in the quadratic extension field Q(sqrt(-3)).
> 
>If we substitute the values given for h, we can solve for k and hence get n.
> 
>This solution is essentially complete.
> 
>
>Bob Silverman   (they call me Mr. 9)


Newsgroups: net.internat
Subject: Re: Anti-Hyphenation
Summary: 
Expires: 
References: <471 at harvard.ARPA> <773 at mmintl.UUCP> <968 at enea.UUCP> <501 at harvard.ARPA> <795 at mmintl.UUCP> <3353 at brl-tgr.ARPA> <1092 at enea.UUCP>
Sender: 
Reply-To: arndt at ttds.UUCP (Arndt Jonasson)
Followup-To: 
Distribution: net
Organization: The Royal Inst. of Techn., Stockholm
Keywords: 

In article <1092 at enea.UUCP> sommar at enea.UUCP (Erland Sommarskog) writes:
>Someone (Sorry, I didn't care to include his article) in <3353 at brl-tgr.ARPA>
>talks against hyphenation.
>
>Let's fisrt note: If you right-justify, sometimes you must hyphenate
>                  to      avoid      lines    like      this     one
>                  which are very hard to read.
>Then my main question:
>                  What about newspapers? Should they look like
>		  One
>		  word
>		  on 
>		  every line, when long words appear in the text.
>		  
>I will not suggest hyphenation should be done everywhere possible,
>but in some places you got to do it. And it shall always be done
>with care, no matter if you writing by hand or by computer.


Subject: change map in adb
Newsgroups: net.unix, net.lang.c

[Anyone for net.lang.as? :-)]

In a certain application for the MC68000/68010, I want to use the high address
bits as object tags. One of the 'objects' marked in this way is the PC. This
is quite ok when running, but when debugging, adb can't find the address. I
have tried to change the address mapping in adb to make adr+0xD000000 map
identically as adr, but adb still doesn't recognize the address. What am I
doing wrong? (The system is approximately System III.)

Please answer by mail, as I don't ordinarily read these newsgroups.

Thanks in advance,
Arndt Jonasson
Newsgroups: net.lang.c
Subject: Re:  Pointing Float
Summary: 
Expires: 
References: <707 at brl-tgr.ARPA>
Sender: 
Reply-To: arndt at ttds.UUCP (Arndt Jonasson)
Followup-To: 
Distribution: 
Organization: The Royal Inst. of Techn., Stockholm
Keywords: 

Newsgroups: net.lang.c
Subject: Re:  Pointing Float
Summary: 
Expires: 
References: <707 at brl-tgr.ARPA>
Sender: 
Reply-To: arndt at ttds.UUCP (Arndt Jonasson)
Followup-To: 
Distribution: 
Organization: The Royal Inst. of Techn., Stockholm
Keywords: 

Newsgroups: net.lang.c
Subject: Re:  Pointing Float
Summary: 
Expires: 
References: <707 at brl-tgr.ARPA>
Sender: 
Reply-To: arndt at ttds.UUCP (Arndt Jonasson)
Followup-To: 
Distribution: 
Organization: The Royal Inst. of Techn., Stockholm
Keywords: 

Subject: change map in adb
Newsgroups: net.unix net.lang.c

[Anyone for net.lang.as? :-)]

In a certain application for the MC68000/68010, I want to use the high
address bits as object tags. One of these 'objects' is the PC, whose tag
is 0xD. This is quite ok when running, but when debugging, adb complains
about not finding the address. I tried to change the adb address map to
map 0xD000000+ADR into ADR. $m showed what I thought to be the correct
mapping, but adb still doesn't accept these addresses. What am I doing
wrong? (The system is approximately System III.)

Please answer by mail, as I don't ordinarily read these newsgroups.

Thanks in advance,
Arndt Jonasson



More information about the Comp.unix mailing list