Description Usage Arguments Details Value
View source: R/decode_state_mat.R
decode_state_mat
decodes state matrix.
1 | decode_state_mat(string, states, inputs, actions)
|
string |
Numeric vector. |
states |
Numeric vector with the number of states, which is the number of rows. |
inputs |
Numeric vector length one, with the number of columns. |
actions |
Numeric vector with the number of actions. Actions (and states) determine how many binary elements we need to represent an element of the action (or state) matrix. |
This function takes a solution string of binary values in Gray representation, transforms it to a decimal representation, then puts it in matrix form with the correct sized matrices, given the specified numbers of states, inputs, and actions.
Returns numeric (integer) matrix.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.