more financial formulas
solver (2 examples)
1) take nominal rate (APR) and divide it by freq for year. (e.g., if compounds monthly, divide by 12). that is called the periodic effective rate.
2) calculate: (1 + PeriodicEffectiveRate)^NPER - 1. that is called the annual effective rate
quiz up to this point
next time:
back to invoice
pivottable and pivotchart
Wednesday, March 30, 2011
Monday, March 28, 2011
Wednesday, March 23, 2011
lecture
HW:
lecture book, exercise 2.9
start reading ch 3 in book.
index.html
how to copy local files to the remote machine, and vice versa
incorporating images in a web page
i used width and height attributes
i also "hotlinked"
that is not nice!
the web site might go down
they can take revenge by changing the image to something you don't want, embarrassing
how not to hotlink
equation for financial calculations
FV = PV * (1 + RATE) ^ NPER
we got up to and including example 9 in finance chapter
lecture book, exercise 2.9
start reading ch 3 in book.
index.html
how to copy local files to the remote machine, and vice versa
incorporating images in a web page
i used width and height attributes
i also "hotlinked"
that is not nice!
the web site might go down
they can take revenge by changing the image to something you don't want, embarrassing
how not to hotlink
equation for financial calculations
FV = PV * (1 + RATE) ^ NPER
we got up to and including example 9 in finance chapter
Monday, March 21, 2011
=3+A1
=SUM(), AVERAGE
quick intro to functions
WEB:
once you have successfully logged in
you need to create a folder called
public_html
then, you can create files inside that folder. i created hello.html
cs12.cs.qc.cuny.edu/~wajo6788/hello.html
note to self - it was called Invoice1.xlsx
Time value of money
money is worth more now than later
PV = present value
FV = future value
PV + PV * RATE
PV * ( 1 + RATE )
PV * ( 1 + RATE )
PV * ( 1 + RATE ) * ( 1+ RATE)
PV * ( 1 + RATE ) * ( 1+ RATE) *(1 + RATE)
FV = PV * (1 + RATE) ^ NPER
404 error
page does not exist
403 error
permissions not granted
=SUM(), AVERAGE
quick intro to functions
WEB:
once you have successfully logged in
you need to create a folder called
public_html
then, you can create files inside that folder. i created hello.html
cs12.cs.qc.cuny.edu/~wajo6788/hello.html
note to self - it was called Invoice1.xlsx
Time value of money
money is worth more now than later
PV = present value
FV = future value
PV + PV * RATE
PV * ( 1 + RATE )
PV * ( 1 + RATE )
PV * ( 1 + RATE ) * ( 1+ RATE)
PV * ( 1 + RATE ) * ( 1+ RATE) *(1 + RATE)
FV = PV * (1 + RATE) ^ NPER
404 error
page does not exist
403 error
permissions not granted
Wednesday, March 16, 2011
absolute vs. relative refs
excel seems to be smart
it modifies rows as appropriate
so too, cols
we don't like "magic numbers"
we want to isolate assumptions
relative refs automatically adjust
absolute references stay in place
absolute refs: use $
A1 style - what we;ve seen so far
R1C1 style - row number, column number
[] in R1C1 style mean offsets
by default, when you NAME a cell, it names
it as an absolute reference
debugging tools
things go wrong
"bug"
http://en.wikipedia.org/wiki/Grace_Hopper
Grace Hopper
first computer bug
"evaluate formula" tool
"trace precedents" tool
"trace dependents" tool
way of figuring out what is going wrong
excel seems to be smart
it modifies rows as appropriate
so too, cols
we don't like "magic numbers"
we want to isolate assumptions
relative refs automatically adjust
absolute references stay in place
absolute refs: use $
A1 style - what we;ve seen so far
R1C1 style - row number, column number
[] in R1C1 style mean offsets
by default, when you NAME a cell, it names
it as an absolute reference
debugging tools
things go wrong
"bug"
http://en.wikipedia.org/wiki/Grace_Hopper
Grace Hopper
first computer bug
"evaluate formula" tool
"trace precedents" tool
"trace dependents" tool
way of figuring out what is going wrong
Monday, March 14, 2011
http://cs12.cs.qc.cuny.edu/~joshwaxman
your webpage will be:
http://cs12.cs.qc.cuny.edu/~wajo4672
host name: cs12.cs.qc.cuny.edu
username (all lower-case):
First 2 letters of last name followed by
First 2 letters of first name followed by
Last 4 digits of CUNYFirst ID#
password: 8 digits of CUNYFirst ID#
need a program to log on to this computer
WINSCP if you have a PC
Fugu if you have a Mac
If you Google Search
WinSCP download
winscp.net/eng/download.php
HW: Try to download and install WINSCP
try to login using your credentials
If you have a Mac, Fugu
http://cs12.cs.qc.cuny.edu/~xiuyi/fugu.html
HW: the next two exercises in ch 2 in lecture book about HTML
2.7-2.8
Really, all websites are numbers
IP addresses
DNS - domain name system
http://en.wikipedia.org/wiki/Domain_Name_System
a phone book for the internet
http://123.45.2.90/chase.com/thisisreal/gimmeyourfinancialinfo.htm
http://0xff.0xab.0xca.0xab/chase.com/login
http://chase.info/login
http://chase-banking.com/login
You could Google Chase
http://scamsite.ru/chase.com/login
domain starts at the :// and ends at the first slash
you can use this to detect many scams
domain, subdomain
domain is REALLY just the last 2 elements of what we've called the domain so far.
subdomain is before this.
eniac.cs.qc.cuny.edu/~svitak/cs12/
why is this important?
http://chase.com.scamsite.ru/login
Phishing email
besides the URLs, misspellings, will not know your name.
http://www.snopes.com/
Also, check out Amazon student
your webpage will be:
http://cs12.cs.qc.cuny.edu/~wajo4672
host name: cs12.cs.qc.cuny.edu
username (all lower-case):
First 2 letters of last name followed by
First 2 letters of first name followed by
Last 4 digits of CUNYFirst ID#
password: 8 digits of CUNYFirst ID#
need a program to log on to this computer
WINSCP if you have a PC
Fugu if you have a Mac
If you Google Search
WinSCP download
winscp.net/eng/download.php
HW: Try to download and install WINSCP
try to login using your credentials
If you have a Mac, Fugu
http://cs12.cs.qc.cuny.edu/~xiuyi/fugu.html
HW: the next two exercises in ch 2 in lecture book about HTML
2.7-2.8
Really, all websites are numbers
IP addresses
DNS - domain name system
http://en.wikipedia.org/wiki/Domain_Name_System
a phone book for the internet
http://123.45.2.90/chase.com/thisisreal/gimmeyourfinancialinfo.htm
http://0xff.0xab.0xca.0xab/chase.com/login
http://chase.info/login
http://chase-banking.com/login
You could Google Chase
http://scamsite.ru/chase.com/login
domain starts at the :// and ends at the first slash
you can use this to detect many scams
domain, subdomain
domain is REALLY just the last 2 elements of what we've called the domain so far.
subdomain is before this.
eniac.cs.qc.cuny.edu/~svitak/cs12/
why is this important?
http://chase.com.scamsite.ru/login
Phishing email
besides the URLs, misspellings, will not know your name.
http://www.snopes.com/
Also, check out Amazon student
Wednesday, March 9, 2011
lecture
I haven't put up the assignments on Blackboard yet, so hold on to them.
For HW:
Ch 2 in lecture book, on HTML, exercises 2.4 to 2.6.
A list of hws so far:
1) binary conversions
2) lecture book, ch 1, review questions
3) lecture book, ch 2, exercises 2.1 to 2.3.
4) lecture book, ch 2, exercises 2.4 to 2.6.
http://www.w3schools.com/html/default.asp
early goal of HTML, they didn't stick to much: markup meaning, rather than formatting.
CSS - cascading style sheets
We finished "HTML Elements" on W3Schools
Excel
rows, col, cells
values
data types: number, text, logical, errors
formulas
always start =
operands can be values
operators such as +, -, /, *
order of operation
PEMDAS
Monday at 3:00 in adjunct room (A202?, right across from dept office)
For HW:
Ch 2 in lecture book, on HTML, exercises 2.4 to 2.6.
A list of hws so far:
1) binary conversions
2) lecture book, ch 1, review questions
3) lecture book, ch 2, exercises 2.1 to 2.3.
4) lecture book, ch 2, exercises 2.4 to 2.6.
http://www.w3schools.com/html/default.asp
early goal of HTML, they didn't stick to much: markup meaning, rather than formatting.
CSS - cascading style sheets
We finished "HTML Elements" on W3Schools
Excel
rows, col, cells
values
data types: number, text, logical, errors
formulas
always start =
operands can be values
operators such as +, -, /, *
order of operation
PEMDAS
Monday at 3:00 in adjunct room (A202?, right across from dept office)
Monday, March 7, 2011
lecture
algorithm - a recipe
search algorithms
Linear search vs. binary search
choose a good algorithm, because CPU speed can only go so far
Linear search - sequentially examine each element in collection, see if it is what you are looking for
int i = 0;
while(A[i] != 6)
{
i = i + 1;
}
if (A[i] == 6)
cout << "We found it at position " << i;
else
cout << "Sorry, we did not find it";
Analysis of Algorithms
Euler's rule
sum of:
1 + 2 + 3 ..... + n
(n+1) * (n/2) =
(n^2 + n) / 2
divide by n
about n
on the order of n
O(n)
What if the numbers are sorted?
we can use binary search.
is O(log n)
log base 2 of n
1 million elements in my collection
in linear search, about 1 million operations
in binary search, about 20 operations
Computers cannot do everything
http://www.claymath.org/millennium/
Traveling salesman problem
not solvable in amount of time we have
using algorithm i described
next quiz next wednesday
search algorithms
Linear search vs. binary search
choose a good algorithm, because CPU speed can only go so far
Linear search - sequentially examine each element in collection, see if it is what you are looking for
int i = 0;
while(A[i] != 6)
{
i = i + 1;
}
if (A[i] == 6)
cout << "We found it at position " << i;
else
cout << "Sorry, we did not find it";
Analysis of Algorithms
Euler's rule
sum of:
1 + 2 + 3 ..... + n
(n+1) * (n/2) =
(n^2 + n) / 2
divide by n
about n
on the order of n
O(n)
What if the numbers are sorted?
we can use binary search.
is O(log n)
log base 2 of n
1 million elements in my collection
in linear search, about 1 million operations
in binary search, about 20 operations
Computers cannot do everything
http://www.claymath.org/millennium/
Traveling salesman problem
not solvable in amount of time we have
using algorithm i described
next quiz next wednesday
Wednesday, March 2, 2011
how to encode:
numbers
characters
now, pixels
picture element
2 color bitmap. L x W / 8
because only need 1 bit per pixel
16 colors
2^4 = 16
so we need four bits for each pixel
four bits = 1/2 byte
300 across x 200 down = 60,000 pixels
so, 30 bytes are necessary
256 colors.
2^8 = 256
so, need 1 byte per 1 pixel
60,000
24-bit bitmap = "True color" = 3 bytes per pixel
180,000
store RGB values
16,777,216 possible values
this was for .BMP files that you do this kind of mult to find the size
hexadecimal specification of color
#99 ff 00
RLE
run-length encoding
http://en.wikipedia.org/wiki/Run-length_encoding
GIF uses LZW encoding, which is a different encoding scheme. specifics, you don't need to know
lossless compression - GIF
don't lose info
lossy compression - JPG
loses info every time you save
raster vs. vector graphics
http://en.wikipedia.org/wiki/Raster_graphics
http://en.wikipedia.org/wiki/Vector_graphics
http://en.wikipedia.org/wiki/SVG
numbers
characters
now, pixels
picture element
2 color bitmap. L x W / 8
because only need 1 bit per pixel
16 colors
2^4 = 16
so we need four bits for each pixel
four bits = 1/2 byte
300 across x 200 down = 60,000 pixels
so, 30 bytes are necessary
256 colors.
2^8 = 256
so, need 1 byte per 1 pixel
60,000
24-bit bitmap = "True color" = 3 bytes per pixel
180,000
store RGB values
16,777,216 possible values
this was for .BMP files that you do this kind of mult to find the size
hexadecimal specification of color
#99 ff 00
RLE
run-length encoding
http://en.wikipedia.org/wiki/Run-length_encoding
GIF uses LZW encoding, which is a different encoding scheme. specifics, you don't need to know
lossless compression - GIF
don't lose info
lossy compression - JPG
loses info every time you save
raster vs. vector graphics
http://en.wikipedia.org/wiki/Raster_graphics
http://en.wikipedia.org/wiki/Vector_graphics
http://en.wikipedia.org/wiki/SVG
Subscribe to:
Posts (Atom)