delivered the opinion of the court:
The defendant, Kenneth D. Le May, was charged with the murder of his ex-wife, Leta, tried by a jury in the circuit court of Winnebago County, found guilty and sentenced to the penitentiary for a term of 40 to 50 years. Defendant now seeks review of that conviction.
Defendant claims that the trial court erred in failing to hold a pretrial sanity hearing, and that the State failed to prove that he was sane at the time of the homicide. He also claims error in the giving of instructions and the admission into evidence of a photograph of the deceased.
The record indicates that defendant had been divorced by Leta on November 30, 1962. On the morning of December 2, 1962, he went to her house in Rockford at about 6:00 A.M. where they quarreled. Shortly thereafter Leta was found lying in her bathtub clothed in a coat and suit. She died of two bullet wounds in the head. Defendant was later arrested near Elgin and a .22 caliber bolt action rifle was found in his car. In two pretrial statements defendant said that he was scuffling with the deceased and shot her. At the trial defendant for the first time stated that Leta had said she was pregnant by another man and it was none of his God damn business and everything turned red.
*210In considering defendant’s claim that the trial court erred in failing to hold a sanity hearing, we must examine the proceedings prior to trial. Defendant, represented by counsel of his own choosing, originally pleaded not guilty. Thereafter the plea was withdrawn and after proper admonishment, he persisted in a plea of guilty, and a judgment of guilty was entered. At a subsequent hearing on aggravation and mitigation, Dr. Graybill, a psychiatrist testifying for defendant, stated that in his opinion defendant was not aware of what he was doing at the time of the shooting. However, Dr. Graybill stated that defendant was sane at the time of the hearing, was able to appreciate the charges against him, understand the consequences thereof, and capable of entering a plea. On the basis of this testimony and at the suggestion of the trial judge, the plea of guilty was withdrawn, the judgment vacated, and the case set for trial.
The duty of a trial court to cause a sanity hearing to be held only arises when evidence or circumstances give rise to a bona fide doubt as to the accused’s sanity at the time of trial. The only question of defendant’s sanity at any time was raised by Dr. Graybill, who also insisted that defendant was sane at the time of trial. It is further apparent that defendant at all times was able to co-operate with counsel during the trial and testified lucidly on his own behalf. On this record there is nothing to create a bona fide doubt as to defendant’s sanity at the time of trial and, therefore, there was no need for a separate sanity hearing. People v. Lego, 32 Ill.2d 76; People v. Harper, 31 Ill.2d 51; cf. People v. Burson, 11 Ill.2d 360.
Defendant next claims that a reasonable doubt was raised as to his sanity at the time of the shooting. Dr. Gray-bill testified at the trial that in his opinion defendant was sane prior and subsequent to the shooting, but that he did not know what he was doing “at the moment” of the shooting. The “moment” he was speaking of could be anywhere from a few minutes to an instant. Dr. Graybill based his *211opinion in part on a “borderline normal” electroencephalogram, brain damage, a borderline intelligence, and the assumption that defendant’s condition was triggered by the deceased’s remark in connection with her pregnancy. Dr. Graybill further testified that, “I think it is difficult for anyone to kill in a situation like this without being mentally deranged.”
Dr. Stephan, a psychiatrist, testified in rebuttal that when he saw defendant on December 6, 1962, he was sane and had no symptoms of brain damage. He further testified that little significance could be drawn from a borderline normal electroencephalogram.
While defendant testified that “everything went red” after his wife told him she was pregnant, his prior statement taken a day after his arrest sought to justify the killing as an accident. He stated that he was scuffling with his wife and the gun accidentally went off.
Defendant argues that once evidence of insanity is introduced the ordinary presumption of sanity does not prevail and the burden devolves on the State to prove that at the time of committing the act, the accused was legally sane. (Davis v. United States, 160 U.S. 469, 40 L. Ed. 499; People v. Munroe, 15 Ill.2d 91.) We agree with this concept of the burden of proof. However, we feel that the present record raises a factual question for the jury on the issue of defendant’s sanity at the time of the occurrence.
Dr. Graybill’s hypothesis of momentary insanity was based on many factors including an assumption of brain damage, a borderline normal electroencephalogram, and an inflammatory statement allegedly made by the deceased. Dr. Stephan, while he did not affirmatively state that defendant was sane at the time of the occurrence, raised a question of fact as to the validity of Dr. Graybill’s opinion, and defendant’s prior claim of an accidental shooting effectively rebuts the assumption of the deceased’s alleged inflammatory remark. In addition the jury could consider the *212physical facts relating to the shooting. We believe the jury was justified in determining that the State had satisfied the burden of proof on the issue of sanity.
Defendant next alleges error in the giving of State’s instructions Nos. 18, 20, 21 and 22 on the defense of insanity. At the conference on instructions defendant’s attorney withdrew his objections to both instructions 20 and 22, and defendant’s written post-trial motion did not object to the giving of any of the instructions now criticized. The failure to assign error in the written motion for a new trial ordinarily waives the error on appellate review. People v. Hunter, 23 Ill.2d 177; People v. Flynn, 8 Ill.2d 116.
Defendant, however, points out that the present Code of Criminal Procedure provides that, “Plain errors or defects affecting substantial rights may be noticed although they were not brought to the attention of the trial court.” (111. Rev. Stat. 1965, chap. 38, par. 121 — 9(a).) This section is permissive, and we believe it is in accord with our prior practice where substantial error has arisen in a criminal trial. However in the present case defendant was capably represented by counsel of his own choosing who considered instructions 20 and 22 not to be prejudicial after consideration at the conference on instructions. As to No. 20, the instruction was first objected to as repetitious, and the court stated: “I don’t think this No. 20 hurts the defendant.” Defendant’s counsel replied: “Well, perhaps from the standpoint of uncontrollable impulse maybe, maybe we better not object to it.”
As to No. 22 the trial judge first questioned the propriety of the instruction and gave the instruction only after a colloquy in which counsel withdrew his objection. As to No. 21, counsel stated no grounds for his objection. When considered with the other instructions as a series, instruction 21 is not objectionable.
In addition instructions 18 and 20 were approved by the court in People v. Carpenter, 11 Ill.2d 60. We have ex*213amined the entire charge and we believe that the jury was properly instructed on the issue of insanity, and no substantial error occurred in the giving of the criticized instructions.
Defendant also contends that he was prejudiced by the introduction of a photograph of deceased into evidence. We feel that the photograph in question tended to establish facts in controversy material to the offense, and that the trial court did not abuse its discretion in admitting the photograph into evidence. People v. Hoffman, 32 Ill.2d 96; People v. Jenko, 410 Ill. 478, 482.
Defendant finally raises for the first time in his reply brief the question of the admission into evidence of two statements of defendant taken when he was not represented by counsel. The statements were admitted without objection, but defendant now contends that the statements were inadmissible under the doctrine of Miranda v. Arizona, 384 U.S. 436, 16 L. Ed. 2d 694.
In Johnson v. New Jersey, 384 U.S. 719, 16 L. Ed. 2d 882, the United States Supreme Court held that principles announced in Miranda should apply only to cases commenced after that decision was announced. Since the present trial commenced prior to the Miranda decision, its principles are inapplicable, and defendant does not question that the statements were clearly admissible prior to Miranda.
We conclude that defendant was afforded a fair trial free of substantial error and was proved guilty beyond a reasonable doubt. The judgment of the trial court is affirmed.