For purposes of this subtitle
(1) a nonresident alien individual or foreign corporation shall be considered as being engaged in a trade or business within the United States if the partnership of which such individual or corporation is a member is so engaged, and
(2) a nonresident alien individual or foreign corporation which is a beneficiary of an estate or trust which is engaged in any trade or business within the United States shall be treated as being engaged in such trade or business within the United States.