flat assembler
Message board for the users of flat assembler.

Index > Projects and Ideas > Calculator project

Goto page Previous  1, 2, 3  Next
Author
Thread Post new topic Reply to topic
vid
Verbosity in development


Joined: 05 Sep 2003
Posts: 7106
Location: Slovakia
vid
also this doen't work:

1.343454e-9+1.5e-9
Post 16 Jan 2008, 05:31
View user's profile Send private message Visit poster's website AIM Address MSN Messenger ICQ Number Reply with quote
edfed



Joined: 20 Feb 2006
Posts: 4217
Location: 2018
edfed
key grid is like the windows calculator

ti scrolling prompt is like MSdos console, with doskey by default.
but is speak, i speak and i don't have coded a calculator...
try to find a TI8x emulator
Post 16 Jan 2008, 05:37
View user's profile Send private message Visit poster's website Reply with quote
codegrinder



Joined: 12 Dec 2005
Posts: 20
Location: Moldova
codegrinder
vid wrote:
- "-1e-5" doesn't work...

Fixed.
vid wrote:
- is "sin(pi)" supposed to be "0.049327995502523812" ? not sure, it's been some time...

Made radians mode by default.
vid wrote:
- add description of function arguments
- Add this: http://en.wikipedia.org/wiki/E_(mathematical_constant)

Added.


Description: Calculator+Sources
Download
Filename: calculator.zip
Filesize: 14.15 KB
Downloaded: 279 Time(s)

Post 16 Jan 2008, 06:39
View user's profile Send private message ICQ Number Reply with quote
codegrinder



Joined: 12 Dec 2005
Posts: 20
Location: Moldova
codegrinder
vid wrote:
also this doen't work:
1.343454e-9+1.5e-9

Last changes fixed this.
Post 16 Jan 2008, 06:40
View user's profile Send private message ICQ Number Reply with quote
codegrinder



Joined: 12 Dec 2005
Posts: 20
Location: Moldova
codegrinder
edfed wrote:
key grid is like the windows calculator

ti scrolling prompt is like MSdos console, with doskey by default.
but is speak, i speak and i don't have coded a calculator...
try to find a TI8x emulator


I plan to add keys and scrolling is also interesting idea but right now I'd like to have tested evaluations. Anyway thanks, I'll have you suggestion in mind.
Post 16 Jan 2008, 06:45
View user's profile Send private message ICQ Number Reply with quote
vid
Verbosity in development


Joined: 05 Sep 2003
Posts: 7106
Location: Slovakia
vid
this doesn't work either: "1.11111111111111111111111111111"
Post 16 Jan 2008, 18:42
View user's profile Send private message Visit poster's website AIM Address MSN Messenger ICQ Number Reply with quote
codegrinder



Joined: 12 Dec 2005
Posts: 20
Location: Moldova
codegrinder
vid wrote:
this doesn't work either: "1.11111111111111111111111111111"

It takes no more then 20 digits after point, no sense to take more because it will not give more precision. Can allow more by ignoring the rest of characters.
Post 16 Jan 2008, 18:53
View user's profile Send private message ICQ Number Reply with quote
vid
Verbosity in development


Joined: 05 Sep 2003
Posts: 7106
Location: Slovakia
vid
yes, rather ignore them
Post 16 Jan 2008, 21:51
View user's profile Send private message Visit poster's website AIM Address MSN Messenger ICQ Number Reply with quote
codegrinder



Joined: 12 Dec 2005
Posts: 20
Location: Moldova
codegrinder
vid wrote:
yes, rather ignore them

Here you are.


Description:
Download
Filename: calculator.zip
Filesize: 14.15 KB
Downloaded: 231 Time(s)

Post 17 Jan 2008, 02:30
View user's profile Send private message ICQ Number Reply with quote
bitRAKE



Joined: 21 Jul 2003
Posts: 2796
Location: dank orb
bitRAKE
Can you make leading with a "+" okay - like leading with "-"?

Try this to make the calculator choke: "--------------1"

Each "-" makes the calculator take longer, and longer, and longer, ... Laughing
Post 17 Jan 2008, 04:43
View user's profile Send private message Visit poster's website Reply with quote
Madis731



Joined: 25 Sep 2003
Posts: 2145
Location: Estonia
Madis731
That is one wierd error, seems like calculating the "-"-sign takes exponential amount of time :S

Btw, its starting to make shape, the calculator, so keep it up Smile
Post 17 Jan 2008, 06:50
View user's profile Send private message Visit poster's website Yahoo Messenger MSN Messenger Reply with quote
codegrinder



Joined: 12 Dec 2005
Posts: 20
Location: Moldova
codegrinder
Here is version with bugfixes (many -, +before number, many digits in integer part of a number) and new functions. Does anyone want hiperbolic or &, |, ^, <<, >>? Maybe some other functions?

Madis731 wrote:
Btw, its starting to make shape, the calculator, so keep it up Smile
Thanks, I'm going to make something useful (and possibly cool), not just another example.

[Edit]Found silly bug, so attachment is updated[/Edit]


Description:
Download
Filename: calculator.zip
Filesize: 15 KB
Downloaded: 266 Time(s)



Last edited by codegrinder on 18 Jan 2008, 04:18; edited 1 time in total
Post 18 Jan 2008, 03:05
View user's profile Send private message ICQ Number Reply with quote
vid
Verbosity in development


Joined: 05 Sep 2003
Posts: 7106
Location: Slovakia
vid
Quote:
Does anyone want hiperbolic or &, |, ^, <<, >>? Maybe some other functions?

if YOU want to make a good calculator, add 'em!

but careful about ^ - is it exponential or xor? i'd prefer ** for exp i quess.
Post 18 Jan 2008, 03:41
View user's profile Send private message Visit poster's website AIM Address MSN Messenger ICQ Number Reply with quote
codegrinder



Joined: 12 Dec 2005
Posts: 20
Location: Moldova
codegrinder
vid wrote:
but careful about ^ - is it exponential or xor? i'd prefer ** for exp i quess.

The same schema is in devcalc Smile.
Post 18 Jan 2008, 04:21
View user's profile Send private message ICQ Number Reply with quote
Madis731



Joined: 25 Sep 2003
Posts: 2145
Location: Estonia
Madis731
Code:
-96+9-1 = -88
-97+9-1 = -88.999999999999999
-98+9-1 = -89.999999999999999
-99+9-1 = -91
    
Post 18 Jan 2008, 07:31
View user's profile Send private message Visit poster's website Yahoo Messenger MSN Messenger Reply with quote
codegrinder



Joined: 12 Dec 2005
Posts: 20
Location: Moldova
codegrinder
Madis731 wrote:
Code:
-96+9-1 = -88
-97+9-1 = -88.999999999999999
-98+9-1 = -89.999999999999999
-99+9-1 = -91
    

Fixed.


Description:
Download
Filename: calculator.zip
Filesize: 15.05 KB
Downloaded: 226 Time(s)

Post 18 Jan 2008, 11:44
View user's profile Send private message ICQ Number Reply with quote
asmrox



Joined: 19 Jan 2008
Posts: 160
asmrox
unicode strings, and calls to ansi functions.

<?xml version... whats that?


but works good Smile
Post 19 Jan 2008, 04:39
View user's profile Send private message Reply with quote
LocoDelAssembly
Your code has a bug


Joined: 06 May 2005
Posts: 4633
Location: Argentina
LocoDelAssembly
Quote:

<?xml version... whats that?


Because without it the dialogs doesn't follow the desktop theme and looks Win2000-like. It is noticeable on a WinXP with default desktop appearance settings the difference between using schemas and not.
Post 19 Jan 2008, 06:29
View user's profile Send private message Reply with quote
codegrinder



Joined: 12 Dec 2005
Posts: 20
Location: Moldova
codegrinder
asmrox wrote:
unicode strings, and calls to ansi functions.

Pardon me, but where did you see unicode strings except resource macroses?
asmrox wrote:
but works good Smile

Thanks Smile.
Post 19 Jan 2008, 10:52
View user's profile Send private message ICQ Number Reply with quote
codegrinder



Joined: 12 Dec 2005
Posts: 20
Location: Moldova
codegrinder
Hyperbolic functions + bugfixes. Sec was 1/sin(x) and Csc was 1/cos(x). Fixed.

I need your comments on future interface. You will find my vision in attachment. Any comments/ideas are appreciated.


Description:
Filesize: 17.91 KB
Viewed: 7825 Time(s)

interface.png


Description:
Download
Filename: calculator.zip
Filesize: 16.84 KB
Downloaded: 294 Time(s)

Post 20 Jan 2008, 04:24
View user's profile Send private message ICQ Number Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  
Goto page Previous  1, 2, 3  Next

< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2019, Tomasz Grysztar.

Powered by rwasa.