Dr. Wei Jiang, an internist and psychiatrist at Duke University states, Although you can not jump into sex the day after a heart attack or surgery, most people can resume sexual relations three to six weeks afterward, as long as they are free of chest pain or other complications.