He entered the Society of Jesus on February 5, 1832. He was in charge of the episcopal seminary of Bertinoro when political troubles in 1860 led to his move to England. At Stonyhurst College he took up philosophy and taught it for some seven years. This led to his producing three volumes of "Realis Philosophia." These were for private presses, and the volumes are not reliable as evidence of his mature opinions. In 1868 he left England for California.
In California he would be Rector of Saint Ignatius' College, San Francisco, for three years, and is listed as a past President of the University of San Francisco. He resided at Santa Clara, teaching elementary mathematics there. He would work in Santa Clara until his death. At his death he left behind, in manuscript, an elaborate new edition of the "Realis Philosophia" which never saw the light. His published works are "Molecular Mechanics" (Cambridge, 1866); "The Love of Religious Perfection", originally in Italian, in the style of "The Imitation of Christ" (published in English, Dublin, 1863); articles in "The Catholic World", XVII-XXI (1873-75), the best printed account of his philosophy; two articles in the "Am. Cath. Q. Rev.", II (1877); and "A Discussion with an Infidel", being a review of Büchner's "Force and Matter" (New York, London, and Leamington, 1901). His elementary works on mathematics, all published in San Francisco, are "Algebra" (1890), "Geometry" (1895), "Analytical Geometry" (1887), "Plane and Spherical Trigonometry" (1886), and "Infinitesimal Calculus" (1889).
Father Bayma took the Venerable Bede for his model, and often referred to the old Breviary Lesson, which used to be read in England on St. Bede's day. It ran: "Bede [and Bayma too] was handsome of stature, grave of gait, rich and sonorous of voice, eloquent of speech, noble of countenance, a blend of affability and severity. He was affable to the godly and devout, formidable to the proud and negligent. He was always reading, always writing, always teaching, always praying."
To posterity he must be known by his "Molecular Mechanics", a metaphysical and mathematical work treating of the constitution of matter. With Roger Joseph Boscovich, Bayma reduces all matter to unextended points – centres of force acting in the inverse square of the distance – thus acting upon one another, but of course not touching, for Bayma abhorred continuous matter and upheld actio in distans. These points were bound up into molecules, and molecules into bodies. Boscovich made his points, or elements, attractive at molar distances, repulsive at molecular. Bayma divides elements into attractive and repulsive, the former always attracting, the latter always repelling; the attractive elements preponderating in the nucleus of the molecule, the repulsive in the envelope. The work drew attention at Cambridge, and at Trinity College, Dublin. The author was advised to test his theories by ten years of experiments in chemistry and electricity. This did not occur in reality due to his death.