When is each option used?
I can only speak for the common law jurisdiction of the United Kingdom, but typically an issue is remanded back to the lower court for further proceedings. This is because the lower court is normally in a better position to handle the matter. For example, the lower court will have heard all of the arguments and evidence presented by both sides, and will have more experience in reaching a fair and just decision on the facts (backed by the clarifications of the law provided by the appellate court).
Additionally, there is the concept of appellate court deference and respect for the lower courts as established in Dupont de Nemours (EI) & Co v ST Dupont (Note)  EWCA Civ 1368  1 WLR 2793  (May LJ):
… [the appellate court] will accord appropriate respect to the decision of the lower court. Appropriate respect will be tempered by the nature of the lower court and its decision-making process. There will also be a spectrum of appropriate respect depending on the nature of the decision of the lower court which is challenged.
In contrast, the appellate court won't have heard any of the arguments—they would have to either re-hear the whole case again (expensive and time-consuming) or decide the matter on the papers which is no real replacement for the oral arguments made at trial, with the associated risk that an injustice is committed.
This is backed up by the United States Supreme Court in Anderson v City of Bessemer (1985) 470 US 564, 574-575:
"The trial judge's major role is the determination of fact, and with experience in fulfilling that role comes expertise. Duplication of the trial judge's efforts in the court of appeals would very likely contribute only negligibly to the accuracy of fact determination at a huge cost in diversion of judicial resources. In addition, the parties to a case on appeal have already been forced to concentrate their energies and resources on persuading the trial judge that their account of the facts is the correct one; requiring them to persuade three more judges at the appellate level is requiring too much. As the court has stated in a different context, the trial on the merits should be 'the 'main event' … rather than a 'try-out on the road'' …"
It would also deprive the appellate court of valuable time to hear further appeals on other important points of law.
Most of the time, cases are remanded back to the lower court by the appellate court for the reasons stated above. In the rare instance that a decision needs to be reversed, it will be because there is no potential injustice in doing so, it is not appropriate for the lower court to decide, and/or the decision is something that is only within the powers of the appellate court (e.g. the court wishes to set a binding precedent).
Does anything prevent the lower court from reaching the same outcome?
Yes, the decision of the appellate court can usually be considered binding precedent. This would require the lower court to either follow that precedent (and so presumably come to a different decision) or find a way to "distinguish" the case such that the precedent does not apply.
If they were to find a way to distinguish the case and made the same decision despite the appellate court ruling, they risk having their decision re-appealed again. No judge wants their judgment to be appealed to an appellate court since they risk questions about their professional competence if it happens frequently, and it's also professionally embarrassing for both the judge and the appellate court who would have to address the matter again (and rightly tick the judge off, probably).
Making the same decision again—and having any subsequent appeal succeed—would almost certainly ensure the appellate court then chooses to reverse the decision rather than keep remanding it back to the lower court. This would damage the judge's professional opportunity to be promoted to that or other appellate courts in the future. The appellate court may also decide to censure or rebuke the judge when reversing the case as happened recently in Serafin v Malkiewicz & Ors  EWCA Civ 852:
In our view, the Judge not only seriously transgressed the core principle that a judge remains neutral during the evidence, but he also acted in a manner which was, at times, manifestly unfair and hostile to the Claimant.
Of course, in the case above the Court of Appeal also erred and the Supreme Court remanded the case back to a court of first instance:
Serafin v Malkiewicz & Ors  UKSC 23:
 Conscious of how the justice system has failed both sides, this court, with deep regret, must order a full retrial.
 In the light of the above I am driven, with a degree of embarrassment in relation to respected colleagues, to suggest that the new judge should determine the availability of the public interest defence without reference to the reasoning which led the Court of Appeal to conclude that the defendants had met the requirements neither of section 4(1)(a) nor of section 4(1)(b) of the Act.