Problem Statement :: In Java ,Given an array of ints, is it possible to choose a group of some of the ints, such that the group sums to the given target, ... 
I'm sitting here and programmnging some algorithms for my main program in Java (well the first one so far). I programmed the levenshtein algorithm just fine thanks to wiki being so ... 
Given an array of ints, is it possible to choose a group of some of the ints, such that the group sums to the given target, with this additional constraint: if ... 
I am implementing MFCC algorithm in Java.
There is a sample code here: http://www.ee.columbia.edu/~dpwe/muscontent/practical/mfcc.m at Matlab. However I have some problems with mel filter banking process. How to generate ... 
In the following code we can add 6 times. I want to to reduce it to three times.
package dsa;
import javax.swing.JOptionPane;
/**
*
* @author asda
*/
public class myQueue
{
...

I'm looking for some library(open source will be perfect) that have realization of different optimizaion algorithms in java. Actually I need a dual simplex method. It will be good if it ... 
What will be the best approach to implement forward chaining and backward chaining for reasoning process in java?
We have been given Hornform knowledge base which has set of statements.
I have tried ... 

I'm in the rough stages of creating a Spades game and I'm having a hard time thinking up a cryptographicallysecure way to shuffle the cards. So far, I have this:

I'm implementing the A* search algorithm from this pseudo on wikipedia's article:
function A*(start,goal)
closedset := the empty set // The set of nodes ...

So let me explain my problem a little better now (please reopen this question). I heard of markov chain theory when thinking about a method to generate procedural lines to build ... 
Suppose F is a collection of sets. An edgelabeled and nodelabeled
tree T is an HStree for F iff it is a smallest tree with the following
properties:
(1) Its root is ... 
I have implemented MFCC algorithm and want to implement BFCC. What are the differences between them and is it enough just to use another function instead of frequency to mel (2595 ... 
I have a problem, maybe a silly question, I want to store data in a database after I hash with the SHA1 algorithm. However, at a future time, the size in ... 
I have an inmemory cache which stores a set of information by a certain level of aggregation  in the Students example below let's say I store it by Year, Subject, ... 
import java.awt.Color;
import java.awt.Point;
import java.awt.image.BufferedImage;
import java.io.File;
import java.io.IOException;
import java.util.ArrayList;
import java.util.Random;
import javax.imageio.ImageIO;
public class Voronoi
{
public static void main(String args[])
{
Random ...


static void LasVegas(int []tablero, int f, int ultimaReina){
HashSet<Integer> enterosUsados = new HashSet<Integer>();
if (ultimaReina!=1) enterosUsados.add(ultimaReina);
if ((ultimaReina1) >=0){enterosUsados.add(ultimaReina1);}
...

I have to create an algorithm for routing purposes in pipeline industry. Like we have 4 pipelines available and in between there can be either injection of oil or it can ... 
I need a Fisher's Exact Test for a matrix n x m. I've been searching for hours and I've only found one example code, but it's written in Fortran. I've been ... 
I have a jersey oauth provider that uses HmacSHA1 for signing/verifying requests. This works for my development & test platforms where client & server are both different physical systems. However, when ... 
This is slide from class at my University, it about PatternMatching Algotithm..
And I try to code it in Java below;
...

I'm doing problem 10003 "cutting sticks" of the UVa online judge, I'm pretty sure my code works and I think I' correctly exiting the problem. But still I get a runtime ... 
I'm writing a calculator without using decimals (supports only Rational numbers), but I'd like to be able to do a version of square root.
When a square root function is ... 
I'm writing a .NET program for an engineering company. Their specification is to find the number of holes (either of same or different radius) on a rectangular plate and then to ... 
I have two arraylists, where each of which stores a set of elements. I would like to obtain and output the intersection of these two sets. Is there any efficient and ... 
Link to documentation: http://download.oracle.com/javase/6/docs/api/java/lang/Long.html#numberOfTrailingZeros%28long%29
Here is the Java implementation source code:
/**
* Returns the number of zero bits following the lowestorder ("rightmost")
* onebit in the two's complement binary representation ...

so I've been trying to use the Ibk nearest neighbor algorithm that goes together with the weka machine learning library.....
I know how to classify instances, but I want to implement the ... 

I need some help to store some data efficiently. I have a large list of objects (about 100.000) and want to store associations between this items with a coefficient. Not all ... 
I'm trying to use bouncycastle to encrypt a file using a public key.
I've registered the provider programatically:
Security.addProvider(new BouncyCastleProvider());
I created the public key object successfully.
when i get to encrypting the file using ... 
I implement versioning for my own domain model (tracking of differences in objects during update operations). Domain model has a tree structure. E.g. (> is reference)
A
> B
> C > A
...

Is there anything in Java that would allow me to take a code snippit and allow me to see exactly how many "ticks" it takes to execute. I want to ... 
I tried creating the A* algorithm in java and I have this strange bug. I know the A* doesn't always find the best path, but here it seems to go against ... 
I'm stumped. I need to access the next nth row in a query loop to show version differences between posts.
I'm using <cfquery> to output the revisions by group, and this is ... 
I want to find a nonempty, contiguous subarray for a given input array of integers, that can have duplicate values. I tried the divide and conquer method to find the maximum ... 
I want to recognize some entities on texts that I have and I found a lot of algorithms (NaiveBayes, Hidden Markov Models, Conditional Random Field, etc.), but seems that almost all ... 
I wrote a java program which scans and finds Executable lines of codes (ELOC), blank lines of codes(BLOC) and comments (CLOC) for only java and c++ codes. Following is my code:
...

I need a packing algorithm that fits a set of circles of varying radii, if the circles fit, in a rectangle. I've seen various pages on Wikipedia ... 
I don't want get a sorted array, just nth element's value. For example, given the array
a = [20, 5, 1, 3]
I'd like to be able to ... 
I have the following challenge that I need to create unique object tuples out of object lists. The speical challenge is here how I can do it for dynamic list sizes ... 
As a graduate I went for an interview for a java development role and was doing pretty well in the technical examinations until i came up against this question.
If i was ... 
I'm trying to find an object in a list based on a set of criteria. The basic logic looks like this
for (objectx obj : list)
{
if (object.property1 > ...

As an introduction to Java and android development I decided to write a Challenge 24 (given 4 numbers, must add, multiply, divide or subtract in order to create the product 24) ... 
I am trying to create a signature using the HMACSHA256 algorithm and this is my code.
I am using US ASCII encoding.
final Charset asciiCs ...

This is a project given to us by our professor.
The requirements are to implement 3 prepicked algorithms of CPU Scheduling in JAVA.
our group was given FCFS(First Come First Serve),Round Robin,and MFQ(Multifeedback ... 
Would someone be able to help with how I could implement this, or at least the algorithm to use for this.
What I am trying to do is parse a a hierarchical/tree ... 
I have a problem where in I need to process some files with size in the range of few kbs up to 1 GB max. The use case is such that ... 
I need to find all the missing date ranges from the rest of the year given a collection of date ranges. All the date ranges fall within the same year. And ... 
I am going to make a game called Deal or no deal using Java. Can anyone give me the idea or the algorithm of how banker offers? Or the algorithm for ... 
I didn't found but may be someone could me explain  OLAP cube is a combination of all possible aggregation, so related to Mondrian  leaf level is data in fact ... 
I have a List<Data> that contains random objects: i and o characters.
The Data has two types, i and o (Data.type ).
I want to write a function in Java that can arrange the ... 
I have the following implementation of Kadane's algorithm in java. It is basically to find the maximum sum of contiguous subarray.
String[] numbers = string.split(",");
...

I need to keep track of the last 7 days work hours in a flat file reading loop. It's being used to measure 'fatigueability' of work rosters.
Right now I have something ... 
I am trying to convert this dungeon algorithm from java into javascript, however, my script works 70% of the time. When it works, the problems are: the rooms ... 
I'm trying to create an algorithm that set some relevance to a webpage based on keywords that it finds on the page.
I'm doing this at the moment:
I set some words and ... 
Hey guys. I've been strugling with a backtraking problem for hours. Can anyone lend me a hand? Here is the problem:
n camels numbered from 1 to n are the arranged order. ... 
I'm doing an algorithm to classify the relevance of a page for some theme like 'movies' using all meta information as possible, but excluding the textual content of the body.
I want ... 
As part of my software I'm looking to write a keystone correction filter to avoid the tombstone / keystone effect you can get when projectors are displayed at an angle not ... 
Possible Duplicate:
Algorithm to return all combinations of k elements from n
The combination can be formed with 3 digits from 1,2,3,4 such a way that ... 
I was trying to solve random coding kata's and found this one, my question here is what is the optimal algorithm and best design approach for solving this kata?
Given a sequence ... 
I want to create a program for syntax analyzer for java, but I'm confusing in what way I should design the algorithm? can you please elaborate...

I am at the end of my homework, and a little confused on the right way to go for this algorithm. I need to find the base10 of a number:base that ... 
I'm making a simple enough game that involves using a grid, very much like a sudoku style grid, but I am having an extremely tough time figuring some seemingly simple things ... 
I'm looking to do a linear interpolation of a irregularly sampled function z(x,y) based on a Delaunay triangulation. Say I have a hill for which I have obtained a Delaunay triangulation: ... 
Hope you all know about Dropbox. In Dropbox, we can drag the files to drop box folder then it will be stored in the cloud. I need to do this ... 
and thanks for reading me.
I have a little problem that is that I need to Know the first/last day of a week in a month and a year, so:
public String getFirstDayOfWeekAndMonth(int ...

I am making this little program using command line arguments, I have like 90% of the work done. But I am trying to allow the user to enter non numerical values ... 
I mean by "make sound" which sound never exist, its completely made in Java.
I am trying to make a very simple very basic hello real world code in Java, but cant ... 
For an issue tracking system I need to calculate the response time for a request. The timer for response time should only be running during business hours. What algorithm/library should I ... 
I am trying to validate battleship field with these rules:
 Ships don't touch with sides or corners;
 Ships are straight;
 There are 1×4deck ship, 2×3deck, 3×2deck, 4×1deck ships.
The field is represented as ... 
I'm trying to find an efficient way to grab a Set of Subsets of a PowerSet.
For example, this works when the set sizes are small:
Set<Integer> set = new HashSet<Integer>();
set.add(1);
set.add(2);
set.add(3);
Set<Integer> set2 ...

Using official tutorial i understood the main principles of Java Cryptography Architecture.
But neither the officials nor internet gives me anything distinct about creating my own provider and implementing some crypto algorithms.
I ... 
Mathematics/algorithms was never my strong point (!) so requesting help on this one.
What is the most efficient implementation for a method with the following signature:
/*
* pairParts.size() > 0
* pairParts.size() ...

In my final year project I have to build an Algorithm animator. It would be done to show how the algo works using nodes(PCs) and edges(connections). For example, how the leader ... 
I work on a project where Spaced Repetition is essential, however I am not a specialist on the subject and I am afraid to reinvent the square wheel. My research pointed ... 
I have just started the java programming and at the moment I am doing the basic things. I came across a problem that I can't solve and didn't found any answers ... 
Possible Duplicate:
Algorithm: efficient way to remove duplicate integers from an array
I would like to know what is the best, efficient approach for finding a ... 
I was asked this question on an interview and I couldn't came up with an efficient idea to solve this problem.
"How to scan hundreds of log files containing SSN, and ... 
This is kind of hard to explain but I need to come up with an algorithm that will use these 14 value buckets to move through it based on the day ... 
My program have evaluate hundreds of millions of records. So the question of memory and performance are important.
Lets each record has key  ticketID. Also record has field value and field ... 
I have two long arrays of bytes and I need to compute how many bytes on corresponding positions are identical. My solution (in JAVA) is as follows:
int ...

I am trying to implement this Gift Wrapping Algorithm (yoshihitoyagi!) done in java, in VB6. I'm pretty sure I have done this properly, but for some reason, it will ... 
If I'm constructing a tail replace method for an RLE sequence, is the best way to decompress the sequence, append the new sequence at the given index, and then recompress or ... 
I need an algorithm (any programming language) to test the vitality with an hill climbing algorithm for breaking a cipher for a crypto challenge. The algorithm should test how likely it ... 
Trying to write algorithm for subsetSum... It should find all possible subsets of a given vector, then find which ones add up to a target value. However, I keep getting nullpointerexceptions, ... 
I need help with an algorithm to search for query words, in isolation and/or in combination, assign a score to each match and sort the matches by score. The returned results ... 
Hi i have been given a task for my course and it is to create an algorithm to make a 5 by 5 square like below:
*****
*****
*****
*****
*****
Ive spent hours attempting to do ... 
Hi i am doing my coursework and i have been given the task is to make an algorithm for a square that's 5x5 using "*" but has to be filled in ... 