Post Reply 
(11C) (15C) Convert German Units of Area Measurement
04-09-2018, 02:47 PM
Post: #1
(11C) (15C) Convert German Units of Area Measurement
2 converter program for popular German units of area measurement.

Program A converts Saarlands to Fußballfelds.

Program B converts Fußballfelds to Saarlands.

(There is no way to convert to Metric or Imperial, why would you ever want to do that?)

Code:
; Convert Saarlands to Fußballfelds
LBL A
  3
  6
  EEX
  4
  *
  RTN

; Convert Fußballfelds to Saarlands
LBL B
  3
  6
  EEX
  4
  /
  RTN
Find all posts by this user
Quote this message in a reply
04-09-2018, 07:19 PM
Post: #2
RE: (11C) (15C) Convert German Units of Area Measurement
(04-09-2018 02:47 PM)michaelzinn Wrote:  Program A converts Saarlands to Fußballfelds.
Program B converts Fußballfelds to Saarlands.

Maybe you should explain this to our non-German readers. ;-)

By the way: one "Fußballfeld" is mostly used to illustrate an area of 1 hectare (10.000 m²). Sure, the field itself usually is smaller, but the idea is to have a handy comparison. Based on this fact and the Saarland's area being 2570 km² a conversion factor of 257.000 may be more appropriate.

Dieter
Find all posts by this user
Quote this message in a reply
04-10-2018, 01:48 PM
Post: #3
RE: (11C) (15C) Convert German Units of Area Measurement
(04-09-2018 07:19 PM)Dieter Wrote:  
(04-09-2018 02:47 PM)michaelzinn Wrote:  Program A converts Saarlands to Fußballfelds.
Program B converts Fußballfelds to Saarlands.

Maybe you should explain this to our non-German readers. ;-)

By the way: one "Fußballfeld" is mostly used to illustrate an area of 1 hectare (10.000 m²). Sure, the field itself usually is smaller, but the idea is to have a handy comparison. Based on this fact and the Saarland's area being 2570 km² a conversion factor of 257.000 may be more appropriate.

Dieter

Interesting! I didn't know that a Fußballfeld is just an alias for hectare when used as an area of measurement. That makes it even more confusing.
Find all posts by this user
Quote this message in a reply
04-10-2018, 06:09 PM
Post: #4
RE: (11C) (15C) Convert German Units of Area Measurement
(04-10-2018 01:48 PM)michaelzinn Wrote:  Interesting! I didn't know that a Fußballfeld is just an alias for hectare when used as an area of measurement. That makes it even more confusing.

Well, that's at least a common way of visualizing hectares. Here the term "entspricht einer Größe von fünf Fußballfeldern" simply is a translation of "5 Hektar". But also take a look at Wikipedia. So a hectare fits very well if you consider the whole area inside the 400 m track.

By the way – if I remember correctly you once said you like "vintage programming", and in another thread you asked for traditional solutions to overcome the limits of simple programmable calculators. So maybe you will also like this idea:

The 11C/15C has is only a limited number of labels. More important, it can only display numbers, there is no text output. Now... did [A] convert from Saarlands to Fußballfelds or was it the other way round? Here is a simple trick: since areas cannot be negative the sign may be used to flag a result. This way both conversions can be done with one single program:

Code:
LBL A
x<0?   (TEST 2)
1/x
3
6
EEX
4
x
x<0?   (TEST 2)
1/x
CHS
RTN

Rule: Saarlands are positive, Fußballfelds are negative.
Want it the other way round? Replace x<0? with x>0?.

Convert 2 Saarlands: 2 [A] => –720.000
Since the result is negative you know that these are 720.000 Fußballfelds.

Convert one Million Fußballfelds: –1.000.000 [A] => 2,7778
Since the result is positive you know that these are 2,8 Saarlands.

Pressing [A] multiple times switches between the two units:
2
[A] => –720.000
[A] => 2
[A] => –720.000
[A] => 2
...

So the area is 2 Saarlands or 720.000 Fußballfelds.

Dieter
Find all posts by this user
Quote this message in a reply
04-10-2018, 06:59 PM
Post: #5
RE: (11C) (15C) Convert German Units of Area Measurement
(04-10-2018 06:09 PM)Dieter Wrote:  
(04-10-2018 01:48 PM)michaelzinn Wrote:  Interesting! I didn't know that a Fußballfeld is just an alias for hectare when used as an area of measurement. That makes it even more confusing.

Well, that's at least a common way of visualizing hectares. Here the term "entspricht einer Größe von fünf Fußballfeldern" simply is a translation of "5 Hektar". But also take a look at Wikipedia. So a hectare fits very well if you consider the whole area inside the 400 m track.

By the way – if I remember correctly you once said you like "vintage programming", and in another thread you asked for traditional solutions to overcome the limits of simple programmable calculators. So maybe you will also like this idea:

The 11C/15C has is only a limited number of labels. More important, it can only display numbers, there is no text output. Now... did [A] convert from Saarlands to Fußballfelds or was it the other way round? Here is a simple trick: since areas cannot be negative the sign may be used to flag a result. This way both conversions can be done with one single program:

Code:
LBL A
x<0?   (TEST 2)
1/x
3
6
EEX
4
x
x<0?   (TEST 2)
1/x
CHS
RTN

Rule: Saarlands are positive, Fußballfelds are negative.
Want it the other way round? Replace x<0? with x>0?.

Convert 2 Saarlands: 2 [A] => –720.000
Since the result is negative you know that these are 720.000 Fußballfelds.

Convert one Million Fußballfelds: –1.000.000 [A] => 2,7778
Since the result is positive you know that these are 2,8 Saarlands.

Pressing [A] multiple times switches between the two units:
2
[A] => –720.000
[A] => 2
[A] => –720.000
[A] => 2
...

So the area is 2 Saarlands or 720.000 Fußballfelds.

Dieter

Ah, you are using the sign as an additional input parameter. Great idea!
Find all posts by this user
Quote this message in a reply
04-10-2018, 08:15 PM
Post: #6
RE: (11C) (15C) Convert German Units of Area Measurement
(04-10-2018 06:59 PM)michaelzinn Wrote:  Ah, you are using the sign as an additional input parameter.

It flags both input and output.

(04-10-2018 06:59 PM)michaelzinn Wrote:  Great idea!

But not really a new one. ;-)

Dieter
Find all posts by this user
Quote this message in a reply
01-22-2021, 06:10 AM
Post: #7
RE: (11C) (15C) Convert German Units of Area Measurement
Thanks for this nice technique! It may not be new but works well and I've used it to combine two existing programs I've kept in my 11-C for years as a machinist/programmer - saving two program lines and 1 (precious) label in the process.

I calculate spindle RPM (rotations per minute) from SFPM (Surface feet per minute) and tool Diameter using RPM = (SFPM * 12) / (PI * DIA)

And occasionally, given the RPM and Tool Diameter calculate SFPM using
SFPM = (PI * DIA * RPM)/12

For the updated program I enter SFPM as positive and RPM as negative, followed by DIA (always pos):

Code:

LBL A
PI
*
X><Y
X<0?
1/x
/
1
2
/
X>0?
1/X
CHS
RTN

Example: what RPM do you run a 2.0 dia tool at 3000 SFPM?
3000 ENTER 2 A yields: -5730 RPM (rounded to nearest integer)

Example: what SFPM is a .50 dia tool at 6000 RPM?
6000 CHS ENTER .5 A yields: 785 SFPM (to nearest integer)

Note: Interestingly, I had to change the 2nd test to X>0? to get things to come out right - probably due to using division after the constant 12 (feet to inches). One could probably rewrite to make the tests the same but the program works as is and made sense to me when tracing the program and stack contents.

Thanks again!

Allen
Find all posts by this user
Quote this message in a reply
Post Reply 




User(s) browsing this thread: 1 Guest(s)