% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/simulate.R
\name{GenerateNetwork}
\alias{GenerateNetwork}
\title{Generate Initial Network Topology}
\usage{
GenerateNetwork(num.node)
}
\arguments{
\item{num.node}{An integer representing the total number of genes/nodes in the network.}
}
\value{
A square transition function matrix combining the initial DAG topology with randomly assigned Boolean logic functions. Elements with a value of 0 indicate no directed edge, while positive integers indicate the presence of an edge and specify the defining Boolean function type (codes 1-12: 1-10 for two-input functions, 11-12 for one-input identity/negation functions).
}
\description{
Randomly generates a valid directed acyclic graph (DAG) topology
\eqn{T}{T} and assigns a corresponding Boolean transition function \eqn{F}{F} to each node.
The algorithm samples parent set configurations, keeping the constraint
that the maximum in-degree for any node is 2, and further ensures
the resulting structure does not contain directed cyclic loops.
}
\examples{
# Generate a true network topology and Boolean rules for 5 nodes
set.seed(123)
true_network <- GenerateNetwork(num.node = 5)

# Graph the network with built-in exported function plot_network
plot_network(true_network)

}
