In today's world, efficient computation is the key to success in many fields. Pattern association plays an influential role in many areas of life, such as learning and memory. In complex dynamics, bidirectional associative memory has been effectively demonstrated by neural networks. However, these neural networks face challenges in terms of performance, such as computational time. A random bipolar input pattern and output pattern of a matrix with different sizes were used to analyze the background of this study. In order to address the challenges of bidirectional associative memory, nonlinear memory association is considered to be the most feasible method. In this study, we present a cascadebased non-linear feedforward neural network that performs pattern association in two passes and behaves like a Bayesian algorithm. A random pattern and English alphabets with different patterns have been used to validate the results of this approach. Using the experimental results, the study evaluated BAM's equivalent performance, pattern association, and stability.