Recommender systems play an important role in quickly identifying and recommending most acceptable products to the users. The latent user factors and item characteristics determine the degree of user satisfaction on an item. While many of the methods in the literature have assumed that these factors are linear, there are some other methods that treat these factors as nonlinear; but they do it in a more implicit way. In this paper, we have investigated the effect of true nature (i.e., nonlinearity) of the user factors and item characteristics, and their complex layered relationship on rating prediction. We propose a new deep feedforward network that learns both the factors and their complex relationship concurrently. The aim of our study was to automate the construction of user profiles and item characteristics without using any demographic information and then use these constructed features to predict the degree of acceptability of an item to a user. We constructed the user and item factors by using separate learner weights at the lower layers, and modeled their complex relationship in the upper layers. The construction of the user profiles and the item characteristics, solely based on rating triples (i.e., user id, item id, rating), overcomes the requirement of explicit demographic information be given to the system. We have tested our model on three real world datasets: Jester, Movielens, and Yahoo music. Our model produces better rating predictions than some of the state-of-the-art methods which use demographic information. The root mean squared error incurred by our model on these datasets are 4.0873, 0.8110, and 0.9408 respectively. The errors are smaller than current best existing models errors in these datasets. The results show that our system can be integrated to any web store where development of hand engineered features for recommending products is less feasible due to huge traffics and also that there is a lack of demographic information about the users and the items.