computer-science

multiplicative inverse?!?!?

Hi, I know that an affine cipher substitutes BD with SG. I need to find the encryption formula, in the form y = a x + b, where a and b are coefficients. From the information above I end up having to equations: a+b=18 and 3a+b=6 So I am working like this: a+b=18 and 3a + b = 6-> 3a+18-a=6->  2a= 6-18 -> 2a=14 (cuz it is mod 26) b=18-a ...

Prime Factorization

I have recently been reading about the general use of prime factors within cryptography. Everywhere i read, it states that there is no 'PUBLISHED' algorithm which operates in polynomial time (as opposed to exponential time), to find the prime factors of a key. If an algorithm was discovered or published which did operate in polynomial t...

RSA cryptosystem

Hi i am trying to set up an RSA cryptosystem i have all the values except d selected prime numbers: p=1889, q=2003 n=3783667 phi=3779776 e= 61 i got stuck finding d could anyone help me to figure it out? Setting up an RSA cryptosystem • Two large distinct prime numbers p and q are selected, and n = pq and Φ(n) = (p − 1)(q − 1) are cal...

Which are practically unsolvable problems in programming world?

Travelling salesman problem is said to be practically "unsolvable" when number of nodes increase. What other programming problems that are considered unsolvable? ...

Worst case running time (Big O)

Hi every one. I have this question, and I don't know how to solve it, because I don't understand it. :( The question is: Programs A and B are analyzed and are found to have worst case running times no greater than 150n log n and n2, respectively. Answer the following questions: i) Which program has the better guarantee on...

Can this breadth-first search be made faster?

I have a data set which is a large unweighted cyclic graph The cycles occur in loops of about 5-6 paths. It consists of about 8000 nodes and each node has from 1-6 (usually about 4-5) connections. I'm doing single pair shortest path calculations and have implemented the following code to do a breadth-first search. from Queue import Queu...

How to create an ontology in python?

Are there libraries or certain "techniques" that you can use to create an ontology of elements? Or "design patterns"? I am talking about just a "graph" of things. Suppose I have a bunch of words. Certain words are "under" other words or "related" to other words. I need a good way to group them and know their relationship. ...

Implementation Detail for Graph Analysis Algorithms

Let's say I have a graph with "heavy" nodes, that is each node is an object that is already carrying a lot of data. I want to do a graph transformation that requires me to calculate a special property for each node. This property only needs to be remembered temporarily to apply the transformation. How can I store this property efficie...

How do you detect outliers on multivariate data?

I am trying to do a regression problem but I have 3 independent variables and not 1 so it is hard to detect outliers from a scatter graph. Any suggestions? ...

A phrase as catchy as 'Feature Creep' but for underestimated projects

I'm needing a term or established term to represent a phenomenon our company currently calls a 'Black Hole': a project that takes magnitudes longer than estimated, yet we're already sucked in and HAVE to see it through to completion. EDIT: Hoping that the best term will be voted up. ...

Morris Internet Worm - anyone knows how did they manage to stop it?

Hi there, yes, this is a homework-type question but could you please help me out? In a very short presentation on the topic of Morris Internet Worm I am supposed to list the steps taken to stop the worm from spreading. My pp slides are now approaching the final state, but before I go and say that this or that is how they stopped the wo...

What is an irrational number relevant to computer science?

For a project we're working on right now, we want to pull a Donald Knuth and have a version number that converged towards some irrational number. However, we don't want to use something boring like pi, e, sqrt(2), etc. Is there an irrational number that is particularly relevant to computer science that we could employ? ...

Exactly what is the difference between a "closure" and a "block"?

I've found that lots of people use the words closure and block interchangeably. Most of these people can't explain what they're talking about. Some Java programmers (even ones from really expensive consultancies) talk about anonymous inner classes as "blocks" and "closures" - but I know this isn't true. (You can't pass mutable variables...

What does the 'Enterprise Ready' mean?

What do you mean by saying that something is 'Enterprise Ready'? ...

Building a game, need a language with strongly supported first class functions

I'm building an educational game which, through it's modularity, allows for teaching students how to program. It's essentially a generic card game which can easily be modified. The backbone of the game is supposed to be totally uneditable (at least in theory), so I need to build a "Card" type that allows for an anonymous function as it...

Are there functions in Python?

Or is everything a method? Since everything is an object, a def whatever: is just a method of that file.py, right? ...

What kind of Maths should a student Computer Science be familiar with?

I am considering go back to College to get a Master Degree on Computer Science in 2011. As I have been a programmer who had been building all kinds of software, I don't think any thing related to programming shall be a big problem for me. But I did forgotten almost all knowledge I've learned as a undergraduate student. So I think may...

Transitioning from Associates CIS to Bachelor's CS

I realize there are a bunch of questions regarding CIS vs CS degrees, but I didn't really find anything relating to my specific situation. I am in the middle of my second year of an Associates Degree in CIS. Before this, I had a year at a small university that didn't go well at all, for a variety of reasons (distance from home, underest...

calculating max and min expressible values for floating point number rep

Hi, i want to figure out why expressible numbers in the IEEE floating point standard is 10^+38 - -10^38 (and similarly for the +ve). most textbooks just make this statement of fact, im grappling with why. ie. how would you calc this range? Many thanks ...

floating points: IEEE based, but non-standard conversion of bit values to binary

hey! So here is what we have, a custom IEEE based setup: Consider a five-bit floating representation based on the IEEE floating point format with 1 sign bit, two exponent bits and 2 significand bits. And a selection of bits that needed to be converted to binary (answers included): 0 00 00 = 0 0 00 01 = 0.01 ...