Skip to main content

Questions tagged [mathematical-programming]

Using a computer to implement mathematics. For questions about (mathematical) optimization, (also) use the optimization tag.

0 votes
0 answers
22 views

Scheduling Training for Two Dogs with Rest Constraints

You are a dog trainer tasked with training two dogs, Peter and Markley, for train1 days and train2 days, respectively. You can ...
Erebius's user avatar
  • 11
1 vote
0 answers
18 views

Transferable skills: From GAP to C++ [closed]

There is mathematical software for an area of mathematics (i.e., group theory), called GAP. For a while now, I have heard the vague statement that it is "based on C++". I don't know what ...
Shaun's user avatar
  • 141
0 votes
2 answers
131 views

What other ways could be of representing an irreducible fraction without gcd?

My code for it: from math import gcd y = int(input()) w = int(input()) g = gcd(y, w) print(f"{y// g}/{w// g}") Could there be any other way of solving this problem without using gcd ?
user141710's user avatar
1 vote
0 answers
45 views

Understanding the Condition Number of Cholesky-Least-Squares

Context The condition number is a purely-mathematical concept in the sense that it's intrinsic of a matrix (or a function.) Conceptually, it's how much an error would stretch with respect to it's ...
almon's user avatar
  • 11
1 vote
1 answer
121 views

Could someone help me understand why the solution to this problem isn't always one?

This is my current logic with respect to this problem, however, after submitting this hard-coded solution, it does not pass all test cases. I would like to know how. Here is my logic: Ignoring the ...
WarriorsSuraj's user avatar
-1 votes
1 answer
70 views

Knapsack problem with at least 1 item of two categories, no boundary on total items, unique items

Let's say we want to maximize the caloric intake of a person. One person MUST pick AT LEAST ONE steak and AT LEAST ONE vegetable (no limit of how many steaks or veggies he can pick, as long as they ...
Гого Зукед's user avatar
1 vote
0 answers
56 views

Kronecker Decomposition Algorithm

I am looking for an algorithm that decomposes a $2^n$ square matrix into a Kronecker product $\otimes$ of $n$ number of $2 \times 2$ matrices. Does anyone know if there is an implementation out there ...
3299792458777's user avatar
2 votes
1 answer
170 views

Proof of NP-hardness: Is the problem of finding the minimum edge-weighted subgraph with at least M pairwise connectivity NP-hard?

Given an undirected graph $G=(V,E)$ with non-negative edge weights $c_{ij}$ for each $(i,j)\in E$ and a positive integer $M$, the problem asks to determine the minimum-weight set of edges $S\subseteq ...
HonestSJ's user avatar
0 votes
1 answer
85 views

How do computer scientists finds a minimum of a tuple?

In multiobjective optimization, what does it mean to minimize a function of the form $F(a)=(O_1,-O_2,...,O_n)$? I mean, in mathematics, we can order every set by Zorn's lemma but I think we need some ...
guest's user avatar
  • 11
-2 votes
1 answer
107 views

The Hydra Game runs forever

I saw this question here: The Hydra Game algorithm I am also running into troubles with the same problem. I also learned of the problem in this Numberphile video, and also tried to compute it myself. ...
Lee's user avatar
  • 1
1 vote
4 answers
548 views

The Hydra Game algorithm

I was recently introduced to the Hydra Game by the youtube channel Numberphile (https://www.youtube.com/watch?v=prURA1i8Qj4). In this video, they discuss many variants of the Hydra Game - cut off one ...
SomeCallMeTim's user avatar
2 votes
1 answer
403 views

Potential of Artificial Intelligence to improve algorithm for PI

Recently AI (alphazero) was used to improve practical matrix multiplications by around 10 to 20 percent. Alphageometry and ramanujan machines all came into existence in the recent years as well. Seems ...
SiminSimin's user avatar
1 vote
0 answers
43 views

Decreasing quantity elements in quantities array to get it to be in same ratio as array of ratios

Problem Statement: We want to update(only decrease allowed) elements of array to obtain a new array which is in same ratio as ratio array. Example lets say you have quantity vector as [20, 50, 20] and ...
decentstudent's user avatar
2 votes
1 answer
186 views

Efficient algorithm for finding a vector to maximize the number of positive dot products with a given set (finding the maximum overlap of half-spaces)

I have a large set $\mathbf{V}$ of vectors in $\mathbb{R}^d\setminus\{\mathbf{0}\}$ and need to find a vector $\mathbf{u}$ that maximizes $\sum_{\mathbf{v}\in\mathbf{V}}\mathbf{1}_{\mathbf{u}\cdot\...
multiplywithadot's user avatar
1 vote
3 answers
122 views

Which algorithms could be suitable for solving my disjunctive programming problem?

Following a previous post on the cs stack exchange (link to question), I have been searching to no avail for an implementation of a disjunctive programming solver in C# (or wrapped in C#). In this ...
Ed_Silver's user avatar

15 30 50 per page
1
2 3 4 5
12