
419 So.2d 460 (1982)
James Edwards BAGENTS
v.
Peggy Jean BAGENTS.
No. 82-C-0183.
Supreme Court of Louisiana.
September 7, 1982.
*461 Roy Maughan, Maughan, Atkinson & Martin, Baton Rouge, for applicant.
Michael V. Clegg, Macy, Adcock, Kemp, Dupree, McIntyre, Shows & Clegg, Baton Rouge, for respondent.
LEMMON, Justice.
This is a child custody matter. After the mother obtained an October, 1979 divorce on the ground of adultery and was awarded custody of her five-year old daughter, the father in May, 1980 filed a rule for change of custody, alleging that the mother was living with a man in the same apartment with the minor child. After a hearing, the trial court granted custody to the father. Shortly thereafter, the mother married her paramour and filed a motion for new trial, which was denied. The mother appealed, and the court of appeal affirmed. 408 So.2d 393. We granted certiorari to review the decisions of the lower courts. 411 So.2d 47.
James and Peggy Bagents were married in 1972, and their only child was born in 1974. When the mother filed for a divorce, the father admitted having an adulterous affair with a 17-year old girl. Shortly after the divorce, the father married his correspondent in adultery in January, 1980.
In December, 1979, the mother began living with Wade Bourgeois, who was not yet divorced from his wife. This liaison continued uninterrupted until the father filed a rule for a change of custody in May, 1980. The week before the trial, on the advice of counsel, the mother moved out of Bourgeois' apartment.[1]
At the hearing on the rule, the mother openly admitted that she had lived with Bourgeois, whom she planned to marry as soon as he secured his divorce. She also testified that "I do not think it's wrong as long as it's handled the right way", explaining:
"I'm just raising her to believe it's all right for us to live together as long as we're not dressing in front of each other and stuff like that. If anything is done, it's after she's asleep. It's never done nothing like that is ever done in front of her. We never undress or anything in front of her."
The mother also testified that the child had been extremely upset after she and her husband separated, but became adjusted and happy after she and Bourgeois established their relationship. The mother asserted that the child had more of a family life under the present arrangement than she had when the father was living with them.
Other evidence showed that the child was doing well in school and was attending church regularly.
*462 The father testified that although he had committed adultery before his separation from his former wife, he lived with his parents after the separation and did not begin living with his present wife until after they were married. He and his present wife also testified that she was not pregnant at the time of their marriage. There was also evidence of the father's use of marijuana during the previous marriage, but he denied use for a period of one year prior to trial. While he asserted that he was seeking a change of custody because the mother's relationship with Bourgeois had a detrimental effect on the child, he was aware of the relationship from its inception and did not object until an Easter Sunday fight over the late return of the child after weekend visitation.[2] He asserted, however, that prior to the fight he had consulted an attorney about the change of custody.
Thus, the evidence showed that neither parent was a model of morality. The father had committed adultery and used marijuana during the marriage, and he was motivated, at least in part, to seek a change of custody because of a fight with his former wife. The mother, on the other hand, lived in open concubinage with a married man in the same apartment with the child and not only defended the propriety of the relationship, but also suggested that it was beneficial to the child.
Faced with such evidence, the trial judge placed emphasis on the fact that a child learns by example from parents and that the mother's utter disregard for moral guidance and social standards is certain to affect the child adversely. Relying on the decisions in Bride v. Thon, 378 So.2d 152 (La.App. 1st Cir. 1979), and Beck v. Beck, 341 So.2d 580 (La.App. 2nd Cir. 1977), the trial court granted the change of custody. The trial judge in effect evaluated the mother's overall character and fitness, noting that the mother had chosen a presumptively detrimental relationship over consideration for the welfare of the child. The court of appeal admitted the dilemma faced by the trial court, but found no clear abuse of discretion in the trial court's determination that a change was in the child's best interest.
The principal consideration in every child custody case is the best interest and welfare of the child. Past misconduct and moral unfitness, demonstrated in this case by the mother's open concubinage in the home with the child, is a valid basis for determining the present suitability of a parent. Borras v. Falgoust, 285 So.2d 583 (La.App. 4th Cir. 1973). The present case is complicated by the fact (stipulated at the hearing on the motion for new trial) that the mother married her paramour as soon as it was legally possible to do so, thus eliminating the detriment from the child's living in the environment of an illicit relationship. However, the marriage did not represent a change in the mother's moral values or a desire to reform, and the trial judge on motion for new trial refused to recall the change of custody, again stressing that it was not in the best interest of the child to be raised by a parent with this mother's selfish attitude and immoral outlook.
In performing its function of deciding custody cases, the trial court is vested with a vast amount of discretion. On appellate review, great deference must be accorded to the decision of the trial court, not only because of that court's better capacity to evaluate witnesses, but also because of the proper allocation of trial and appellate functions between the respective courts. Canter v. Koehring Co., 283 So.2d 716 (La.1973).
The decision reached by the trial court in this case is not necessarily the decision that the individual judges of this court would have reached. Nevertheless, this court's function is not to substitute its collective decision for that of the trial court, *463 but to review the decision for error of law. We cannot say in this case that the trial court erred as a matter of law in deciding that a change of custody was in the child's best interest.
For these reasons, the judgment of the lower courts is affirmed.
DIXON, C. J., and CALOGERO, J., dissent.
DENNIS, J., dissents with reasons.
DENNIS, Justice, dissenting.
I respectfully dissent.
The majority fails to consider our decisions in Fulco v. Fulco, 259 La. 1122, 254 So.2d 603 (1971), Monsour v. Monsour, 347 So.2d 203 (La.1977) and most recently Atteberry v. Atteberry, 381 So.2d 1231 (La. 1980). If the majority wishes to abrogate the "reformation rule" established in these cases, then it should clearly say so. I do not feel that the simple statement, "the marriage did not represent a change in the mother's moral values or a desire to reform" suffices to dispense with the reformation issue. In light of our past decisions, some guidance is due to members of the bench and bar as to why Mrs. Bagents' remarriage did not constitute reformation of her past conduct.
NOTES
[1]  The mother admitted that the move was prompted by legal reasons, rather than moral reasons.
[2]  Indeed, the mother contended that she had contacted her former husband, prior to allowing Bourgeois to move in with her and the child, and sought the father's assurance that he would not try to change custody on the basis that "I'm unfit or something because I'm living with him".
