際際滷

際際滷Share a Scribd company logo
Computing 101
Intuition, fundamentals, engineering
Harshal G. Hayatnagarkar
Note
All images are used for illustration purpose only. Copyrights are reserved with their respective owners.
What could we cover?
 Nature of computing
 Nature of programming languages, role of compilers/interpreters, etc.
 Advanced concepts in computing
 Data and task parallel computing
 Distributed computing
 Accelerated computing
 
 Science and engineering of computing
 Computer Hardware and Software engineering
 Delivery processes
 Research and Development processes
Definition of Computing
"In a general way, we can define computing to mean any goal-oriented activity
requiring, benefiting from, or creating computers. Thus, computing includes
designing and building hardware and software systems for a wide range of
purposes; processing, structuring, and managing various kinds of information;
doing scientific studies using computers; making computer systems behave
intelligently; creating and using communications and entertainment media; finding
and gathering information relevant to any particular purpose, and so on. The list is
virtually endless, and the possibilities are vast." - The ACM Computing Curricula
2005 and 2020 (Wikipedia)
Definition of Computing
"In a general way, we can define computing to mean any goal-oriented activity requiring, benefiting from, or creating computers. Thus, computing includes
designing and building hardware and software systems for a wide range of purposes; processing, structuring, and managing various kinds of information;
doing scientific studies using computers; making computer systems behave intelligently; creating and using communications and entertainment media;
finding and gathering information relevant to any particular purpose, and so on. The list is virtually endless, and the possibilities are vast." - The ACM
Computing Curricula 2005 and 2020 (Wikipedia)
A function transforming a structured input into a structured
output by using methods of counting
f y
x y = f(x)
But before we move on, lets make a tea first !!
Lets make some tea...
1. Make tea
2. Serve it
It will make a tea, wont it?
Lets make some tea...
1. Make tea
2. Serve it
It will make a tea, wont it?
1. Take water
2. Add sugar
3. Add tea powder
4. Boil
5. Serve
Lets make some tea...
1. Make tea
2. Serve it
It will make a tea, wont it?
1. Take water
2. Add sugar
3. Add tea powder
4. Boil
5. Serve
1. Take metal utensil
2. Pour 75ml water into it
3. Add 2 tb of sugar
4. Add 1 ts of tea powder
5. Switch on a stove
burner
6. Put metal utensil on it
7. Let the water boil
8. Switch off the burner
9. Take a tea cup
10. Put a filter on the tea
cup
11. Pour the tea
12. Serve
Making tea seems like an awful amount of work.
Tea, tea, tea !!
 Without sugar
 Black tea
 Black tea with lime
 Black tea with lime and honey
 Tea fusion
 Green tea
 Tapri Chai
 Tapri Chai with Ginger
 Tapri Chai with Ginger and Elaichi
 Masala Chai
Lets make some tea, coffee, chocolate...
 Beverages for a group of people
 Its peak winter. (here is a clue)
 2 diabetes friendly cups (hidden knowledge = no sugar)
 1 cup for someone with cough and cold (hidden knowledge = with ginger)
 1 cup for a child with a sweet tooth (hidden knowledge = chocolate + extra sugar)
 1 person is vegan (hidden knowledge = no milk and honey)
 1 person is allergic to cocoa (hidden knowledge = chocolate contains cocoa)
 Domain knowledge
 No milk in green tea
 No sugar for diabetic people
 Coffee often does not need filtering
 Tea bags
 Vegans prefer non-dairy substitutes
Cooking beyond tea and beverages
 Cuisines: Chinese, Continental, Indian, etc.
 Cuisines as bundles of shared domain knowledge
 Common ingredients
 Protocols: Based on external factors such as seasons, people, ceremonies, etc.
 Processes: Cooking, serving, eating (E.g. soup first and desert last, dal + roti, fork + spoon)
 Quality control for safety, authentic taste, cleanliness, timeliness, wastage reduction
 All this needs to be described somewhere as manuals of standard
operating procedures so that anyone can follow up
Running a restaurant
 Far more complex than cooking at home
 Waiters End: Waiting for customers, arranging a table,
showing menu, suggesting menus, taking an order,
queuing it, delivering it to right table, billing the
customer, quality control, and Service with a smile
 Kitchens End: Receiving orders, preparing food
(sometimes with customization), collating all items
together, calling waiters, and coordinating with
customers, and quality control
 Warehouses End: Planning for raw materials, cold and
regular storage, quality control
 Managements End: Running the show, tactical and
strategic
Information everywhere...
 Structures and processes
 For example
 Structure: Order  table #, people, food items, quantity,
customizations),
 Structure: Menu  Soups, entries, deserts, beverages (hot & cold),
 Process: Cooking  Ingredients, steps, equipments
 Process: Pest control  Frequency, before and after steps,
coordination
 Together gives rise to Descriptive Complexity
Tea and the problem of descriptive complexity
 What is a Tea?
 What are types of teas?
 How to make each type of tea?
Descriptive complexity
 Description of structure and processes
 Variations of types and subtypes
 Implications of variations
 Spatial, temporal, and people contexts
 Tracking defects, improvements, evolution
 Precise with decisions and repetitions
 If X then Y
 Do X until Y
 Inferences
 For human and machine actors
 Human and machine interoperable
 Interaction protocols: Communication,
coordination, escalation
 Language for interaction
 Quality
Role of computing
is to explicitly capture
this descriptive complexity.
Descriptive complexity
 Description of structure and processes
 Variations of types and subtypes  Taxonomy, meronomy, ontologies  Set theory
 Implications of variations  Causal relationships  Set theory
 Spatial, temporal, and people contexts  Set theory, linear algebra, dynamical systems, logic
 Tracking defects, improvements, evolution  Set theory, graph theory, logic
 Precise with decisions and repetitions
 If X then Y  Logic (boolean algebra)
 Do X until Y  Graph theory
 Inferences  First order logic, higher order logic
 For human and machine actors
 Human and machine interoperable
 Interaction protocols: Communication, coordination, escalation
 Language for interaction
 Quality
Computing 101   an imperfect introduction to computing using cooking analogy
Parallels between cooking and coding
Definition of Computing
"In a general way, we can define computing to mean any goal-oriented activity requiring, benefiting from, or creating computers. Thus, computing includes
designing and building hardware and software systems for a wide range of purposes; processing, structuring, and managing various kinds of information;
doing scientific studies using computers; making computer systems behave intelligently; creating and using communications and entertainment media;
finding and gathering information relevant to any particular purpose, and so on. The list is virtually endless, and the possibilities are vast." - The ACM
Computing Curricula 2005 and 2020 (Wikipedia)
A function transforming a structured input into a
structured output by using methods of counting
f y
x y = f(x)
Definition of Computing
A function transforming a structured input into a
structured output by using methods of counting
f = recipe y = tea
x = [water,
sugar, tea
powder,
milk]
y = f(x)
Definition of Computing
A function transforming a structured input into a
structured output by using methods of counting
f = algorithm
y = output
with
structure
x = input
with
structure
y = f(x)
Structure = Data Structure
Transformation function = Algorithm
Taxonomy = Classification = Object-orientation
Beverages
Hot Cold
Buttermilk
Milkshake
Coffee
Tea
Strawberry
Mango
Green Tea
Ginger Tea Chocolate
Coding some recipes
1. Take metal utensil
2. Pour 75ml water into it
3. Add 1 tb of sugar if not diabetic
4. Add 2 ts of tea powder
5. Switch on a stove burner
6. Put metal utensil on it
7. Let the water boil
8. Switch off the burner
9. Take a tea cup
10.Put a filter on the tea cup
11.Pour the tea
12.Call waiter to serve
If condition
Loop
Function call / delegation
Variable
Programming languages, Compilers, Interpreters
Process: Clean code
Version Control
Tasting and testing
Data Structures: Requirements for Storage and Retrieval
Data Structures: Hierarchical Storage
Pre-computations
Modularity, composability, reusability
Application versus Framework versus Library
Patterns, and pattern languages
Cuisine as a pattern language  Cooking, serving, eating
Software patterns  Designing, developing, testing, deploying
Parallel Computing: Task Parallel (Single Core)
Parallel Computing: Data Parallel (Single Core)
Single Instruction Multiple Data
(SIMD)
Observe that
beans are aligned,
and have almost
similar length.
Ditto for vector
processing in
computers where
data should be
byte-aligned and
of similar lengths.
Parallel Computing: Data/Task Parallelism - Multicore
Scaling: Up versus Out
Scale Up
Making a kitchen, bigger
Adding more chefs to a
kitchen
Scale Out
Adding more kitchens
Scaling Hazards: (Too many cooks...)
Communication, Coordination,
Collaboration
 Race conditions, deadlocks,
overheads
Imagine designing a kitchen/kitchens with 100,000 chefs
What could be the problems?
With scale, everything changes !!
At scale, Cooking Becomes Food Processing
With scale, everything changes !!
Tasting at scale : Food processing
Implicit model of quality Explicit model of quality
Testing Software
Micro Macro
With scale : Large-scale software deployments
 Safety + Quality + Quantity + Efficiency + Profit is the combined goal.
 Process matters first and the most.
 Precision matters next, the second.
 Automation matters next, the third.
 Planning and metrics everywhere
 Humans and machines share an environment
Engineering for scale
Systems Thinking
We live in a data-driven world !
Hazards of scaling
Service-Product Dichotomy
How to differentiate?
How to differentiate?
Packaging  UI/UX
Nutrients  Business value
Cost  Productivity, efficiency
All of these need R&D !!
R&D Goals
 Innovating products/services
 Improving quality of processes: Safer,
efficient, quicker, less waste, cheaper
 Integrating field experience:
Customer feedback, new trends in
markets, fusion, differentiation
 Process innovation: Take-home, drive
through, online delivery, community
kitchen, donating leftover edible food,
waste disposal
 Trade off assessment: Many v/s fewer
menu items, buffet v/s a la carte, etc.
Technology as a differentiator
Lets Cook Some Code !!
Thank you !
Questions ?

More Related Content

Computing 101 an imperfect introduction to computing using cooking analogy

  • 1. Computing 101 Intuition, fundamentals, engineering Harshal G. Hayatnagarkar Note All images are used for illustration purpose only. Copyrights are reserved with their respective owners.
  • 2. What could we cover? Nature of computing Nature of programming languages, role of compilers/interpreters, etc. Advanced concepts in computing Data and task parallel computing Distributed computing Accelerated computing Science and engineering of computing Computer Hardware and Software engineering Delivery processes Research and Development processes
  • 3. Definition of Computing "In a general way, we can define computing to mean any goal-oriented activity requiring, benefiting from, or creating computers. Thus, computing includes designing and building hardware and software systems for a wide range of purposes; processing, structuring, and managing various kinds of information; doing scientific studies using computers; making computer systems behave intelligently; creating and using communications and entertainment media; finding and gathering information relevant to any particular purpose, and so on. The list is virtually endless, and the possibilities are vast." - The ACM Computing Curricula 2005 and 2020 (Wikipedia)
  • 4. Definition of Computing "In a general way, we can define computing to mean any goal-oriented activity requiring, benefiting from, or creating computers. Thus, computing includes designing and building hardware and software systems for a wide range of purposes; processing, structuring, and managing various kinds of information; doing scientific studies using computers; making computer systems behave intelligently; creating and using communications and entertainment media; finding and gathering information relevant to any particular purpose, and so on. The list is virtually endless, and the possibilities are vast." - The ACM Computing Curricula 2005 and 2020 (Wikipedia) A function transforming a structured input into a structured output by using methods of counting f y x y = f(x)
  • 5. But before we move on, lets make a tea first !!
  • 6. Lets make some tea... 1. Make tea 2. Serve it It will make a tea, wont it?
  • 7. Lets make some tea... 1. Make tea 2. Serve it It will make a tea, wont it? 1. Take water 2. Add sugar 3. Add tea powder 4. Boil 5. Serve
  • 8. Lets make some tea... 1. Make tea 2. Serve it It will make a tea, wont it? 1. Take water 2. Add sugar 3. Add tea powder 4. Boil 5. Serve 1. Take metal utensil 2. Pour 75ml water into it 3. Add 2 tb of sugar 4. Add 1 ts of tea powder 5. Switch on a stove burner 6. Put metal utensil on it 7. Let the water boil 8. Switch off the burner 9. Take a tea cup 10. Put a filter on the tea cup 11. Pour the tea 12. Serve
  • 9. Making tea seems like an awful amount of work.
  • 10. Tea, tea, tea !! Without sugar Black tea Black tea with lime Black tea with lime and honey Tea fusion Green tea Tapri Chai Tapri Chai with Ginger Tapri Chai with Ginger and Elaichi Masala Chai
  • 11. Lets make some tea, coffee, chocolate... Beverages for a group of people Its peak winter. (here is a clue) 2 diabetes friendly cups (hidden knowledge = no sugar) 1 cup for someone with cough and cold (hidden knowledge = with ginger) 1 cup for a child with a sweet tooth (hidden knowledge = chocolate + extra sugar) 1 person is vegan (hidden knowledge = no milk and honey) 1 person is allergic to cocoa (hidden knowledge = chocolate contains cocoa) Domain knowledge No milk in green tea No sugar for diabetic people Coffee often does not need filtering Tea bags Vegans prefer non-dairy substitutes
  • 12. Cooking beyond tea and beverages Cuisines: Chinese, Continental, Indian, etc. Cuisines as bundles of shared domain knowledge Common ingredients Protocols: Based on external factors such as seasons, people, ceremonies, etc. Processes: Cooking, serving, eating (E.g. soup first and desert last, dal + roti, fork + spoon) Quality control for safety, authentic taste, cleanliness, timeliness, wastage reduction All this needs to be described somewhere as manuals of standard operating procedures so that anyone can follow up
  • 13. Running a restaurant Far more complex than cooking at home Waiters End: Waiting for customers, arranging a table, showing menu, suggesting menus, taking an order, queuing it, delivering it to right table, billing the customer, quality control, and Service with a smile Kitchens End: Receiving orders, preparing food (sometimes with customization), collating all items together, calling waiters, and coordinating with customers, and quality control Warehouses End: Planning for raw materials, cold and regular storage, quality control Managements End: Running the show, tactical and strategic
  • 14. Information everywhere... Structures and processes For example Structure: Order table #, people, food items, quantity, customizations), Structure: Menu Soups, entries, deserts, beverages (hot & cold), Process: Cooking Ingredients, steps, equipments Process: Pest control Frequency, before and after steps, coordination Together gives rise to Descriptive Complexity
  • 15. Tea and the problem of descriptive complexity What is a Tea? What are types of teas? How to make each type of tea?
  • 16. Descriptive complexity Description of structure and processes Variations of types and subtypes Implications of variations Spatial, temporal, and people contexts Tracking defects, improvements, evolution Precise with decisions and repetitions If X then Y Do X until Y Inferences For human and machine actors Human and machine interoperable Interaction protocols: Communication, coordination, escalation Language for interaction Quality
  • 17. Role of computing is to explicitly capture this descriptive complexity.
  • 18. Descriptive complexity Description of structure and processes Variations of types and subtypes Taxonomy, meronomy, ontologies Set theory Implications of variations Causal relationships Set theory Spatial, temporal, and people contexts Set theory, linear algebra, dynamical systems, logic Tracking defects, improvements, evolution Set theory, graph theory, logic Precise with decisions and repetitions If X then Y Logic (boolean algebra) Do X until Y Graph theory Inferences First order logic, higher order logic For human and machine actors Human and machine interoperable Interaction protocols: Communication, coordination, escalation Language for interaction Quality
  • 21. Definition of Computing "In a general way, we can define computing to mean any goal-oriented activity requiring, benefiting from, or creating computers. Thus, computing includes designing and building hardware and software systems for a wide range of purposes; processing, structuring, and managing various kinds of information; doing scientific studies using computers; making computer systems behave intelligently; creating and using communications and entertainment media; finding and gathering information relevant to any particular purpose, and so on. The list is virtually endless, and the possibilities are vast." - The ACM Computing Curricula 2005 and 2020 (Wikipedia) A function transforming a structured input into a structured output by using methods of counting f y x y = f(x)
  • 22. Definition of Computing A function transforming a structured input into a structured output by using methods of counting f = recipe y = tea x = [water, sugar, tea powder, milk] y = f(x)
  • 23. Definition of Computing A function transforming a structured input into a structured output by using methods of counting f = algorithm y = output with structure x = input with structure y = f(x) Structure = Data Structure Transformation function = Algorithm
  • 24. Taxonomy = Classification = Object-orientation Beverages Hot Cold Buttermilk Milkshake Coffee Tea Strawberry Mango Green Tea Ginger Tea Chocolate
  • 25. Coding some recipes 1. Take metal utensil 2. Pour 75ml water into it 3. Add 1 tb of sugar if not diabetic 4. Add 2 ts of tea powder 5. Switch on a stove burner 6. Put metal utensil on it 7. Let the water boil 8. Switch off the burner 9. Take a tea cup 10.Put a filter on the tea cup 11.Pour the tea 12.Call waiter to serve If condition Loop Function call / delegation Variable
  • 30. Data Structures: Requirements for Storage and Retrieval
  • 35. Patterns, and pattern languages Cuisine as a pattern language Cooking, serving, eating Software patterns Designing, developing, testing, deploying
  • 36. Parallel Computing: Task Parallel (Single Core)
  • 37. Parallel Computing: Data Parallel (Single Core) Single Instruction Multiple Data (SIMD) Observe that beans are aligned, and have almost similar length. Ditto for vector processing in computers where data should be byte-aligned and of similar lengths.
  • 38. Parallel Computing: Data/Task Parallelism - Multicore
  • 39. Scaling: Up versus Out Scale Up Making a kitchen, bigger Adding more chefs to a kitchen Scale Out Adding more kitchens
  • 40. Scaling Hazards: (Too many cooks...) Communication, Coordination, Collaboration Race conditions, deadlocks, overheads
  • 41. Imagine designing a kitchen/kitchens with 100,000 chefs What could be the problems?
  • 43. At scale, Cooking Becomes Food Processing
  • 45. Tasting at scale : Food processing Implicit model of quality Explicit model of quality
  • 47. With scale : Large-scale software deployments
  • 48. Safety + Quality + Quantity + Efficiency + Profit is the combined goal. Process matters first and the most. Precision matters next, the second. Automation matters next, the third. Planning and metrics everywhere Humans and machines share an environment Engineering for scale
  • 50. We live in a data-driven world !
  • 54. How to differentiate? Packaging UI/UX Nutrients Business value Cost Productivity, efficiency All of these need R&D !!
  • 55. R&D Goals Innovating products/services Improving quality of processes: Safer, efficient, quicker, less waste, cheaper Integrating field experience: Customer feedback, new trends in markets, fusion, differentiation Process innovation: Take-home, drive through, online delivery, community kitchen, donating leftover edible food, waste disposal Trade off assessment: Many v/s fewer menu items, buffet v/s a la carte, etc.
  • 56. Technology as a differentiator
  • 57. Lets Cook Some Code !! Thank you ! Questions ?

Editor's Notes

  • #2: I promise that by the end of this session, you will be hungry, food or knowledge, or both.