KMaps

KMaps help us simplify algebraic functions.

The following helps us simplify:
!ABC+ !AB!C + ABC + A!B!C = X

First we can make a truth table:

A B C  X
0 0 0  0
0 0 1  0
0 1 0  1
0 1 1  1
1 0 0  1
1 0 1  0
1 1 0  0
1 1 1  1

kmapexample

 

Posted in CSIT 2860 Notes | Comments Off on KMaps

Queries?

It seems that everything has become progressively busier since starting this blog. I write class notes still, saving them as .txt files to later be formatted and synthesized into meaningful content for this blog.
Unfortunately, that process of editing has required too much, and I have fallen behind in posting.

Additionally, lab classes involve files and information beyond those .txt class notes- requiring further work to try to either recreate or import them into this blog.

If anyone in this audience has questions about a particular topic I cover, I urge you to email me with your questions. This will help make my writing relevant.

Posted in Announcements | Comments Off on Queries?

CSIT 1520:11

Graphics (Chapter 15)
2/22/2012

Java Coordinate System
For any given component, the top left most pixel has the coordinate values of (0,0).
There are therefore no negative coordinate values.

Rectangles and ovals are drawn by specifying width and height.

A circle is just an oval with equal width and height.

Strings are drawn by specifying name of the String and starting coordinate.

FontMetrics can return width and height of a String.

Polygon is closed (all sides touch to make a closed shape).

e.g.
/*polygon is just a series of coordinated being connected with line segments, so we must add coordinate points to make a polygon*/
p.addPoint(20,30);
/*it is better to put your coordinate values into arrays*/
int[] xValues = {20,40,60,80,100};
int[] yValues = {10,20,30,40,50};
/*then, when you declare the polygon, do so with the arrays as arguments: Polygon(int[] xpoints, int[] ypoints, int npoints), npoints being however many points exist for the polygon, which is just the length of one of the arrays of coordinate values*/
Polygon p = new Polygon(xValues, yValues, xValues.length);

Polyline is unbounded (the chain of line segments is left open).

 

Posted in CSIT 1520 Notes | Comments Off on CSIT 1520:11

Supersets and Subsets

Given the above diagram, it can be said that

  • A is a superset of D
  • D is a subset of A
  • A and B are a supersets of C
  • C is a subset of A and B
Posted in Bibliotheka | Comments Off on Supersets and Subsets

Math1530:15

March 28 & 29, 2012

Rare Event Rule

 for any assumption, if the probability of the observed event is small, we conclude that the assumption is probably incorrect
 

μ(p̂) = p

σ(p̂) = sqrt((p * q) / n)

z = p̂ – p / sqrt((p * q) / n)

 
null hypothesis (H0)- parameter is equal to claimed value
alternative hypothesis (H1)- parameter is different from claimed value

test statistic within critical region, reject H0
else, if test statistic doesn’t fall in critical region, it fails to reject H0

When claim is [>], alternative hypothesis is [>]
> : >
< : <
= : !=
!= : !=
<= : >
>= : <

test statistics

for proportion
z = (p̂ – p) / sqrt((p*q) / n)

for mean
t = xbar – μ / (s / sqrt(n))

significant level (α)
probability that test statistic will fall in critical region when null hypothesis is true

Posted in Math 1530 Notes | Comments Off on Math1530:15

Math1530:14

This all occurs in a normal distribution.

Confidence Level

7-2

To find proportion…

binomial- of the sample, there are either successes or not successes (whatever attribute a success may be such as boy, girl, heads, tails, Economics Major, etc.)

sample size: n
number of successes: x
point estimate: p^ = x/n
Z(α/2) = z-score of the two tails
margin of error: E = Z(α/2) * sqrt((p^ * q^) / n)
interval estimate: p^ +/-  E

7-4

To find range in which population mean is likely to be…

population standard deviation: σ (of sample = σ / sqrt(n))
population mean: μ
sample mean, point estimate: xbar
sample size: n
sample standard deviation: s
t(α/2) = t-value of two-tailed distribution found under (1 – confidence level) on table A-3
degree of freedom: df = n – 1
Margin of Error: E = t(α/2) * s/sqrt(n)
interval estimate: xbar +/- E

has different shape with different degree of freedom

 

 

Posted in Math 1530 Notes | Comments Off on Math1530:14

Swapping Two Variables Without a Third

This is how to swap two variables without introducing a third variable.

a=a+b;
b=a-b;
a=a-b;

 

e.g.

given a = 2 and b = 3
a = 2 + 3   (i.e. a = a + b)
(a = 5)

b = 5 – 3 (i.e. b = a – b)
(b = 2)

a = 5 – 2 (i.e. a = a – b)
(a = 3)

 

Now a, which was originally 2, is now 3. Likewise, b, originally 3, is now 2.

Posted in Programming General | Comments Off on Swapping Two Variables Without a Third

Math1530:13

March 1, 2012

For a Normal Distribution,

    • your total area is 1, and probability can be found of a given value (x) by finding the accumulative area up to x on the x-axis
    • if your mean is not 0 and your standard deviation is not 1,
      • your z-score is not x
        • to find z-score, subtract the mean (μ) from your given value on the x-axis (x) and divide the difference by the standard deviation (σ).

tl;dr

when μ != 0 && σ != 1,

z-score = x – μ / σ

Posted in Math 1530 Notes | Comments Off on Math1530:13

Abstract Method Override

Don’t forget: if you use an abstract class, all the abstract methods must be implemented in the subclass.

Posted in CSIT 1520 Notes | Comments Off on Abstract Method Override

Math1530:12

February 28, 2012

Density Curve
graph of continuous probability distribution

    • total area under curve = 1
    • every point on the curve must have vertical weight that is 0 or greater

 

i.e. cannot fall below the x-axis

Because total area under curve = 1, there is correspondence between probability and area

Standard Normal Distribution
normal probability distribution with mean of 0 and standard deviation of 1
z-score
distance along horizontal scale of the standard normal distribution
area
region under the curve
total area = 1
to find area of region under the curve delineated by z-score, check the table
            each z-score has an associated area in a standard normal distribution

Posted in Math 1530 Notes | Comments Off on Math1530:12