Decimal to fraction conversion


Closed Thread
Results 1 to 21 of 21

Hybrid View

  1. #1
    skimask's Avatar
    skimask Guest


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by tico View Post
    I am looking for a way to convert a decimal number to a fraction I have looked thru the manual but cant seem to find a solution.

    What I need to do is convert say .0625 to 1/16

    I would like a resoultion of 1/16 of an inch.
    Well,
    .0625 * 10000 = 625
    625 / 625 = 1
    1/16

    .1250 * 10000 = 1250
    1250 / 625 = 2
    2/16

    and so on and so on...

  2. #2
    Join Date
    Sep 2004
    Location
    montreal, canada
    Posts
    6,898


    Did you find this post helpful? Yes | No

    Default

    (results * 16)/1000 ???

    But we don't see and know what you're currently using... hard to guess
    Steve

    It's not a bug, it's a random feature.
    There's no problem, only learning opportunities.

  3. #3
    skimask's Avatar
    skimask Guest


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by mister_e View Post
    (results * 16)/1000 ???
    I'm waiting for the question 'how do I get a decimal point or a slash in the fraction' or something like that.

  4. #4
    Join Date
    Dec 2006
    Posts
    38


    Did you find this post helpful? Yes | No

    Talking

    Thanks for the reply mister_e
    I have not written anything yet I am just begining this code for some reson I thought there might be some function built in.
    Its okay I guess I will just have to do it the straight math way.
    Last edited by tico; - 26th April 2007 at 02:52.

  5. #5
    Join Date
    Dec 2006
    Posts
    38


    Did you find this post helpful? Yes | No

    Default What happened skimask

    Hey skimask
    WOW 3 minutes went by and you realized you didnt say anything cocky, or did you just have to think for a while due to the fact you couldnt tell me to refer to the little green book at section x.yy

    and as for your cocky comment you can continue to wait for the other shoe to drop.

    but just so you dont have something else cocky to come back with I guess this will work...............

    LCDOUT $fe, 1, #Product,"/",#Remainder

  6. #6
    skimask's Avatar
    skimask Guest


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by tico View Post
    Hey skimask
    WOW 3 minutes went by and you realized you didnt say anything cocky, or did you just have to think for a while due to the fact you couldnt tell me to refer to the little green book at section x.yy
    and as for your cocky comment you can continue to wait for the other shoe to drop.
    but just so you dont have something else cocky to come back with I guess this will work...............
    LCDOUT $fe, 1, #Product,"/",#Remainder
    What's the fascination here?

    And as far as the 'I'm waiting for the question 'how do I get a decimal point or a slash in the fraction' or something like that.' comment...if you'll look closer, I don't remember seeing a name attached to that...unless I missed it.

    And sorry it took me 5 minutes to get that comment to you.
    I'll try to be quicker next time...mmmmkkk?!!?!

  7. #7
    Join Date
    Dec 2006
    Posts
    38


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by skimask View Post
    What's the fascination here?
    The fascination is that you realized I actually helped someone without being cocky about it

    And as far as the 'I'm waiting for the question 'how do I get a decimal point or a slash in the fraction' or something like that.' comment...if you'll look closer, I don't remember seeing a name attached to that...unless I missed it.
    fourth post down is your comment on mister_e 's post

    And sorry it took me 5 minutes to get that comment to you.
    I'll try to be quicker next time...mmmmkkk?!!?!
    actually it took you 3 minutes 09:17 first post 09:20 second post 20-17= 3

    unless I forgot 1st grade math

    I have been on this forum for a little while now and I always dread having to put up a post asking for help due to ridicule and snobby answers from people like yourself.

    I try to learn afterall I spent lots of money on PBP a development system and associted learning items, after searching and looking thru the manual, I dont always find the answers to me questions so I need to post to this forum and I always wait for someone like yourself to put a nasty post up like RTFM RTFD or whatever, sometimes your read but dont comprehend or get confused, hence the need for a question on this forum, afterall I thought that was the forums purpose to help others not ridicule your next victim as you so seem to enjoy post after post.

Similar Threads

  1. A/D conversion with PIC18F67J50
    By ScaleRobotics in forum mel PIC BASIC Pro
    Replies: 9
    Last Post: - 8th May 2009, 02:48
  2. Help for decimal conversion
    By eva in forum mel PIC BASIC Pro
    Replies: 2
    Last Post: - 15th March 2007, 19:20
  3. microns to decimal conversion
    By Rleonard in forum mel PIC BASIC Pro
    Replies: 4
    Last Post: - 28th February 2007, 15:37
  4. Decimal to Binary Conversion
    By schlaray in forum mel PIC BASIC Pro
    Replies: 4
    Last Post: - 23rd December 2006, 15:58
  5. Decimal to binary conversion
    By Demon in forum Code Examples
    Replies: 9
    Last Post: - 25th February 2005, 21:05

Members who have read this thread : 0

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts