Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8350789
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 9, 20262026-06-09T08:25:51+00:00 2026-06-09T08:25:51+00:00

I am using Boltzman exploration in Q-learning where I have at least 10 actions

  • 0

I am using Boltzman exploration in Q-learning where I have at least 10 actions in each state. I know that with only two actions, Boltzman exploration can be applied quite simply as follows:

  1. Calculate pr1 and pr2 for the two actions with the Boltzman exploration equation.
  2. Generate a random number r
  3. Assuming pr1>pr2. If r<=pr1, take action corresponding to probability pr1. If r>pr1, take action corresponding to pr2.

However, how can I do this with 10 actions? At each decision step, I update the probabilities of all the actions. This gives me a probability distribution of all the actions where the probability of best action is highest. How do I select action in this case using the Boltzman exploration?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-09T08:25:52+00:00Added an answer on June 9, 2026 at 8:25 am

    Here is an excellent discussion of weighted random sampling: Darts, Dice, and Coins.

    And here is my implementation of the Vose’s Alias method:

    class WeightedRandom
    {
        private alias : array[int];
        private prob  : array[double];
    
        private random : Random;
    
        public this(p : array[double], random : Random)
        {
            this.random = random;
    
            def n = p.Length;
    
            alias = array(n);
            prob  = array(n);
    
            def small = Queue(n);
            def large = Queue(n);
    
            def p = p.Map(_ * n : double);
    
            foreach (x in p with i)
                (if (x < 1.0) small else large).Enqueue(i);
    
            while (!small.IsEmpty && !large.IsEmpty)
            {
                def s = small.Dequeue();
                def l = large.Dequeue();
                prob[s]  = p[s];
                alias[s] = l;
                p[l] = p[l] + p[s] - 1;
                (if (p[l] < 1.0) small else large).Enqueue(l);
            }
    
            while (!large.IsEmpty)
                prob[large.Dequeue()] = 1.0;
    
            while (!small.IsEmpty)
                prob[small.Dequeue()] = 1.0;
        }
    
        public NextIndex() : int
        {
            def i = random.Next(prob.Length);
            if (random.NextDouble() < prob[i])
                i;
            else
                alias[i];
        }
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Using Android TelephonyManager an application can obtain the state of data activity over the
Using report builder 3.0, I have a report that queries a cube. How do
Using CRM 4, I have an entity form that contains a tab with an
Using TortoiseSVN against VisualSVN I delete a source file that I should not have
using this http://bl.ocks.org/950642 we can see how to add images to nodes, the question
Using Location.getBearing(); I seem to get randomly changing bearings. Aka, I can turn the
Using android 2.3.3, I have a background Service which has a socket connection. There's
Using jQuery, one can easily find out whether a particular element is visible using
Using the HTML5 File API I can get the Binary String representation of a
Using NSDateComponents I know how to get the day component, but this gives me

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.