Showing posts with label Solution. Show all posts
Showing posts with label Solution. Show all posts

Tuesday, May 31, 2016

I am my own grandfather problem

comments 3 Blogger Comments

Many, many years ago when I was twenty-three
I was married to a widow who was pretty as could be
This widow had a grownup daughter who had hair of red
My father fell in love with her, and soon they too were wed
This made my Dad my son-in-law and really changed my life
For now my daughter was my mother, 'cause she was my father's wife
And to complicate the matter, even though it brought me joy,
I soon became the father of a bouncing baby boy
My little baby then became a brother-in-law to Dad
And so became my uncle, though it made me very sad
For if he were my uncle, then that also made him brother
Of the widow's grownup daughter, who was of course my stepmother
Father's wife then had a son who kept them on the run
And he became my grandchild, for he was my daughter's son
My wife is now my mother's mother, and it makes me blue
Because although she is my wife, she's my grandmother too
Now if my wife is my grandmother, then I'm her grandchild
And every time I think of it, it nearly drives me wild
'Cause now I have become the strangest case you ever saw
As husband of my grandmother, I am my own grandpa
CHALLENGES:
1. Write Predicate Calculus representing the situation with a series of expressions
2. Use modus ponens to conclude that “I am my own grandfather”.

First, try it out yourself!

Click here to reveal solution!
Predicate Calculus representing the situation with a series of expressions:
  • married(i,w).
  • mother(w,d).
  • mother(d,s1).
  • father(f,s1).
  • father(f,i).
  • father(i,s2).
  • mother(w,s2).
use modus ponens on this system to prove the conclusion that “I am my own grandfather”.
  1. ∀ X Y ∃ Z married(X,Z)∧mother(Z,Y)⇒ father(X,Y).
  2. ∀ X Y ∃ Z father(Z,X)∧father(Z,Y)⇒ brother(X,Y).
  3. ∀ X Y ∃ Z father(X,Z),mother(Z,Y)⇒ grandfather(X,Y).
  4. ∀ X Y ∃ Z grandfather(X,Z)∧brother(Z,Y)⇒ grandfather(X,Y).
  5. married(i,w).
  6. mother(w,d).
  7. mother(d,s1).
  8. father(f,s1).
  9. father(f,i).
  10. From 1,5,6::
    married(i,w)∧mother(w,d)⇒ father(i,d).
  11. From 3,7,10 ::
    father(i,d),mother(d,s1)⇒ grandfather(i,s1).
  12. From 2,8,9 ::
    father(f,s1)∧father(f,i)⇒ brother(s1,i).
  13. From 4,11,12 ::
    grandfather(i,s1)∧brother(s1,i)⇒ grandfather(i,i).
Hence, I'm my own grandfather.
Now, a video ;)
I'm my own Grandpa. Interesting idea, isn't it?
If you have any alternate solution, please feel free to submit a solution. Ideally, making an E-mail post would be appropriate, but commenting right on this page is also okay. Or, if you're really interested, you could also drop us your E-mail address and become an author(E-mail ID must be associated with a Gmail provider).
Read More

Saturday, December 19, 2015

Solution to User Question: CG_001

comments 0 Blogger Comments
 CG Question; Binod asks:
Please provide me the solution :computer graphicsconsider 512 pixels by 512 scan lines with 24 bit true colour.if 5 minutes video is required to capture calculate the total memory requirement



@Binod:
Simple really, 

First determine the number of pixels. 
In this question 512x512 is the number. 

Then determine the bit-depth which is 24bit here. 
Bit-depth represents the number of bits assigned to a pixel in a display device. 

Now the given time duration is 5minutes i.e 300seconds. 

The total memory requirement would be 
= 512 x 512 x 24 x 300 x 1 
= 1887436800bits. 

Divide it by 8 to get Byte value = 235929600Bytes

Divide it by 1024 to get Kilobyte value = 230400Kilobytes

Divide it by 1024 to get Megabyte value = 225Megabytes

This solution assumes the following things:

  • The video is being refreshed at only 1 frame per second.
    as seen here ( 512 x 512 x 24 x 300 x 1 ) which represents 1fps
  • The video does not undergo any optimizing algorithm to reduce video memory. In real-practice, videos are shot with such algorithms in place which allows it to retain maximum quality with small size.
calculate yourself:




check your solution:

Enter Screen resolution: x
Enter bit-depth:
Enter time in seconds:
Enter frame-rate:
Answer:

Read More

Most read this week!