0% found this document useful (0 votes)
82 views22 pages

Computer Skills Advanced Algorithmic Problem Solving

This document discusses algorithmic problem solving and formalizing problems symbolically. It introduces flow diagrams and natural language descriptions as ways to represent problems symbolically. Flow diagrams use blocks, arrows, and decisions to visually depict a process from start to end. Natural language can describe processes top-down or down-top. Examples of flow diagrams calculating simple math problems and depicting a business service process are provided.

Uploaded by

David
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
82 views22 pages

Computer Skills Advanced Algorithmic Problem Solving

This document discusses algorithmic problem solving and formalizing problems symbolically. It introduces flow diagrams and natural language descriptions as ways to represent problems symbolically. Flow diagrams use blocks, arrows, and decisions to visually depict a process from start to end. Natural language can describe processes top-down or down-top. Examples of flow diagrams calculating simple math problems and depicting a business service process are provided.

Uploaded by

David
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 22

Computer skills advanced

algorithmic problem solving

Prof. Raffaella FOLGIERI


DEMM, Department of Economics, Management and quantitative Methods
aa 2015/2016
Prof. Raffaella Folgieri  Algorithmic Problem solving
• The Problem solving coincide in this case with the
approach to the research of the solution of the
problem through definite steps: algorithmic thinking
• Born of the symbolic expression of a problem (Al
Waritzsmi, Arabian mathematician)
• Solution flow = algorithm
• Different symbolic representations:
• Flow diagram (diagramma a blocchi)
• Top‐down, down‐top
• UML
Prof. Raffaella Folgieri  A metaphor
• Also in this case it is important to specify clearly the
requirements of the problem
• Telephone without threads, a game played in the middle of '900
(when all the telephones had threads)
– The game is simple. A queue or a circle of children.
– The first child tells a sentence in the ear of the following child
who do the same with the following one and so on. The last
child in the queue must declare the sentence. Usually the last
sentence is quite different from the first.
• The management of requirements works in a similar way. More the
chain between the need and the solution is long, greater is the
probability to misunderstand the requirements.
• It is important to formalize the problem to obtain
– Consensus
– Efficient communication
– Correct translation of the problem into a solution algorithm
– Validation of the result
Prof. Raffaella Folgieri  Economic models
• Application of mathematics in economics
– After the second world war
– The operational research (ricerca operativa)
assumed a specific physiognomy, as a special field of
applied research. Some people from the R.A.F.,
English Royal Air Force, constituted a research group
to study optimal systems for attack and defence –
the so called "Blackett club" (“Circolo Blackett”)
from the name of the scientist directing it.
– Today the operational research is used to solve
organizational problems in many fields.
Prof. Raffaella Folgieri  Formalization
• An algorithm translates the formalization of a
problem
• Formalizing a problem means:
• Find a symbolic representation

A business process is the centre of the activities of


a company… business logic
• We will see some simple symbolic representations
(for general purposes, very used in IT and in
business field)
– Flow diagram (Schema a blocchi)
– Top-down, down-top (natural language)
Prof. Raffaella Folgieri  Flow diagram – blocks and instructions

End or start

Flow control

Process steps (instructions/commands)

Input/output

Decisions (control instructions)


Prof. Raffaella Folgieri  Flow diagram – rules
No arrows enter in START and no arrows exit
from the END

In each INSTRUCTION block one arrow can


enter and one arrow can exit

In each DECISION block one arrow enters and


two arrows exit.

 Almost a path from START to END must exist
Prof. Raffaella Folgieri  non-standard flow diagram

Alternative elaboration
Document
Multiple documents
Manual input
Manual operation
Saved data
Magnetic disk (data
support/database)
Prof. Raffaella Folgieri  Flow diagram – example1

Sum of first n natural


numbers, whith n=50

(1275)
Prof. Raffaella Folgieri  Flow diagram – example2

Variation with temporal indication


Prof. Raffaella Folgieri  Flow diagram – example 3

• Schemata of a
business service
• Users (use cases) have
been added
Prof. Raffaella Folgieri  Natural language
• The flow diagram (flowchart) is a simply way to scheme
problems
• Another way (also used to analyse problems) is based on the
use of natural language, describing the solution
problem/process following the models:
– Top-down (decomposing the main problem in simple sub-
problems)
– Down-top (starting from the bottom)
Prof. Raffaella Folgieri 

Do not confuse these terms with the financial 
ones:
Top down strategy. Investment strategy 
allowing to individuate sectors and industries 
from which we expect a good performance. 

Bottom‐up approach
the investor concentrate the attention of a
specific company  instead of the sector in 
which the company operates or on the 
economy in its complex.
Prof. Raffaella Folgieri  Tools to implement the methodologies

Some (not all):


• MS Visio
• Business Object (SAP)
• Various Case tools
• Many free softwares (search "flow diagram" or
"business logic" on the Internet)
see, for example, draw.io: https://
www.draw.io/
Prof. Raffaella Folgieri  Example: flow diagram to calculate the PIL (Y)
C = consumptions
START I = private investments
G = public expense
Only the 
NX = net export
Nominal PIL formula: NO YES Nominal PIL:
nominal
Y = C + I + G + NX Y = C + I + G + NX
PIL?

Input YEAR and PRICE  Output 
LEVEL per year Nominal PIL

Calculate components:
C/Prices level
numerically Data  graphically
I/Prices level
G/Prices level presentation
NX/Prices level

Real PIL calculus: Conditional
PIE
Sum of components formatting

Output Real 
PIL
END

Now we can translate the diagram into an algorithm (for example using formulas in Excel)
Prof. Raffaella Folgieri 

ejoy flowcharts...
the friendship algorhythm:
https://www.youtube.com/watch?
v=k0xgjUhEG3U
Computer skills advanced
problem solving and computational
thinking

Prof. Raffaella FOLGIERI


DEMM, Department of Economics, Management and quantitative Methods
aa 2013/2014
Prof. Raffaella Folgieri  Computational thinking (1)
• New problem solving paradigm
• It takes its name from the extensive use of 
techniques from computer science
• The term computational thinking has been used 
for the first time by Seymour Papert (a 
mathematician at MIT) in 1996
• The method can be used algorithmically to 
solve scale problems realizing strong 
improvements in efficiency
Prof. Raffaella Folgieri  Computational thinking (2)
• Applied to all the disciplines
• Adopted by the scientific community after a 
famous article written by Jeannette M. Wing 
(computer science professor at Carnegie Mellon 
University)
• The paper suggests that it is a fundamental skill 
for all the people and not only for computer 
science scientists, and underlines the 
importance to integrate it with other 
disciplines.
Prof. Raffaella Folgieri  The Centre for the Computational thinking

• At the Carnegie Mellon University.
• Main activity: PROBEs (PROBlem‐oriented 
Explorations), application of new concepts of 
the computational thinking to different 
disciplines.

• The centre’s website: 
http://www.cs.cmu.edu/~CompThink/
Prof. Raffaella Folgieri  Computational thinking characteristics
The problem solving process is characterized by:
• Analysis and logical organization of data (data 
modelling and data abstraction) and simulations
• Formulating problems to which a PC can give 
support
• Identification, test and implementation of possible 
solutions
• Automation of solution through the algorithmic 
thinking
• Generalization and application of this process to 
other problems
Prof. Raffaella Folgieri  Computational thinking: web references
• Resources (particularly in social science):
http://education.sdsc.edu/resources/CompThinking.pdf
• University of Eindburg, computational thinking:
http://www.inf.ed.ac.uk/research/programmes/comp‐think/
(especially http://www.inf.ed.ac.uk/research/programmes/comp‐
think/previous.html )
• Wing’s paper: 
http://www.cs.cmu.edu/afs/cs/usr/wing/www/publications/
Wing06.pdf
• Try to explore the computational thinking with Google: 
http://www.google.com/edu/computational‐thinking/
• Based on computational thinking principles:
http://scalablegamedesign.cs.colorado.edu/wiki/Scalable_Game_Design_wi
ki (scalable game design)
http://www.cs4fn.org/ (computer science for fun)
http://www.ncwit.org/unplugged (computer science in a box)

You might also like