Skip to main content

Questions tagged [monte-carlo]

Filter by
Sorted by
Tagged with
0 votes
0 answers
25 views

How can we include the missing values in our computation?

Please refer to the paper Migacz, S., et al. (2019). Parallel implementation of a sequential Markov chain in Monte Carlo simulations of physical systems with pairwise interactions. Journal of Chemical ...
user366312's user avatar
1 vote
0 answers
72 views
+50

Can you explain how the update should work?

Please refer to the paper Migacz, S., et al. (2019). Parallel implementation of a sequential Markov chain in Monte Carlo simulations of physical systems with pairwise interactions. Journal of Chemical ...
user366312's user avatar
1 vote
0 answers
24 views

In monte-carlo tree search, do you propagate the result from the terminal or just the leaf?

In most descriptions of monte-carlo tree search, I see the simulation step described as: Play out a game from the leaf node until a terminal node is reached and get the result. And the ...
Kyle's user avatar
  • 11
0 votes
1 answer
173 views

Finding the error probability of a Monte Carlo algorithm

Let's say I have a Monte Carlo algorithm $A$ that gives the correct answer with a probability $p$ > $1/2$. I don't have any information on if it's decisional or not. I understand that I can make ...
diegodr02's user avatar
3 votes
0 answers
60 views

Constrained random sampling by inequalities

Assume I have $n$ random variables $x$ which need to obey a set of inequality constraints that are linear and can be written as $Ax \leq 0$. Is there a method to sample effectively from these for ...
Dan's user avatar
  • 61
1 vote
1 answer
93 views

How branching factor affects complexity of Monte Carlo Tree Search?

I was reading: https://stackoverflow.com/questions/34724201/whats-the-time-complexity-of-monte-carlo-tree-search Where it says: The runtime of the algorithm can be simply be computed as O(mkI/C) ...
Algo's user avatar
  • 11
1 vote
3 answers
368 views

What set.seed() mean in the Monte Carlo method

I'm trying to learn the implementation of the Monte Carlo method in R language. I am following a course with an example of predicting results for a board game. What I'm not understanding is the usage ...
Lyra Dobruna's user avatar
1 vote
0 answers
67 views

Combine Las Vegas and Montecarlo probabilistic algorithms to improve chance of finding correct answer

Let's say that I have a Las Vegas algorithm for a given problem (whose answer is true/false for simplicity) with a chance of ...
Lightsong's user avatar
  • 239
0 votes
0 answers
34 views

How to create random pseudo samples from a non-stationary time series containing NaNs using Monte-Carlo method?

I am looking for answers creating 500 samples of non-stationary Time series based on its probability distribution preferably using monte-carlo simulation. DATA LINK Secondly, the most example ...
shewag's user avatar
  • 1
2 votes
1 answer
145 views

Question about what exponentially small probability of success means in randomized algorithms

I am reading the book Randomized Algorithms By Motwani and Raghavan, and one of their exercises gives a modification of Karger's Min-Cut algorithm(Both is Monte Carlo) which picks two vertices and ...
DenLilleMand's user avatar
1 vote
0 answers
18 views

How exactly are non-leaves in Monte Carlo tree search chosen?

I play around with Monte Carlo tree search and tic-tac-toe. For now I have followed the Wikipedia article. There is one place, where I am stuck, the selection phase. The given procedure is the ...
Martin Ueding's user avatar
2 votes
0 answers
59 views

Decision problem solution monte carlo

I have a rather straightforward question for this community (that I am not able to solve). Assume there is a probability of Tom having a bag of candy. If Tom has a bag, he says the truth 4/5 times and ...
DragoonStorm's user avatar
4 votes
1 answer
617 views

Is there some kind of expected error margin for my Monte Carlo algorithm?

My Monte Carlo algorithm starts by placing some circles in the plane with potential overlaps. I then place a large circle somewhere and compute the overlapping area of this larger circle with the ...
J. Schmidt's user avatar
1 vote
0 answers
89 views

How to design an unbounded Monte Carlo algorithm for SAT(Boolean Satisfiability Problem) problem?

I want the algorithm to be in polynomial time and the correct answer rate is 0.5 or more. (True / false judgment is polynomial time) All the methods I think of take exponential time(2^n). Can anyone ...
musk's user avatar
  • 23
3 votes
1 answer
72 views

Uniformly sample $x,y\in\{0,1\}^n$ with Levenstein distance $k$

Given alphabet $\{0,1\}$, we want to uniformly sample $x,y \in \{0,1\}^n$ such that $ed(x,y)=k$, where $ed$ denotes the Levenstein distance, i.e., the minimum number of edit operations (insert, delete,...
Ameer Jewdaki's user avatar
2 votes
2 answers
230 views

Describe a Monte Carlo algorithm for the Triangle Packing problem

Book: Parameterized Algorithms by Marek Cygan (free to download legally) Chapter about Multivariate polynomials on Page 353 (In the book not the pdf) Question 10.19: Describe a Monte Carlo $2^{3k}n^{O(...
John19's user avatar
  • 63
2 votes
0 answers
209 views

How to avoid division by zero in UCT formula in Monte Carlo tree search?

In step 2 (expansion) of the Monte Carlo tree search algorithm, one or more child nodes are created, and one node named C is chosen among them. The simulation step is applied to C giving it a score of ...
Robert Moore's user avatar
1 vote
0 answers
55 views

What problem is this application of simulated annealing trying to solve?

I was reading about simulated annealing on its Wikipedia page, and was drawn to a particular example illustrating the annealing schedule. Below is the picture and its description: Example ...
Brian Barry's user avatar
0 votes
0 answers
101 views

Devise Mont Carlo and Las Vegas Algorithms to Solve Maximum Independent Set

I am trying to devise a Las Vegas algorithm to solve Maximum Independent Set, but I don't know how to start. Also, I want to devise a Mont Carlo algorithm for this problem. I would appreciate any help....
Sepehr Omidvar's user avatar
1 vote
1 answer
107 views

MCTS how to prevent Selecting a TERMINAL state in TRAVERSAL Phase?

Hello I am currently working on an implementation of MCTS and I ran into the problem that my tree traversal policy selects nodes with terminal game states. Furthermore how do I prevent selecting a ...
user131546's user avatar
2 votes
1 answer
268 views

Algorithm to sample high-dimensional parameter space of expensive cost function

I am looking for recommendations for algorithms (apparently this is the right SO site for that) that efficiently scan the high-dimensional parameter space of a cost function that is very expensive to ...
fuenfundachtzig's user avatar
9 votes
1 answer
5k views

What is the optimal algorithm for playing the hangman word game?

Suppose we are playing the game hangman. My opponent and I both have access to the dictionary during the game. My opponent picks a word from the dictionary with knowledge of the algorithm which I will ...
zfj3ub94rf576hc4eegm's user avatar
2 votes
1 answer
291 views

What is an example of a Monte-Carlo algorithm for finding a Hamiltonian path?

I've recently been made aware that there exist Monte-Carlo algorithm(s?) for determining whether a Hamiltonian path exists in a graph. I am struggling to figure out how it would work. What is the ...
Baksel's user avatar
  • 143
1 vote
0 answers
273 views

Combining TWO Monte Carlo algorithms to get a Las Vegas algorithm that solves the same problem

I came across a problem that I have no clue how to solve. Consider two Monte Carlo algorithms, called A and B that both solve the same problem. A is true-biased and t-correct, while B is false-...
ndrb's user avatar
  • 11
2 votes
2 answers
608 views

Pandemic board game - find all possible next 4 actions

I hope I am asking this on the right community. I am building an Artificial Intelligence to play the board game Pandemic. The AI uses a Monte Carlo algorithm. After implementing the game rules and ...
AllirionX's user avatar
  • 123
1 vote
1 answer
2k views

UCT (Upper Confidence bounds applied to Trees)

For UCT (Upper Confidence bounds applied to Trees), why If given infinite time and memory, UCT theoretically converges to Minimax. ? Besides, I do not quite understand how UCT deals with the flaw of ...
kevin's user avatar
  • 111
1 vote
0 answers
465 views

Can the shortest path problem be solved using Monte Carlo Tree Search?

I think Monte Carlo Tree Search could be used to find the shortest path, but it seems that this method is only used considering win/lose outcomes in the simulation step. If we consider the path ...
Ralff's user avatar
  • 163
2 votes
2 answers
2k views

How to find the best exploration parameter in a Monte Carlo tree search?

I've developed a Monte Carlo tree search algorithm in checkers. Here is my question. What should be the value of $C$, the exploration parameter in the following formula described in Monte Carlo Tree ...
Jack Logan's user avatar
1 vote
0 answers
183 views

Is MCTS an appropriate method for this problem size (large action/state space)?

I'm doing a research on a finite horizon decision problem with $t=1,\dots,40$ periods. In every time step $t$, the (only) agent has to chose an action $a(t) \in A(t)$, while the agent is in state $s(t)...
D. B.'s user avatar
  • 21
1 vote
1 answer
125 views

How to decrease the confidence of a Monte Carlo algorithm in its answer?

Recall that a Monte Carlo algorithm is $p$-correct if it outputs a correct answer with probability at least $p$. In the case of decision problems, where the answer is binary, repeating the MC ...
milongo's user avatar
  • 33
2 votes
1 answer
211 views

Monte Carlo Algorithms : Are there any problems where two opposite Monte Carlo algorithms could solve it?

I started reading on Probabilistic algorithms and Monte-Carlo algorithms. Since a Monte-Carlo can only give a certain answer for either True or False, I was wondering if it's conceivable that for the ...
Robert's user avatar
  • 43
2 votes
1 answer
48 views

Randomly construct linear combination that is within bounds over two basis

Given rank deficient matrix $A$, I want to randomly construct vectors $\vec{x}$ such that: $0 \le x_{j} \le 1$ $0 \le b_{j} \le 1$ where $\vec{b} = A\vec{x}$ Matrix $A$ is about 10 x 15. I want to ...
R zu's user avatar
  • 168
0 votes
1 answer
1k views

Understanding On-policy First Visit Monte Carlo Control algorithm

I am going through the Monte Carlo methods, and it's going fine until now. However, I am actually studying the On-Policy First Visit Monte Carlo control for epsilon soft policies, which allows us to ...
naifmeh's user avatar
  • 125
1 vote
1 answer
137 views

Pi approximation with Montecarlo: Why not just evenly distributed points?

With the randomised algorithm for Pi approximation (see https://www.geeksforgeeks.org/estimating-value-pi-using-monte-carlo/ ), I keep wondering why just using points with an even distance should'n ...
bento's user avatar
  • 111
3 votes
1 answer
462 views

Generate a random magic square on a large field

If consecutive natural numbers 1 .. n^2 are placed in a n*n grid so that sum of numbers in each column and in each row is a constant then we call it a magic square. I would like to generate magic ...
Stepan's user avatar
  • 131
3 votes
1 answer
87 views

How do you protect an AI from a human doing "illogical" moves?

Using a monte carlo approach and evalutation function. Some moves will deemed to be more advantageous than others. As a computer plays itself, it will generally go for the best moves possible. And ...
zooby's user avatar
  • 273
5 votes
2 answers
5k views

What is the difference between Simulated Annealing and Monte-Carlo Simulations?

What is the difference between Simulated Annealing and Monte-Carlo Simulations? Is Simulated Annealing a specific type of Monte-Carlo simulation, or are they completely separate techniques?
M Smith's user avatar
  • 467
1 vote
1 answer
154 views

Do Nested Monte Carlo Algorithm always find the best score where score is the number of moves on the leftmost path

I am studying Nested Monte Carlo Algorithm addressing the problem of guiding the search toward better states when there is no available heuristic. It uses nested levels of random games in order ...
Revolucion for Monica's user avatar
3 votes
1 answer
580 views

How to estimate how many assignments satisfy a given DNF formula using Monte Carlo?

Admittedly, homework. For the purpose of this question: $\phi$ is a DNF formula similar to this one: $(x_1 \wedge \neg x_3 \wedge x_4) \vee (\neg x_1 \wedge x_2)$ Also $C_i$ is a clause in this ...
gaazkam's user avatar
  • 179
2 votes
1 answer
485 views

What is partial expansion in Monte Carlo Tree Search?

I'm trying to understand the modification to the MCTS algorithm called Partial Expansion. From what I've been reading it enables one to not require all child nodes to have been expanded before ...
user79894's user avatar
1 vote
2 answers
7k views

Monte Carlo: what is a seed?

I have reached a chapter in the notes I am following where a program written in C++ is using a Monte Carlo method to estimate $\pi$. It mentions a 'seed', but does not say what this is. I have tried ...
Meep's user avatar
  • 123
2 votes
0 answers
47 views

Card Shuffling, Bounding Mixing time using Paths and Flows

I've been struggling with a problem that is very similar to a 2014 question posted here. The question in particular is 3(1) and 3(2). To paraphrase, we are supposed to use paths and an encoding ...
user3280193's user avatar
1 vote
2 answers
407 views

Monte Carlo algorithm: Element in array

Design a Monte Carlo algorithm that checks in constant time if a given element $x$ is in a $n$-dimensional vector $V$. Calculate the probability for a correct answer. Then suppose $n=10$, how many ...
Álvaro G. Tenorio's user avatar
2 votes
0 answers
42 views

Not grasping Bayesian Monte Carlo

I've read several sources of information that describe the process of Bayesian Monte Carlo Quadrature but am just not understanding the details enough to be able to implement it. For instance two ...
Alan Wolfe's user avatar
  • 1,358
5 votes
1 answer
3k views

Generating values from a probability density function

If I have a probability density function, some f(x) which is >= 0 everywhere and integrates to 1, is there a method to generate random numbers using that PDF? I know there is the box-muller transform ...
Alan Wolfe's user avatar
  • 1,358
5 votes
1 answer
157 views

Monte Carlo Tree Search in connect 5 tree design

I'm trying to create a mcts ai for connect 5 algorithm. However, I'm confused on designing the tree. Here is a quick description of the algorithm: The initial state, S0 is the board state where the ...
Dashadower's user avatar
1 vote
1 answer
1k views

How does MCTS handle games with large numbers of poor moves?

I am trying to understand how pure Monte Carlo tree search (https://en.wikipedia.org/wiki/Monte_Carlo_tree_search) handles games where random playout will likely result in a loss easily avoided by ...
Eli Stevens's user avatar
4 votes
2 answers
275 views

UCT1 Algorithm: What does "total number of simulations" mean?

When reading up on the UCT1 algorithm (I'm writing a Monte Carlo tree search), I'm having trouble with the formula. $$\frac{w_i}{n_i} + \sqrt{\frac{\ln t}{n_i}}$$ Wikipedia, this guy, and this guy all ...
APCoding's user avatar
  • 323
3 votes
1 answer
408 views

How does the Monte Carlo Tree Search Algorithm Decide When to Expand?

I understand that the MCTS algorithm expands its tree after it has selected the best route to take. However, how does it decide when to end selection and then expand the tree? It cannot just traverse ...
APCoding's user avatar
  • 323
1 vote
0 answers
318 views

What did Dijkstra think about Monte Carlo algorithms? [closed]

In A Discipline of Programming, Dijkstra wrote: Two circumstances have changed the scene since then.* The one is the insight that, even in the case of fully deterministic machines, program testing ...
Geremia's user avatar
  • 154